wireguard docs: hardcode wg device name to avoid startup fail

This commit is contained in:
bol-van 2022-06-18 11:48:09 +03:00
parent ae499efa3a
commit 8942aac19d

View File

@ -387,9 +387,8 @@ ipt PREROUTING -t mangle -i $DEVICE -m conntrack --ctstate NEW -j CONNMARK --set
--/etc/firewall.zapret.hook.post_up----------------------------
#!/bin/sh
. /opt/zapret/init.d/openwrt/functions
ZAPRET_NFT_TABLE=zapret
DEVICE=wgvps
cat << EOF | nft -f - 2>/dev/null
delete chain inet $ZAPRET_NFT_TABLE my_output
@ -397,9 +396,6 @@ cat << EOF | nft -f - 2>/dev/null
delete chain inet $ZAPRET_NFT_TABLE my_nat
EOF
network_get_device DEVICE wgvps
[ -n "$DEVICE" ] &&
cat << EOF | nft -f -
add chain inet $ZAPRET_NFT_TABLE my_output { type route hook output priority mangle; }
flush chain inet $ZAPRET_NFT_TABLE my_output