Created
January 28, 2014 20:39
-
-
Save decnorton/8675882 to your computer and use it in GitHub Desktop.
VPN Routing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
sudo mv ip-up /etc/ppp/ip-up | |
sudo chmod a+x /etc/ppp/ip-up | |
sudo chown root /etc/ppp/ip-up |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# VPN server IP | |
VPN_IP = "217.37.8.253" | |
# Office subnet | |
# http://www.aelius.com/njh/subnet_sheet.html | |
VPN_SUBNET = "172.16.50.0/24" | |
if [ "${5:-}" = $VPN_IP ] | |
then | |
/sbin/route add $VPN_SUBNET $5 | |
# Add others if necessary. Can be full IP addresses | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment