mirror of
https://github.com/tailscale/tailscale.git
synced 2026-03-27 10:42:00 -04:00
cmd/tailscaled/*.{target,unit}: add systemd online target
Using the new wait command from #18574 provide a tailscale-online.target that has a similar usage model to the conventional `network-online.target`. Updates #3340 Updates #11504 Signed-off-by: James Tucker <james@tailscale.com>
This commit is contained in:
committed by
James Tucker
parent
a98036b41d
commit
30e12310f1
4
cmd/tailscaled/tailscale-online.target
Normal file
4
cmd/tailscaled/tailscale-online.target
Normal file
@@ -0,0 +1,4 @@
|
||||
[Unit]
|
||||
Description=Tailscale is online
|
||||
Requires=tailscale-wait-online.service
|
||||
After=tailscale-wait-online.service
|
||||
12
cmd/tailscaled/tailscale-wait-online.service
Normal file
12
cmd/tailscaled/tailscale-wait-online.service
Normal file
@@ -0,0 +1,12 @@
|
||||
[Unit]
|
||||
Description=Wait for Tailscale to be online
|
||||
After=tailscaled.service
|
||||
Requires=tailscaled.service
|
||||
|
||||
[Service]
|
||||
Type=oneshot
|
||||
ExecStart=/usr/bin/tailscale wait
|
||||
RemainAfterExit=yes
|
||||
|
||||
[Install]
|
||||
WantedBy=tailscale-online.target
|
||||
Reference in New Issue
Block a user