Add systemd service file

This commit is contained in:
Pim van Pelt
2025-06-16 23:54:55 +02:00
parent 6969e609c0
commit adf033318a

20
govpp-snmp-agentx.service Normal file
View File

@ -0,0 +1,20 @@
[Unit]
Description=GoVPP SNMP AgentX Daemon
After=network.target vpp.service
Requires=netns-dataplane.service
[Service]
Type=simple
ExecStartPre=-+/usr/bin/chmod 660 /run/vpp/stats.sock /run/vpp/api.sock /run/vpp/cli.sock
ExecStartPre=-+/usr/bin/chown :vpp /run/vpp/stats.sock /run/vpp/api.sock /run/vpp/cli.sock
ExecStartPre=-+/usr/bin/chmod 770 /var/agentx /var/agentx/master
ExecStartPre=-+/usr/bin/chown :vpp /var/agentx /var/agentx/master
ExecStart=/usr/sbin/govpp-snmp-agentx -agentx.addr /var/agentx/master -vppcfg /etc/vpp/vppcfg.yaml -vppstats.period 10
User=Debian-snmp
Group=vpp
ExecReload=/bin/kill -HUP $MAINPID
Restart=always
RestartSec=5s
[Install]
WantedBy=multi-user.target