diff --git a/CHANGELOG.md b/CHANGELOG.md index 5657b0b..a068f47 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,7 @@ * Set empty dependencies line to fix Galaxy warning. * Add possibility to restart Fail2ban service. * Use to_nice_json to manage packages list. +* Fix E405 Remote package tasks should have a retry. ## v1.4.0 diff --git a/tasks/main.yml b/tasks/main.yml index 0d167d0..9d6ae82 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -15,6 +15,8 @@ state: '{{ nft_pkg_state }}' with_items: - '{{ nft_pkg_list | to_nice_json }}' + register: pkg_install_result + until: pkg_install_result is success when: nft_enabled|bool - name: INSTALL Remove iptables packages @@ -23,6 +25,8 @@ state: '{{ nft_old_pkg_state }}' with_items: - '{{ nft_old_pkg_list | to_nice_json }}' + register: pkg_remove_result + until: pkg_remove_result is success when: (nft_enabled|bool and nft_old_pkg_manage|bool)