Fix the packages installation task.

This commit is contained in:
Andrea Dell'Amico 2019-03-22 17:28:06 +01:00
parent 66bb6e3db4
commit ee585a6ac4
2 changed files with 5 additions and 4 deletions

View File

@ -1,4 +1,8 @@
--- ---
iptables_deb_pkgs:
- iptables
- iptables-persistent
# #
# Reference only. Check the iptables-rules.v4.j2 for the list of accepted variables # Reference only. Check the iptables-rules.v4.j2 for the list of accepted variables
# #

View File

@ -1,10 +1,7 @@
--- ---
- block: - block:
- name: Install the needed iptables packages - name: Install the needed iptables packages
apt: pkg={{ item }} state=present apt: pkg={{ iptables_deb_pkgs }} state=present cache_valid_time=1800
with_items:
- iptables
- iptables-persistent
- name: Create the /etc/iptables directory when needed - name: Create the /etc/iptables directory when needed
file: dest=/etc/iptables state=directory owner=root group=root mode=0755 file: dest=/etc/iptables state=directory owner=root group=root mode=0755