diff --git a/openvpn/adjustConfigs.sh b/openvpn/adjustConfigs.sh index f5c64f5d5c..f251377162 100755 --- a/openvpn/adjustConfigs.sh +++ b/openvpn/adjustConfigs.sh @@ -13,14 +13,14 @@ normal=$(tput sgr0) # Just need to double check that the default.ovpn is still there and that the diff to origin looks reasonable. # -display_usage() { +display_usage() { echo "${bold}Hint: read the script before using it${normal}" echo "If you just forgot: ./adjustConfigs.sh " } -# if no arguments supplied, display usage -if [ $# -lt 1 ] -then +# if no arguments supplied, display usage +if [ $# -lt 1 ] +then display_usage exit 1 fi @@ -45,6 +45,9 @@ for configFile in $provider/*.ovpn; # Set user-pass file location sed -i "s/auth-user-pass.*/auth-user-pass \/config\/openvpn-credentials.txt/g" "$configFile" + # Remove up/down resolv-conf script calls (Mullvad) + sed -i "/update-resolv-conf/d" "$configFile" + done echo "Updated all .ovpn files in folder $provider"