File tree Expand file tree Collapse file tree 1 file changed +11
-6
lines changed Expand file tree Collapse file tree 1 file changed +11
-6
lines changed Original file line number Diff line number Diff line change 87
87
88
88
ip -6 route show default 2> /dev/null
89
89
if [ $? = 0 ]; then
90
- echo " Enabling IPv6 Forwarding"
91
- # If this fails, ensure the docker container is run with --privileged
92
- # Could be side stepped with `ip netns` madness to drop privileged flag
90
+ echo " Checking IPv6 Forwarding"
91
+ if [ " $( < /proc/sys/net/ipv6/conf/all/disable_ipv6) " != " 0" ]; then
92
+ echo " Sysctl error for disable_ipv6, please run docker with '--sysctl net.ipv6.conf.all.disable_ipv6=0'"
93
+ fi
94
+
95
+ if [ " $( < /proc/sys/net/ipv6/conf/default/forwarding) " != " 1" ]; then
96
+ echo " Sysctl error for default forwarding, please run docker with '--sysctl net.ipv6.conf.default.forwarding=1'"
97
+ fi
93
98
94
- sysctl -w net. ipv6. conf. all.disable_ipv6=0 || echo " Failed to enable IPv6 support "
95
- sysctl -w net.ipv6.conf.default .forwarding=1 || echo " Failed to enable IPv6 Forwarding default "
96
- sysctl -w net.ipv6.conf.all.forwarding=1 || echo " Failed to enable IPv6 Forwarding "
99
+ if [ " $( < /proc/sys/ net/ ipv6/ conf/ all/forwarding ) " != " 1 " ] ; then
100
+ echo " Sysctl error for all forwarding, please run docker with '--sysctl net.ipv6.conf.all .forwarding=1' "
101
+ fi
97
102
fi
98
103
99
104
echo " Running 'openvpn ${ARGS[@]} ${USER_ARGS[@]} '"
You can’t perform that action at this time.
0 commit comments