thermograph/infra/deploy/thermograph-dev.service
Emi Griffith ae1d9bb534 Subtree-merge thermograph-infra (origin/main) into infra/
git-subtree-dir: infra
git-subtree-mainline: d6df04eab2
git-subtree-split: 99b4b3f78d
2026-07-22 22:01:11 -07:00

20 lines
706 B
Desktop File

# systemd --user unit for the Thermograph LAN dev server.
# Installed by deploy/deploy-dev.sh into ~/.config/systemd/user/ with the
# @PLACEHOLDER@ tokens substituted for this machine's paths/port.
# Runs sudo-free as your own user; linger keeps it up across logout/reboot.
[Unit]
Description=Thermograph (dev, LAN) - FastAPI/uvicorn
After=network-online.target
Wants=network-online.target
[Service]
Type=exec
WorkingDirectory=@APP_DIR@/backend
Environment=THERMOGRAPH_BASE=@BASE@
# Bind all interfaces so other devices on the LAN (e.g. your phone) can reach it.
ExecStart=@APP_DIR@/.venv/bin/uvicorn app:app --host 0.0.0.0 --port @PORT@
Restart=on-failure
RestartSec=2
[Install]
WantedBy=default.target