Files
pen2post/Server/htr-api.service
2026-01-28 20:39:59 -08:00

30 lines
782 B
Desktop File

# ===========================================
# HTR FastAPI Service
# Reads configuration from /home/fenix/htr-api/.env
# ===========================================
# BACKUP COPY - After editing, run:
# sudo cp ~/htr-api/htr-api.service /etc/systemd/system/
# sudo systemctl daemon-reload && sudo systemctl restart htr-api
# ===========================================
[Unit]
Description=HTR FastAPI Service
After=network.target vllm-htr.service
Wants=vllm-htr.service
[Service]
Type=simple
User=fenix
WorkingDirectory=/home/fenix/htr-api
# Load environment variables from .env
EnvironmentFile=/home/fenix/htr-api/.env
ExecStart=/home/fenix/htr-api/venv/bin/uvicorn main:app --host 0.0.0.0 --port 8000
Restart=on-failure
RestartSec=5
[Install]
WantedBy=multi-user.target