Skip to content

Commit 9e9eac7

Browse files
committed
Reduce use of deprecated Ansible 'features'
1 parent 1a41957 commit 9e9eac7

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

applyFirewall.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
- name: Allow ssh only from jumphosts
3737
ufw:
3838
rule: allow
39-
from_ip: "{{ hostvars[item].ansible_default_ipv4.address }}"
39+
from_ip: "{{ hostvars[item].ansible_facts['default_ipv4'].address }}"
4040
port: 22
4141
loop: "{{ groups['jumphost'] }}"
4242

@@ -166,7 +166,7 @@
166166
- name: Allow rsync from services
167167
ufw:
168168
rule: allow
169-
from_ip: "{{ hostvars[item].ansible_eth1.ipv4.address }}"
169+
from_ip: "{{ hostvars[item].ansible_facts['eth1'].ipv4.address }}"
170170
port: 873
171171
loop: "{{ groups['service'] }}"
172172

0 commit comments

Comments
 (0)