[wiki/macro/MonitStatus] /usr/scripts/monit -> /usr/scripts/var/monit
This commit is contained in:
parent
4e62a2b84e
commit
4ae7ea0ecf
1 changed files with 2 additions and 2 deletions
|
@ -12,7 +12,7 @@ Exemple :
|
||||||
[[MonitStatus(All|Off|service@host)
|
[[MonitStatus(All|Off|service@host)
|
||||||
"""
|
"""
|
||||||
|
|
||||||
statusfolder = '/usr/scripts/monit/status'
|
statusfolder = '/usr/scripts/var/monit/status'
|
||||||
|
|
||||||
def NotRunningHosts() :
|
def NotRunningHosts() :
|
||||||
"""
|
"""
|
||||||
|
@ -21,7 +21,7 @@ def NotRunningHosts() :
|
||||||
"""
|
"""
|
||||||
hosts = []
|
hosts = []
|
||||||
for host in os.listdir(statusfolder) :
|
for host in os.listdir(statusfolder) :
|
||||||
if os.path.getmtime('/usr/scripts/monit/status/%s' % host) < time.time() - 240 :
|
if os.path.getmtime('%s/%s' % (statusfolder,host)) < time.time() - 240 :
|
||||||
hosts.append(host)
|
hosts.append(host)
|
||||||
return hosts
|
return hosts
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue