binhex / arch-sabnzbdvpn

Docker build script for Arch Linux base with SABnzbd, Privoxy and OpenVPN
GNU General Public License v3.0
49 stars 9 forks source link

Fix for OpenVPN protocol error #6

Closed adamrbell closed 6 years ago

adamrbell commented 6 years ago

After updating to the latest version of your container I was getting the following error on startup:

Options error: --proto tcp is ambiguous in this context. Please specify --proto tcp-server or --proto tcp-client

This is an OpenVPN error.

I think I've tracked down the issue to the use of the VPN_PROTOCOL variable in both the OpenVPN config and the IPTABLES setup. By creating a separate variable, VPN_PROTOCOL_IPTABLES, I believe the issue is fixed.

binhex commented 6 years ago

This is not the correct fix, the issue is simply that you have defined an incorrect vpn_option, its also not required as protocol is picked up via the ovpn config file. So your fix is to remove the value for that key.

adamrbell commented 6 years ago

I was going to write:

When you say vpn_option do you mean vpn_protocol?

but in doing so I realised the real issue here.

I have not defined a VPN_OPTION env variable (which I guess counts as an incorrect one ;) ). My xml template for the container appears to be significantly different from the one in your repo. I have an env variable called "VPN_PROTOCOL". In the one in your repo it's called "VPN_OPTIONS".

I've created a completely new container (with the up to date template) and the protocol error goes away.

However, there is a new error which I will post in the forums.