Fixes Issue #195

This commit is contained in:
Kaladin Light 2017-01-28 13:58:10 -05:00
parent bfd2c43570
commit faaabe4c0e

View file

@ -245,7 +245,6 @@ chooseInterface() {
if [[ $(echo "${availableInterfaces}" | wc -l) -eq 1 ]]; then if [[ $(echo "${availableInterfaces}" | wc -l) -eq 1 ]]; then
pivpnInterface="${availableInterfaces}" pivpnInterface="${availableInterfaces}"
echo "${pivpnInterface}" > /tmp/pivpnINT echo "${pivpnInterface}" > /tmp/pivpnINT
$SUDO cp /tmp/pivpnINT /etc/pivpn/pivpnINTERFACE
return return
fi fi
@ -267,7 +266,6 @@ chooseInterface() {
pivpnInterface=${desiredInterface} pivpnInterface=${desiredInterface}
echo "::: Using interface: $pivpnInterface" echo "::: Using interface: $pivpnInterface"
echo "${pivpnInterface}" > /tmp/pivpnINT echo "${pivpnInterface}" > /tmp/pivpnINT
$SUDO cp /tmp/pivpnINT /etc/pivpn/pivpnINTERFACE
done done
else else
echo "::: Cancel selected, exiting...." echo "::: Cancel selected, exiting...."
@ -313,7 +311,6 @@ It is also possible to use a DHCP reservation, but if you are going to do that,
# If the settings are correct, then we need to set the pivpnIP # If the settings are correct, then we need to set the pivpnIP
echo "${IPv4addr%/*}" > /tmp/pivpnIP echo "${IPv4addr%/*}" > /tmp/pivpnIP
echo "$pivpnInterface" > /tmp/pivpnINT echo "$pivpnInterface" > /tmp/pivpnINT
$SUDO cp /tmp/pivpnINT /etc/pivpn/pivpnINTERFACE
# After that's done, the loop ends and we move on # After that's done, the loop ends and we move on
ipSettingsCorrect=True ipSettingsCorrect=True
else else
@ -411,6 +408,8 @@ installScripts() {
$SUDO chmod 0755 /usr/local/bin/pivpn $SUDO chmod 0755 /usr/local/bin/pivpn
$SUDO cp /etc/.pivpn/scripts/bash-completion /etc/bash_completion.d/pivpn $SUDO cp /etc/.pivpn/scripts/bash-completion /etc/bash_completion.d/pivpn
. /etc/bash_completion.d/pivpn . /etc/bash_completion.d/pivpn
# Copy interface setting for debug
$SUDO cp /tmp/pivpnINT /etc/pivpn/pivpnINTERFACE
$SUDO echo " done." $SUDO echo " done."
} }