From d9386cddcfa26273d816d7de62d6b5ff13bc078f Mon Sep 17 00:00:00 2001 From: Daniel Kontsek Date: Tue, 4 Apr 2017 23:36:50 +0200 Subject: [PATCH] Fixed pkgin install zabbix-agent --- ansible/roles/zabbix-agent/tasks/main.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ansible/roles/zabbix-agent/tasks/main.yml b/ansible/roles/zabbix-agent/tasks/main.yml index b0168316..81548d9d 100644 --- a/ansible/roles/zabbix-agent/tasks/main.yml +++ b/ansible/roles/zabbix-agent/tasks/main.yml @@ -14,7 +14,9 @@ when: ansible_distribution == "CentOS" - name: Install Zabbix agent (SmartOS) - pkgin: name=zabbix-agent state=present + shell: pkgin -y install zabbix-agent + register: res + changed_when: "'nothing to do.' not in res.stdout" when: ansible_distribution == "SmartOS" - name: Create Zabbix agent configuration file