systemd: prometheus files with venv

This commit is contained in:
genofire 2020-06-10 07:28:10 +02:00
parent 38a7b17180
commit 3b451600cf
1 changed files with 4 additions and 2 deletions

View File

@ -5,10 +5,12 @@ Description=ejabberd prometheus exporter
Type=simple
User=nobody
Group=nobody
ExecStart=/opt/ejabberd-metrics/prometheus.py
Environment="VIRTUAL_ENV=/opt/ejabberd-tools/venv"
Environment="PATH=/opt/ejabberd-tools/venv/bin:/usr/local/bin:/usr/bin:/bin"
ExecStart=/opt/ejabberd-tools/prometheus.py
WorkingDirectory=/opt/ejabberd-tools/
Restart=always
RestartSec=5s
Environment=PATH=/usr/bin:/usr/local/bin
[Install]
WantedBy=multi-user.target