From a386fbf0c0421828e4ce2aabd57d780b99a711ac Mon Sep 17 00:00:00 2001 From: Neo_Chen Date: Tue, 2 May 2023 23:44:44 +0800 Subject: [PATCH] updated WireGuard config template --- vpn/wg-postup.sh | 2 -- vpn/wireguard.conf | 3 +-- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/vpn/wg-postup.sh b/vpn/wg-postup.sh index 74dae9b..adda457 100755 --- a/vpn/wg-postup.sh +++ b/vpn/wg-postup.sh @@ -6,10 +6,8 @@ PEER_IP="$3" LOCAL_IPV6="$4" PEER_IPV6="$5" -ip addr del "$LOCAL_IP" dev "$IF" ip addr add "$LOCAL_IP" peer "$PEER_IP" dev "$IF" if [ "$#" -ge 5 ]; then - ip addr del "$LOCAL_IPV6" dev "$IF" ip addr add "$LOCAL_IPV6" peer "$PEER_IPV6" dev "$IF" fi diff --git a/vpn/wireguard.conf b/vpn/wireguard.conf index 20bfba3..5b3e65b 100644 --- a/vpn/wireguard.conf +++ b/vpn/wireguard.conf @@ -1,6 +1,5 @@ [Interface] -Address = , -PostUp = /path/to/wg-postup.sh +PostUp = /path/to/wg-postup.sh %i # Set MTU to 1412 if using PPP #MTU = 1412 Table = off