💾 Archived View for gmi.runtimeterror.dev › systemctl-edit-delay-service-startup › index.gmi captured on 2024-07-09 at 00:30:02. Gemini links have been rewritten to link to archived content
⬅️ Previous capture (2024-05-10)
-=-=-=-=-=-=-
2023-10-15
Following a recent update, I found that the Linux development environment [1] on my Framework Chromebook would fail to load if the Tailscale [2] daemon was already running. It seems that the Tailscale virtual interface may have interfered with how the CrOS Terminal app was expecting to connect to the Linux container. I initially worked around the problem by just disabling the `tailscaled` service, but having to remember to start it up manually was a pretty heavy cognitive load.
[1] Linux development environment
Fortunately, it turns out that overriding the service to insert a short startup delay is really easy. I'll just use the `systemctl edit` command to create a quick override configuration:
sudo systemctl edit tailscaled
This shows me the existing contents of the `tailscaled.service` definition so I can easily insert some overrides above. In this case, I just want to use `sleep 5` as the `ExecStartPre` command so that the service start will be delayed by 5 seconds:
Upon saving the file, it gets installed to `/etc/systemd/system/tailscaled.service.d/override.conf`. Now the Tailscale interface won't automatically come up until a few seconds later, and that's enough to let my Terminal app start up reliably once more.
Easy peasy.
---
Self-Hosted Gemini Capsule with gempost and GitHub Actions
Tailscale Serve in a Docker Compose Sidecar
---