diff --git a/molecule/default/prepare.yml b/molecule/default/prepare.yml index d238e52..c11a2db 100644 --- a/molecule/default/prepare.yml +++ b/molecule/default/prepare.yml @@ -10,14 +10,10 @@ - ansible_os_family == 'RedHat' - name: "Apt get update" - shell: apt-get update && apt-get install -y python-apt + command: apt-get update && apt-get install -y python-apt when: - ansible_os_family == 'Debian' - - name: debug - debug: - var: ansible_distribution_major_version - - name: "Installing packages on Debian" apt: name: diff --git a/tasks/configure_linux.yml b/tasks/configure_linux.yml index 4d956f2..221a768 100644 --- a/tasks/configure_linux.yml +++ b/tasks/configure_linux.yml @@ -30,7 +30,7 @@ mode: 0640 become: yes when: - - telegraf_agent_version is version_compare('0.10.0', '<') + - telegraf_agent_version is version('0.10.0', '<') notify: - Restart Telegraf - Restart Telegraf container @@ -44,7 +44,7 @@ mode: 0640 become: yes when: - - telegraf_agent_version is version_compare('0.10.0', '>=') + - telegraf_agent_version is version('0.10.0', '>=') notify: - Restart Telegraf - Restart Telegraf container diff --git a/tasks/configure_macos.yml b/tasks/configure_macos.yml index 33b3a6b..db2b16c 100644 --- a/tasks/configure_macos.yml +++ b/tasks/configure_macos.yml @@ -30,7 +30,7 @@ mode: 0640 become: yes when: - - telegraf_agent_version is version_compare('0.10.0', '<') + - telegraf_agent_version is version('0.10.0', '<') notify: - Restart Telegraf - Restart Telegraf container @@ -44,7 +44,7 @@ mode: 0640 become: yes when: - - telegraf_agent_version is version_compare('0.10.0', '>=') + - telegraf_agent_version is version('0.10.0', '>=') notify: - Restart MacOS Telegraf - Restart Telegraf container