Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Long list of IPs for Routes #44

Open
StanTowers opened this issue Mar 30, 2021 · 1 comment
Open

Long list of IPs for Routes #44

StanTowers opened this issue Mar 30, 2021 · 1 comment

Comments

@StanTowers
Copy link

Hi, I am having troubles incorporating a long list of IPs to define routes with net_gateway without butchering the my docker-compose file. I tried with an env file, but I am not sure how the variable is supposed to be formatted. I want to put the IP ranges from Zoom into it.

https://support.zoom.us/hc/en-us/articles/360053610731-VPN-Split-Tunneling-Recommendations

docker-compose file:

version: "3"
services:
wireguard:
image: wheelybird/openvpn-ldap-otp:latest
container_name: openvpn
restart: unless-stopped
cap_add:
- NET_ADMIN
env_file:
- environment
environment:
- OVPN_SERVER_CN=*********
- LDAP_URI=******
- LDAP_BASE_DN=*******
- LDAP_BIND_USER_DN=******
- LDAP_BIND_USER_PASS=*******
- LDAP_FILTER=*****
- ACTIVE_DIRECTORY_COMPAT_MODE=true
- OVPN_PROTOCOL=udp
- OVPN_INTERFACE_NAME=tun
- OVPN__NETWORK=10.4.0.0 255.255.252.0
- OVPN_NAT=true
- OVPN_DNS_SERVERS=1.1.1.1,1.0.0.1
- OVPN_DNS_SEARCH_DOMAIN=******
- OVPN_REGISTER_DNS=true
- OVPN_ENABLE_COMPRESSION=false
- OVPN_ROUTES=${ROUTES}
#- OVPN_EXTRA=${ROUTES}
# - REGENERATE_CERTS:true
volumes:
- ./config:/config
- /etc/openvpn:/etc/openvpn
- /lib/modules:/lib/modules
ports:
- 1194:1194/udp


env file:

ROUTES=3.21.137.128 255.255.255.128 net_gateway,3.22.11.0 255.255.255.0 net_gateway,3.23.93.0 255.255.255.0 net_gateway, and so on


Is this doable?

@wheelybird
Copy link
Owner

Hi. Routes are a CSV of network netmask, for example 172.16.10.0 255.255.255.0,172.17.20.0 255.255.255.0.
So in your example you need to remove all occurrences of net_gateway. That's a long list of IPs, so I can see why you don't want them in docker-compose.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants