Files
ytplayer/systemd.ini

17 lines
394 B
INI

[Unit]
Description=YT Player
After=network.target
[Service]
User=ubuntu
WorkingDirectory=/home/ubuntu/ytplayer
EnvironmentFile=/home/ubuntu/ytplayer/.env
ExecStart=/home/ubuntu/ytplayer/venv/bin/uvicorn app:app \
--host 0.0.0.0 \
--port 5000 \
--workers 4 \
--loop asyncio
Restart=always
RestartSec=5
[Install]
WantedBy=multi-user.target