Update 00-openvpn.sh

This commit is contained in:
Alexandre
2023-12-11 18:03:36 +01:00
committed by GitHub
parent bf37c75b92
commit 47f160482d

View File

@@ -34,8 +34,12 @@ if [[ "$(bashio::config "VPN_ENABLED")" == "yes" ]] && [[ "$(bashio::config "VPN
# Check proto
if grep -q "proto" "$file"; then
echo "... proto not found in your ovpn, assuming UDP"
touch /data/udp
if [ -f /data/tdp ]; then
echo "... proto not found in your ovpn, assuming TDP"
sed -i "250a VPN_PROTOCOL=\"udp\"" /etc/cont-init.d/02-vpn.sh
else
echo "... proto not found in your ovpn, assuming UDP"
fi
fi
fi