Get VPN functional tests working in docker container
@kali You asked me for a plain kvm machine in order to run the functional tests.
Right now they fail due to a missing /dev/net/tun
device.
I think this is still possible inside docker.
What we need:
-
/dev/net/tun access -
iptables -
policykit, see #8911
With plain docker the first two topics are covered by passing --cap-add=NET_ADMIN --device /dev/net/tun
to docker (see also https://hub.docker.com/r/dperson/openvpn-client/):
root@Beluga:/etc/gitlab-runner# docker run --cap-add=NET_ADMIN --device /dev/net/tun -it 0xacab.org:4567/leap/docker/debian:stretch_amd64 bash
root@260401c2381a:/# ls /dev/net/tun
/dev/net/tun
root@260401c2381a:/# iptables -nL
Chain INPUT (policy ACCEPT)
target prot opt source destination
Chain FORWARD (policy ACCEPT)
target prot opt source destination
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
Edited by Kali Kaneko