Skip to content

Commit

Permalink
README
Browse files Browse the repository at this point in the history
  • Loading branch information
vladimirok5959 committed Sep 2, 2018
1 parent c3cf1ec commit f8b766d
Showing 1 changed file with 37 additions and 2 deletions.
39 changes: 37 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,47 @@
# bash-pptp-auto-reconnect
Auto start/reconnect for vpn pptp

## Install client
```
apt-get install pptp-linux
mcedit /etc/ppp/chap-secrets
```

## Add VPN user
```
# Secrets for authentication using CHAP
# client server secret IP addresses
vpnconn PPTP pass *
```

```
touch /etc/ppp/peers/vpnconn
mcedit /etc/ppp/peers/vpnconn
```

## Add VPN connection
```
pty "pptp 178.20.158.9 --nolaunchpppd"
name vpnconn
remotename PPTP
require-mppe-128
defaultroute
replacedefaultroute
file /etc/ppp/options.pptp
ipparam vpnconn
```

## Script location
```
Location: /usr/local/bin/vpn
Usage: vpn "ppp0" "10.0.0.1" "connection name"
```

## Usage
```
Usage: vpn "ppp0" "10.0.0.1" "vpnconn"
```

## Crontab
```
/etc/crontab
* * * * * root /usr/local/bin/vpn "ppp0" "10.0.0.1" "vpnconn" >/dev/null
```

0 comments on commit f8b766d

Please sign in to comment.