| 1 |
# Spectra as a systemd user service (spec §22.3): agents reconnect to it as |
| 2 |
# they start, so it should outlive any one terminal. |
| 3 |
# |
| 4 |
# cp packaging/spectra.service ~/.config/systemd/user/ |
| 5 |
# systemctl --user daemon-reload && systemctl --user enable --now spectra |
| 6 |
# journalctl --user -u spectra -f |
| 7 |
[Unit] |
| 8 |
Description=Spectra, the control plane for AI coding agents |
| 9 |
After=default.target |
| 10 |
|
| 11 |
[Service] |
| 12 |
ExecStart=%h/.local/bin/spectra serve |
| 13 |
Restart=on-failure |
| 14 |
RestartSec=2 |
| 15 |
# SIGTERM writes a checkpoint and stops within five seconds. |
| 16 |
KillSignal=SIGTERM |
| 17 |
TimeoutStopSec=15 |
| 18 |
Environment=SPECTRA_LOG=info |
| 19 |
|
| 20 |
[Install] |
| 21 |
WantedBy=default.target |