wiregiard_client_config dont assume server node

This commit is contained in:
mwiegand 2022-02-15 09:18:57 +01:00
parent f9790912a6
commit 69ce72aa7b

View file

@ -7,8 +7,8 @@ from ipaddress import ip_network, ip_interface
repo = Repository(dirname(dirname(realpath(__file__))))
server_node = repo.get_node('netcup.mails')
data = server_node.metadata.get(f'wireguard/clients/{argv[1]}')
server_node = repo.get_node(argv[2])
data = server_node.metadata.get(f'wireguard/clients/{argv[2]}')
vpn_network = ip_interface(server_node.metadata.get('wireguard/my_ip')).network
allowed_ips = [