monit: fix pidfile pour apache2 (>=jessie)

This commit is contained in:
Daniel STAN 2015-08-05 18:03:41 +02:00
parent c3145dbfc0
commit b4287a0a62

View file

@ -56,14 +56,15 @@ service("apache",
name="apache2",
extra=[ has("http-server") and "if failed host localhost port 80 protocol http timeout 30 seconds then restart",
has("https-server") and "if failed host localhost port 443 type tcpssl protocol http timeout 30 seconds then restart",
has("intranet-server") and "if failed host intranet.crans.org port 443 type tcpssl protocol http timeout 30 seconds then restart",
"if cpu is greater than 60% for 2 cycles then alert",
"if cpu > 80% for 5 cycles then restart",
has("users") and "if totalmem > 4 GB for 5 cycles then restart" or "if totalmem > 500.0 MB for 5 cycles then restart",
"if children > 250 then restart",
"if loadavg(5min) greater than 10 for 8 cycles then restart",
],
max_restart=3)
max_restart=3,
pidf='apache2/apache2' if not has('wheezy') else 'apache2',
)
service('nginx')