diff options
author | V3n3RiX <venerix@koprulu.sector> | 2022-08-15 14:28:19 +0100 |
---|---|---|
committer | V3n3RiX <venerix@koprulu.sector> | 2022-08-15 14:28:19 +0100 |
commit | 1c3adf43f1b866276828623dd63f9e10d29421d3 (patch) | |
tree | 08af6cfc34a399a31fab99fe6691383651b7891c /net-vpn/headscale/files/headscale.initd | |
parent | 49d7633bbfe37c8e50c9cd1815c4210ca0a38d49 (diff) |
gentoo auto-resync : 15:08:2022 - 14:28:19
Diffstat (limited to 'net-vpn/headscale/files/headscale.initd')
-rw-r--r-- | net-vpn/headscale/files/headscale.initd | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/net-vpn/headscale/files/headscale.initd b/net-vpn/headscale/files/headscale.initd index 5a98c0e6cb34..f43b3a55af38 100644 --- a/net-vpn/headscale/files/headscale.initd +++ b/net-vpn/headscale/files/headscale.initd @@ -8,6 +8,7 @@ user="${HEADSCALE_USER}:${HEADSCALE_GROUP}" directory="/var/lib/headscale" output_log="/var/log/headscale.log" error_log="/var/log/headscale.log" +private_key="/var/lib/headscale/private.key" start_stop_daemon_args="--user \"${user}\" ${HEADSCALE_OPTIONS} --background" @@ -23,7 +24,12 @@ start_pre() { fi checkpath -d -m 700 -o "${user}" /run/headscale /var/lib/headscale - checkpath -f -m 600 -o "${user}" /var/lib/headscale/db.sqlite /var/log/headscale.log - checkpath -f -m 600 -o "${user}" /etc/headscale/config.yaml -} + checkpath -f -m 600 -o "${user}" \ + /var/lib/headscale/db.sqlite \ + /var/log/headscale.log \ + /etc/headscale/config.yaml + if [[ -f ${private_key} ]]; then + checkpath -f -m 600 -o "${user}" ${private_key} + fi +} |