Sign inSign up

devopscorner/openfortivpn

By devopscorner

•Updated almost 4 years ago

DevOps Corner Indonesia - OpenFortiVPN Client Container Image

Image
2

913

devopscorner/openfortivpn repository overview

⁠DevOpsCorner OpenFortiVPN

DevOps Corner Indonesia - OpenFortiVPN Client Container Image

all contributors tags openfortivpn pulls download all view clone issues pull requests forks stars license


⁠Available Tags

⁠Ubuntu
Image nameSize
devopscorner/openfortivpn:latestdocker image size default-openfortivpn
devopscorner/openfortivpn:22.04docker image size latest-ubuntu
devopscorner/openfortivpn:22.04-latestdocker image size
devopscorner/openfortivpn:22.04-1.19.0docker image size
devopscorner/openfortivpn:20.04docker image size
devopscorner/openfortivpn:20.04-latestdocker image size
devopscorner/openfortivpn:20.04-1.19.0docker image size

⁠Environment

ENV VPN_HOST host
ENV VPN_PORT port
ENV VPN_ADDR host:port
ENV VPN_USER user@domain
ENV VPN_PASS secret
ENV VPN_TRUST_CERT 1234567890987654321
ENV VPN_TIMEOUT 10

⁠Linux

# Create a docker network, to be able to control addresses
docker network create --subnet=172.20.0.0/16 openfortivpn

# Start the priviledged docker container with a static ip
docker run -it --rm \
  --privileged \
  --net openfortivpn --ip 172.20.0.2 \
  -e VPN_HOST=host \
  -e VPN_PORT=port \
  -e VPN_ADDR=host:port \
  -e VPN_USER=user@domain \
  -e VPN_PASS=secret \
  -e VPN_TRUST_CERT=1234567890987654321
  devopscorner/openfortivpn

# Add route for you remote subnet (ex. 10.201.0.0/16)
ip route add 10.201.0.0/16 via 172.20.0.2

# Access remote host from the subnet
ssh 10.201.8.1

⁠OSX

# Create a docker-machine and configure shell to use it
docker-machine create openfortivpn --driver virtualbox
eval $(docker-machine env openfortivpn)

# Start the priviledged docker container on its host network
docker run -it --rm \
  --privileged --net host \
  -e VPN_HOST=host \
  -e VPN_PORT=port \
  -e VPN_ADDR=host:port \
  -e VPN_USER=user@domain \
  -e VPN_PASS=secret \
  -e VPN_TRUST_CERT=1234567890987654321
  devopscorner/openfortivpn

# Add route for you remote subnet (ex. 10.201.0.0/16)
sudo route add -net 10.201.0.0/16 $(docker-machine ip openfortivpn)

# Access remote host from the subnet
ssh 10.201.8.1

⁠Misc

If you don't want to use a docker network, you can find out the container ip once it is started with:

# Find out the container IP
docker inspect --format '{{ .NetworkSettings.IPAddress }}' <container>

⁠Repository URL


  • Author: Dwi Fahni Denni (@zeroc0d3)
  • Vendor: DevOps Corner Indonesia (devopscorner.id)
  • License: Apache v2

Tag summary

Content type

Image

Digest

sha256:408e84576…

Size

133 MB

Last updated

almost 4 years ago

docker pull devopscorner/openfortivpn