diff options
Diffstat (limited to 'deployments/openrc/inet2.initd')
-rwxr-xr-x | deployments/openrc/inet2.initd | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/deployments/openrc/inet2.initd b/deployments/openrc/inet2.initd new file mode 100755 index 0000000..3d12227 --- /dev/null +++ b/deployments/openrc/inet2.initd @@ -0,0 +1,26 @@ +#!/sbin/openrc-run +name="inet2" +description="Sets up wireguard interfaces connected via the host's internet connection" + +extra_started_commands="reloadwg" + +start() { + /usr/local/bin/inet2.sh start + rc-service bird start 2> /dev/null +} + +stop() { + /usr/local/bin/inet2.sh stop + rc-service bird stop 2> /dev/null +} + +restart() { + stop + start +} + +reload() { + /usr/local/bin/inet2.sh reload + rc-service bird restart 2> /dev/null +} + |