bundles/wireguard: re-add reconnect script for added resiliency
All checks were successful
kunsi/bundlewrap/pipeline/head This commit looks good
All checks were successful
kunsi/bundlewrap/pipeline/head This commit looks good
This commit is contained in:
parent
13057d6f76
commit
8656f99f8e
2 changed files with 10 additions and 5 deletions
|
@ -4,9 +4,7 @@
|
|||
# it gets connected. Easiest way is to simply send some pings to the
|
||||
# other side.
|
||||
|
||||
% for peer, config in node.metadata.get('wireguard/peers', {}).items():
|
||||
% for ip in sorted(config['ips']):
|
||||
# refresh connection to ${peer} ${ip}
|
||||
/usr/bin/ping -c 4 ${ip.split('/')[0] if '/' in ip else ip}
|
||||
% endfor
|
||||
% for peer, config in sorted(node.metadata.get('wireguard/peers', {}).items()):
|
||||
# refresh connection to ${peer}
|
||||
/usr/bin/ping -c 4 ${config['their_ip']}
|
||||
% endfor
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue