File tree Expand file tree Collapse file tree 3 files changed +18
-4
lines changed Expand file tree Collapse file tree 3 files changed +18
-4
lines changed Original file line number Diff line number Diff line change 238
238
[ ${# TMP_DNS_SERVERS[@]} -gt 0 ] && OVPN_DNS_SERVERS=(" ${TMP_DNS_SERVERS[@]} " )
239
239
240
240
# Server name is in the form "udp://vpn.example.com:1194"
241
- if [[ " ${OVPN_SERVER_URL:- } " =~ ^(( udp| tcp):// )? ([0 - 9 a- zA- Z\.\- ]+ )(: ([0 - 9 ]+ )) ? $ ]]; then
241
+ if [[ " ${OVPN_SERVER_URL:- } " =~ ^(( udp| tcp| udp 6 | tcp 6 ):// )? ([0 - 9 a- zA- Z\.\- ]+ )(: ([0 - 9 ]+ )) ? $ ]]; then
242
242
OVPN_PROTO=${BASH_REMATCH[2]} ;
243
243
OVPN_CN=${BASH_REMATCH[3]} ;
244
244
OVPN_PORT=${BASH_REMATCH[5]} ;
Original file line number Diff line number Diff line change @@ -37,8 +37,15 @@ nobind
37
37
dev $OVPN_DEVICE
38
38
key-direction 1
39
39
remote-cert-tls server
40
- remote $OVPN_CN $OVPN_PORT $OVPN_PROTO
41
- $OVPN_ADDITIONAL_CLIENT_CONFIG
40
+
41
+ remote $OVPN_CN $OVPN_PORT $OVPN_PROTO "
42
+ if [ " $OVPN_PROTO " == " udp6" ]; then
43
+ echo " remote $OVPN_CN $OVPN_PORT udp"
44
+ fi
45
+ if [ " $OVPN_PROTO " == " tcp6" ]; then
46
+ echo " remote $OVPN_CN $OVPN_PORT tcp"
47
+ fi
48
+ echo " $OVPN_ADDITIONAL_CLIENT_CONFIG
42
49
"
43
50
if [ " $mode " == " combined" ]; then
44
51
echo "
Original file line number Diff line number Diff line change @@ -91,4 +91,11 @@ Fire up a web browser and attempt to navigate to [https://ipv6.google.com](https
91
91
92
92
## Connect to the OpenVPN Server Over IPv6
93
93
94
- Not implemented, yet.
94
+ This feature requires a docker daemon with working IPv6 support.
95
+
96
+ This will allow connections over IPv4 and IPv6.
97
+
98
+ Generate server configuration with the udp6 or tcp6 protocol:
99
+
100
+ docker run -v $OVPN_DATA:/etc/openvpn --rm kylemanna/openvpn ovpn_genconfig -u udp6://VPN.SERVERNAME.COM
101
+ docker run -v $OVPN_DATA:/etc/openvpn --rm kylemanna/openvpn ovpn_genconfig -u tcp6://VPN.SERVERNAME.COM
You can’t perform that action at this time.
0 commit comments