summaryrefslogtreecommitdiff
path: root/images/obfsvpn-client/start.sh
blob: 8de461d9b8a50a08fe66f8bbe66822345348193f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#!/bin/bash

# start the obfsvpn-client
/usr/bin/obfsvpn-client -c "$OBFS4_CERT" &

# use the server container name as remote
if [ -z "$OBFS4_ENDPOINT" ]; then
    sed -i "s/(^remote) .* ([[:digit:]])/\1 obfsvpn-server \2/1" \
        /vpn/client.ovpn
fi
openvpn --config /vpn/client.ovpn --socks-proxy localhost 8080

# ping -c5 10.8.0.1

exit $?