mirror of
https://github.com/prometheus-community/ansible
synced 2024-11-26 05:40:18 +00:00
dcfbfa84d2
Signed-off-by: Paweł Krupa (paulfantom) <pawel@krupa.net.pl>
23 lines
543 B
Django/Jinja
23 lines
543 B
Django/Jinja
[Unit]
|
|
Description=Prometheus SNMP Exporter
|
|
After=network-online.target
|
|
StartLimitInterval=0
|
|
|
|
[Service]
|
|
Type=simple
|
|
User=nobody
|
|
Group={{ 'nogroup' if ansible_os_family == 'Debian' else 'nobody' }}
|
|
ExecReload=/bin/kill -HUP $MAINPID
|
|
ExecStart=/usr/local/bin/snmp_exporter \
|
|
--web.listen-address={{ snmp_exporter_web_listen_address }} \
|
|
--log.level={{ snmp_exporter_log_level }} \
|
|
--config.file=/etc/snmp_exporter/snmp.yml
|
|
|
|
KillMode=process
|
|
|
|
SyslogIdentifier=snmp_exporter
|
|
Restart=always
|
|
RestartSec=1
|
|
|
|
[Install]
|
|
WantedBy=multi-user.target
|