[Unit]
Description=Domovoy Bot - Telegram Bot for Apartment Building
After=network.target

[Service]
Type=simple
User=matrixhasyou
Group=matrixhasyou
WorkingDirectory=/home/matrixhasyou/domovoy_bot
Environment="PATH=/home/matrixhasyou/domovoy_bot/venv/bin"
ExecStart=/home/matrixhasyou/domovoy_bot/venv/bin/python /home/matrixhasyou/domovoy_bot/main.py
Restart=always
RestartSec=10
StandardOutput=append:/home/matrixhasyou/domovoy_bot/logs/systemd.log
StandardError=append:/home/matrixhasyou/domovoy_bot/logs/systemd.log

# Limitations
LimitNOFILE=65535
Nice=10
IOSchedulingClass=idle

# Security
NoNewPrivileges=true
PrivateTmp=true

[Install]
WantedBy=multi-user.target
