wip
This commit is contained in:
parent
1c9c4e0902
commit
c9eef4fc79
5 changed files with 8 additions and 8 deletions
|
@ -35,6 +35,9 @@ def s2s_peer_specific(metadata):
|
||||||
'id': repo.get_node(peer).metadata.get(f'id'),
|
'id': repo.get_node(peer).metadata.get(f'id'),
|
||||||
'ip': repo.get_node(peer).metadata.get(f'wireguard/my_ip'),
|
'ip': repo.get_node(peer).metadata.get(f'wireguard/my_ip'),
|
||||||
'endpoint': f'{repo.get_node(peer).hostname}:51820',
|
'endpoint': f'{repo.get_node(peer).hostname}:51820',
|
||||||
|
'route': [
|
||||||
|
str(ip_interface(repo.get_node(peer).metadata.get(f'wireguard/my_ip')).network),
|
||||||
|
],
|
||||||
}
|
}
|
||||||
for peer in metadata.get('wireguard/peers')
|
for peer in metadata.get('wireguard/peers')
|
||||||
},
|
},
|
||||||
|
@ -52,10 +55,10 @@ def client_peer_specific(metadata):
|
||||||
client: {
|
client: {
|
||||||
'id': client,
|
'id': client,
|
||||||
'route': [
|
'route': [
|
||||||
'172.30.0.0/24',
|
str(ip_interface(conf['ip']).network),
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
for client in metadata.get('wireguard/clients')
|
for client, conf in metadata.get('wireguard/clients').items()
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
|
@ -62,7 +62,6 @@
|
||||||
'peers': {
|
'peers': {
|
||||||
'htz.mails': {
|
'htz.mails': {
|
||||||
'route': [
|
'route': [
|
||||||
'172.30.0.0/24',
|
|
||||||
'10.0.10.0/24',
|
'10.0.10.0/24',
|
||||||
'10.0.11.0/24',
|
'10.0.11.0/24',
|
||||||
'10.0.20.0/24',
|
'10.0.20.0/24',
|
||||||
|
|
|
@ -162,13 +162,13 @@
|
||||||
},
|
},
|
||||||
'clients': {
|
'clients': {
|
||||||
'macbook': {
|
'macbook': {
|
||||||
'ip': '172.30.0.100/24',
|
'ip': '172.30.0.100/32',
|
||||||
},
|
},
|
||||||
'phone': {
|
'phone': {
|
||||||
'ip': '172.30.0.101/24',
|
'ip': '172.30.0.101/32',
|
||||||
},
|
},
|
||||||
'ipad': {
|
'ipad': {
|
||||||
'ip': '172.30.0.102/24',
|
'ip': '172.30.0.102/32',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
|
@ -35,7 +35,6 @@
|
||||||
'peers': {
|
'peers': {
|
||||||
'htz.mails': {
|
'htz.mails': {
|
||||||
'route': [
|
'route': [
|
||||||
'172.30.0.0/24',
|
|
||||||
'10.0.0.0/24',
|
'10.0.0.0/24',
|
||||||
'10.0.2.0/24',
|
'10.0.2.0/24',
|
||||||
'10.0.9.0/24',
|
'10.0.9.0/24',
|
||||||
|
|
|
@ -26,7 +26,6 @@
|
||||||
'peers': {
|
'peers': {
|
||||||
'htz.mails': {
|
'htz.mails': {
|
||||||
'route': [
|
'route': [
|
||||||
'172.30.0.0/24',
|
|
||||||
'10.0.0.0/24',
|
'10.0.0.0/24',
|
||||||
'10.0.2.0/24',
|
'10.0.2.0/24',
|
||||||
'10.0.9.0/24',
|
'10.0.9.0/24',
|
||||||
|
|
Loading…
Reference in a new issue