From bff7d1b743bc2239d7ce7ced37dd03e4e846c03d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Isma=C3=ABl=20Bouya?= Date: Tue, 10 Jul 2018 10:45:04 +0200 Subject: Add monitoring for backup --- modules/profile/manifests/postgresql/backup_dump.pp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'modules/profile/manifests/postgresql') diff --git a/modules/profile/manifests/postgresql/backup_dump.pp b/modules/profile/manifests/postgresql/backup_dump.pp index 5e469c5..5f456ed 100644 --- a/modules/profile/manifests/postgresql/backup_dump.pp +++ b/modules/profile/manifests/postgresql/backup_dump.pp @@ -60,10 +60,10 @@ define profile::postgresql::backup_dump ( @profile::monitoring::local_service { "Last postgresql dump in $pg_backup_path is not too old": sudos => { - "naemon-postgresql-dumps" => "naemon ALL=($pg_user) NOPASSWD: /usr/bin/find $pg_backup_path -mindepth 1 -maxdepth 1 -printf %T@\\n", - } + "naemon-postgresql-dumps-$pg_host" => "naemon ALL=($pg_user) NOPASSWD: /usr/bin/find $pg_backup_path -mindepth 1 -maxdepth 1 -printf %T@?n", + }, local => { - check_command => "check_last_file_date!$pg_backup_path!10!$pg_user" + check_command => "check_last_file_date!$pg_backup_path!10!$pg_user", } } } -- cgit v1.2.3