In this example an image is created to connect to an OpenConnect VPN server,
and then it provides a SOCKS5 proxy service via ssh -D
to a server in the VPN zone.
So SSH_HOST
refers to a host in the VPN zone with SSH service enabled.
The commands to create the image:
git clone https://github.com/mbizhani/Dockage.git
cd Dockage/Image/OpenConnect.SOCKS/
docker build -t opencon-socks:01 .
docker run -it --rm \
-e VPN_HOST='' \
-e VPN_USER='' \
-e VPN_PASS='' \
-e SSH_HOST='' \
-e SSH_USER='' \
-e SSH_PASS='' \
-p 5511:5511 \
--cap-add=NET_ADMIN \
opencon-socks:01
Other environment variables
VPN_CERT
- the scriptrun-openconnect.sh
trys to find the--servercert
. If not, pass it through this env var.VPN_PROTO
(defaultanyconnect
) - It can beanyconnect
,nc
,gp
, andpulse
anyconnect
- Compatible with Cisco AnyConnect SSL VPN, as well asocserv
(default)nc
- Compatible with Juniper Network Connectgp
- Compatible with Palo Alto Networks (PAN) GlobalProtect SSL VPNpulse
- Compatible with Pulse Connect Secure SSL VPN