Skip to content

Commit 09aeb80

Browse files
add option to not configure nat (#187)
Co-authored-by: Kyle Lexmond <kyl191@users.noreply.github.com>
1 parent 1579e39 commit 09aeb80

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

defaults/main/role.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ iptables_service: iptables
1919
manage_firewall_rules: true
2020
openvpn_firewall: auto
2121
openvpn_masquerade_not_snat: false
22+
openvpn_no_nat: false
2223

2324
# Misc
2425
ci_build: false

tasks/iptables.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@
6969
jump: SNAT
7070
action: insert
7171
comment: "Perform NAT readdressing"
72-
when: not openvpn_masquerade_not_snat
72+
when: not openvpn_masquerade_not_snat and not openvpn_no_nat
7373
notify: "save iptables"
7474

7575
- name: Perform NAT readdressing with MASQUERADE - iptables
@@ -80,7 +80,7 @@
8080
jump: MASQUERADE
8181
action: insert
8282
comment: "Perform NAT readdressing"
83-
when: openvpn_masquerade_not_snat
83+
when: openvpn_masquerade_not_snat and not openvpn_no_nat
8484
notify:
8585
- Save iptables
8686

0 commit comments

Comments
 (0)