openwisp / docker-openwisp

OpenWISP in docker. For production usage we recommend using the ansible-openwisp2 role.
https://openwisp.io/docs/dev/docker/
BSD 3-Clause "New" or "Revised" License
149 stars 75 forks source link

[bug] OpenVPN tunnels does not work out of the box #231

Closed pandafy closed 1 month ago

pandafy commented 2 years ago

Steps to replicate

  1. Start the development environment
  2. Register a device to the development environment. The default VPN template should get automatically applied to the device.

Expected Outcome An OpenVPN tunnel is established between device and the OpenVPN container. And it is possible to send traffic through it

Actual Outcome OpenVPN on the router fails with following error

Thu Jun  9 17:23:26 2022 daemon.err openvpn(default)[9866]: TLS Error: TLS key negotiation failed to occur within 60 seconds (check your network connectivity)
dberardo-com commented 1 year ago

running the docker distribution of the openvpn container here ... i see no log, and the container is always restarting in k8s ... do you face this issue too ?

dberardo-com commented 1 year ago

ok , i have figured: the VPN_DOMAIN var was not set ... a debug log would be much helpful : https://github.com/openwisp/docker-openwisp/blob/master/images/common/init_command.sh#L30C13-L30C23