From 11053bbe64ce4c94ebf9859fe1c68b8fdd3da75c Mon Sep 17 00:00:00 2001 From: Madic- <3735459+Madic-@users.noreply.github.com> Date: Sat, 18 Jan 2020 22:50:48 +0100 Subject: [PATCH] Added example for multiple postup/postdown commands --- README.md | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 6c3ca65..acb26ac 100644 --- a/README.md +++ b/README.md @@ -262,8 +262,14 @@ vpn1: wireguard_allowed_ips: "10.9.0.2/32, 192.168.3.0/24" wireguard_persistent_keepalive: 15 wireguard_endpoint: nated.exemple.com - wireguard_postup: "iptables -t nat -A POSTROUTING -o ens12 -j MASQUERADE" - wireguard_postdown: "iptables -t nat -D POSTROUTING -o ens12 -j MASQUERADE" + wireguard_postup: + - iptables -t nat -A POSTROUTING -o ens12 -j MASQUERADE + - iptables -A FORWARD -i %i -j ACCEPT + - iptables -A FORWARD -o %i -j ACCEPT + wireguard_postdown: + - iptables -t nat -D POSTROUTING -o ens12 -j MASQUERADE + - iptables -D FORWARD -i %i -j ACCEPT + - iptables -D FORWARD -o %i -j ACCEPT vpn2: hosts: