Skip to content

Commit

Permalink
openvpn.sh fix dperson#232
Browse files Browse the repository at this point in the history
  • Loading branch information
David Personette committed Mar 20, 2020
1 parent 893049a commit 1a6221a
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions openvpn.sh
Original file line number Diff line number Diff line change
Expand Up @@ -257,8 +257,12 @@ route6="$dir/.firewall6"
[[ "${DNS:-""}" ]] && dns
[[ "${GROUPID:-""}" =~ ^[0-9]+$ ]] && groupmod -g $GROUPID -o vpn
[[ "${FIREWALL:-""}" || -e $route ]] && firewall "${FIREWALL:-""}"
[[ "${ROUTE6:-""}" ]] && return_route6 "$ROUTE6"
[[ "${ROUTE:-""}" ]] && return_route "$ROUTE"
while read i; do
return_route6 "$i"
done < <(env | awk '/^ROUTE6[=_]/ {sub (/^[^=]*=/, "", $0); print}')
while read i; do
return_route "$i"
done < <(env | awk '/^ROUTE[=_]/ {sub (/^[^=]*=/, "", $0); print}')
[[ "${VPN:-""}" ]] && eval vpn $(sed 's/^/"/; s/$/"/; s/;/" "/g' <<< $VPN)
while read i; do
vpnportforward "$i"
Expand Down

0 comments on commit 1a6221a

Please sign in to comment.