# Meerkat TaskPanel taskd guard — generated by `install.sh`. # # Keeps the board server (`src/server/main.mjs`) alive: systemd restarts it after # ANY exit — a crash, a SIGKILL, or a clean shutdown. `Restart=always` is # unconditional, so `kill` alone cannot stop it; `systemctl --user stop` stops it # for good. # # This is NOT a scheduled tick (no .timer): it is the single long-running owner of # the data directory's write lock (R1). `install.sh` copies this unit into # ~/.config/systemd/user/ and enables it immediately. # # mkdir -p ~/.config/systemd/user # cp /.meerkat-taskpanel/scheduling/systemd/meerkat-taskpanel-taskd.service ~/.config/systemd/user/ # systemctl --user enable --now meerkat-taskpanel-taskd.service # # ExecStart names the ABSOLUTE node that rendered this unit — never # `/usr/bin/env node`, which systemd would resolve against the *service's* PATH # and which fails outright on a machine whose node lives only under nvm or # Homebrew. The path is version-pinned: after a node upgrade, run # `install.sh --force` to refresh this unit. # # The Environment= line(s) at the end of [Service] carry the operator's # TASKD_DATA_DIR / TASKD_RUNTIME_POINTER when they set either at install time, so # the guard and the CLI resolve the same board. `install.sh` renders them. [Unit] Description=Meerkat TaskPanel taskd (board server) guard StartLimitIntervalSec=60 StartLimitBurst=5 [Service] Type=simple ExecStart={{NODE}} {{SERVER_ENTRY}} Restart=always RestartSec=5 # No StandardOutput/StandardError redirect: taskd writes and rotates # {{LOG}} itself. A redirect into the same file would duplicate every line; # the journal keeps anything written before the logger starts (a config file # that cannot be read). {{ENV_SYSTEMD}} [Install] WantedBy=default.target