[monit] ajout d'arpwatch

Il faudrait plutôt faire ça avec un service monit duquel dépendent
tous les enfants. Comme pour le initscript de mumudvb, c'est mal foutu
et il n'y a pas de possibilité de restart un seul process.
This commit is contained in:
Daniel STAN 2013-03-08 16:06:17 +01:00
parent 84da529ae2
commit 1226751f10
2 changed files with 13 additions and 1 deletions

View file

@ -1,4 +1,5 @@
# -*- coding: utf-8; mode: python -*-
header()
info["owner"] = "root"
info["group"] = "root"

View file

@ -66,7 +66,18 @@ service("backuppc-server",
service("isc-dhcp-server",
pidf="dhcpd")
# bind's pidfile has changed on squeeze
if has('arpwatch'):
include("arpwatch")
# TODO modeliser ceci par un seul service pour éviter des races débiles
# au moment des restart ...
for vlan in watched_vlans:
iface = 'eth0'
if vlan <> 1:
iface += '.%d' % vlan
service(None, name='arpwatch-%s' % iface,
init='arpwatch',
)
service("bind",
init="bind9",
pidf="named/named")