mirror of
https://github.com/prometheus-community/ansible
synced 2025-02-17 05:08:28 +00:00
43 lines
1 KiB
Text
43 lines
1 KiB
Text
|
{{ ansible_managed | comment }}
|
||
|
[Unit]
|
||
|
Description=Smokeping Prober
|
||
|
After=network-online.target
|
||
|
StartLimitInterval=0
|
||
|
StartLimitIntervalSec=0
|
||
|
|
||
|
[Service]
|
||
|
Type=simple
|
||
|
User={{ smokeping_prober_system_user }}
|
||
|
Group={{ smokeping_prober_system_group }}
|
||
|
PermissionsStartOnly=true
|
||
|
ExecReload=/bin/kill -HUP $MAINPID
|
||
|
ExecStart={{ smokeping_prober_binary_install_dir }}/smokeping_prober \
|
||
|
--config.file={{ smokeping_prober_config_dir }}//{{ smokeping_prober_config_file }} \
|
||
|
--web.listen-address={{ smokeping_prober_web_listen_address }}
|
||
|
|
||
|
SyslogIdentifier=smokeping_prober
|
||
|
KillMode=process
|
||
|
Restart=always
|
||
|
RestartSec=5
|
||
|
|
||
|
LockPersonality=true
|
||
|
NoNewPrivileges=true
|
||
|
MemoryDenyWriteExecute=true
|
||
|
PrivateTmp=true
|
||
|
ProtectHome=true
|
||
|
RemoveIPC=true
|
||
|
RestrictSUIDSGID=true
|
||
|
|
||
|
AmbientCapabilities=CAP_NET_RAW
|
||
|
{% if (ansible_facts.packages.systemd | first).version is version('232', '>=') %}
|
||
|
ProtectControlGroups=true
|
||
|
ProtectKernelModules=true
|
||
|
ProtectKernelTunables=yes
|
||
|
ProtectSystem=strict
|
||
|
{% else %}
|
||
|
ProtectSystem=full
|
||
|
{% endif %}
|
||
|
|
||
|
[Install]
|
||
|
WantedBy=multi-user.target
|