bundlewrap/bundles/wireguard/items.py
Franzi 58ca3fa9ae
All checks were successful
bundlewrap/pipeline/head This commit looks good
bundles/wireguard: add netdev and network files, add iptables rules
2020-11-21 15:38:38 +01:00

27 lines
678 B
Python

assert node.has_bundle('systemd-networkd')
files = {
'/etc/systemd/network/99-wg0.netdev': {
'source': 'wg0.netdev',
'content_type': 'mako',
'context': node.metadata['wireguard'],
'needs': {
'pkg_apt:wireguard',
},
'triggers': {
'svc_systemd:systemd-networkd:restart',
},
},
'/etc/systemd/network/99-wg0.network': {
'source': 'wg0.network',
'content_type': 'mako',
'context': node.metadata['wireguard'],
'needs': {
'pkg_apt:wireguard',
},
'triggers': {
'svc_systemd:systemd-networkd:restart',
},
},
}