add systemd service

This commit is contained in:
Christoph Haas 2026-01-17 22:45:46 +01:00
parent 64323c366f
commit 035751acda
2 changed files with 23 additions and 0 deletions

15
matrix.service Normal file
View file

@ -0,0 +1,15 @@
[Unit]
Description=Matrix Flask Application
After=network.target
[Service]
Type=simple
WorkingDirectory=/opt/matrix
ExecStart=/usr/bin/gunicorn -b 0.0.0.0 -w 1 -k gthread main:app
Restart=always
RestartSec=5s
User=root
Group=root
[Install]
WantedBy=multi-user.target