version: '2' services: vpn: container_name: vpn image: jetbrainsinfra/openvpn volumes: - ./test:/vpn:ro cap_add: - NET_ADMIN devices: - /dev/net/tun:/dev/net/tun dns: 10.0.0.1 environment: - VPN_PASSWORD entrypoint: "sh -c 'echo $$VPN_PASSWORD | openvpn --cd /vpn/ --config lab.ovpn --askpass /dev/stdin'"