mirror of
https://github.com/Ysurac/openmptcprouter-vps-admin.git
synced 2025-03-09 15:40:05 +00:00
Use DHCP for all VPNs
This commit is contained in:
parent
0d10191dcd
commit
dee3add694
1 changed files with 5 additions and 3 deletions
|
@ -153,9 +153,11 @@ def config():
|
||||||
if 'PORT=' in line:
|
if 'PORT=' in line:
|
||||||
glorytun_port = line.replace(line[:5], '').rstrip()
|
glorytun_port = line.replace(line[:5], '').rstrip()
|
||||||
glorytun_tcp_host_ip = '10.255.255.1'
|
glorytun_tcp_host_ip = '10.255.255.1'
|
||||||
glorytun_tcp_client_ip = '10.255.255.2'
|
#glorytun_tcp_client_ip = '10.255.255.2'
|
||||||
|
glorytun_tcp_client_ip = 'dhcp'
|
||||||
glorytun_udp_host_ip = '10.255.254.1'
|
glorytun_udp_host_ip = '10.255.254.1'
|
||||||
glorytun_udp_client_ip = '10.255.254.2'
|
#glorytun_udp_client_ip = '10.255.254.2'
|
||||||
|
glorytun_udp_client_ip = 'dhcp'
|
||||||
available_vpn = ["glorytun-tcp", "glorytun-udp"]
|
available_vpn = ["glorytun-tcp", "glorytun-udp"]
|
||||||
|
|
||||||
if os.path.isfile('/etc/openvpn/server/static.key'):
|
if os.path.isfile('/etc/openvpn/server/static.key'):
|
||||||
|
@ -172,7 +174,7 @@ def config():
|
||||||
if 'port ' in line:
|
if 'port ' in line:
|
||||||
openvpn_port = line.replace(line[:5], '').rstrip()
|
openvpn_port = line.replace(line[:5], '').rstrip()
|
||||||
openvpn_host_ip = '10.255.253.1'
|
openvpn_host_ip = '10.255.253.1'
|
||||||
openvpn_client_ip = '10.255.253.2'
|
#openvpn_client_ip = '10.255.253.2'
|
||||||
|
|
||||||
if os.path.isfile('/etc/mlvpn/mlvpn0.conf'):
|
if os.path.isfile('/etc/mlvpn/mlvpn0.conf'):
|
||||||
mlvpn_config = configparser.ConfigParser()
|
mlvpn_config = configparser.ConfigParser()
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue