40 lines
819 B
Desktop File
40 lines
819 B
Desktop File
[Unit]
|
|
Description=YourPart Daemon Service
|
|
Documentation=https://your-part.de
|
|
After=network.target postgresql.service
|
|
Wants=postgresql.service
|
|
|
|
[Service]
|
|
Type=simple
|
|
User=yourpart
|
|
Group=yourpart
|
|
WorkingDirectory=/opt/yourpart
|
|
ExecStart=/usr/local/bin/yourpart-daemon
|
|
ExecReload=/bin/kill -HUP $MAINPID
|
|
Restart=always
|
|
RestartSec=5
|
|
StandardOutput=journal
|
|
StandardError=journal
|
|
SyslogIdentifier=yourpart-daemon
|
|
|
|
# Sicherheitseinstellungen
|
|
NoNewPrivileges=true
|
|
PrivateTmp=true
|
|
ProtectSystem=strict
|
|
ProtectHome=true
|
|
ReadWritePaths=/opt/yourpart/logs /var/log/yourpart
|
|
ProtectKernelTunables=true
|
|
ProtectKernelModules=true
|
|
ProtectControlGroups=true
|
|
|
|
# Umgebungsvariablen
|
|
Environment=NODE_ENV=production
|
|
Environment=PYTHONUNBUFFERED=1
|
|
|
|
# Ressourcenlimits
|
|
LimitNOFILE=65536
|
|
LimitNPROC=4096
|
|
|
|
[Install]
|
|
WantedBy=multi-user.target
|