diff options
author | angristan <angristan@pm.me> | 2019-05-05 13:09:07 +0200 |
---|---|---|
committer | angristan <angristan@pm.me> | 2019-05-05 13:09:07 +0200 |
commit | b78610cb982075b66434eff90ad4dd4e363988b9 (patch) | |
tree | 6a1593256f776ce12081f380b9f55ab2f3ce3152 /wireguard-install.sh | |
parent | c2c27d46ebf66f1ee66ce818444128b07b09b26e (diff) |
Make shellcheck happy
Diffstat (limited to 'wireguard-install.sh')
-rw-r--r-- | wireguard-install.sh | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/wireguard-install.sh b/wireguard-install.sh index 107d7fb..76ed6d5 100644 --- a/wireguard-install.sh +++ b/wireguard-install.sh @@ -56,24 +56,24 @@ Address = $SERVER_WG_IPV4/24,$SERVER_WG_IPV6/64 ListenPort = $SERVER_PORT PrivateKey = $SERVER_PRIV_KEY PostUp = iptables -t nat -A POSTROUTING -o $SERVER_PUB_NIC -j MASQUERADE; ip6tables -t nat -A POSTROUTING -o $SERVER_PUB_NIC -j MASQUERADE -PostDown = iptables -t nat -D POSTROUTING -o $SERVER_PUB_NIC -j MASQUERADE; ip6tables -t nat -D POSTROUTING -o $SERVER_PUB_NIC -j MASQUERADE" > /etc/wireguard/$SERVER_WG_NIC.conf +PostDown = iptables -t nat -D POSTROUTING -o $SERVER_PUB_NIC -j MASQUERADE; ip6tables -t nat -D POSTROUTING -o $SERVER_PUB_NIC -j MASQUERADE" > "/etc/wireguard/$SERVER_WG_NIC.conf" # Add the client as a peer to the server echo "[Peer] PublicKey = $CLIENT_PUB_KEY -AllowedIPs = $CLIENT_WG_IPV4/32,$CLIENT_WG_IPV6/128" >> /etc/wireguard/$SERVER_WG_NIC.conf +AllowedIPs = $CLIENT_WG_IPV4/32,$CLIENT_WG_IPV6/128" >> "/etc/wireguard/$SERVER_WG_NIC.conf" # Create client file with interface echo "[Interface] PrivateKey = $CLIENT_PRIV_KEY Address = $CLIENT_IPV4/24,$CLIENT_IPV6/64 -DNS = $CLIENT_DNS_1,$CLIENT_DNS_2" > ~/$SERVER_WG_NIC-client.conf +DNS = $CLIENT_DNS_1,$CLIENT_DNS_2" > "$HOME/$SERVER_WG_NIC-client.conf" # Add the server as a peer to the client echo "[Peer] PublicKey = $SERVER_PUB_KEY -Endpoint = $SERVER_PUB_IPV4:1194 -AllowedIPs = 0.0.0.0/0,::/0" >> ~/$SERVER_WG_NIC-client.conf +Endpoint = $SERVER_PUB_IP:1194 +AllowedIPs = 0.0.0.0/0,::/0" >> "$HOME/$SERVER_WG_NIC-client.conf" # Enable routing on the server echo "net.ipv4.ip_forward = 1 |