From ef7c470244c25e9d393d160334f806b4551cdb4f Mon Sep 17 00:00:00 2001 From: Micke Nordin Date: Wed, 26 Apr 2023 16:28:40 +0200 Subject: [PATCH] If at first you don succeed... --- manifests/script.pp | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) diff --git a/manifests/script.pp b/manifests/script.pp index 5a2beae..ccb03ad 100644 --- a/manifests/script.pp +++ b/manifests/script.pp @@ -327,16 +327,6 @@ class sunetdrive::script ( warn_criteria => ['exit_status=1','max_age=3d'], } } - } else { - # Not common - file { '/root/tasks/backupmultinodedb.sh': - ensure => absent, - } - sunet::scriptherder::cronjob { 'backupmultinodedb': - ensure => absent, - cmd => 'true', - } - } $singlenodes.each | $singlenode| { $multinode = hiera_hash('multinode_mapping')[$singlenode]['server'] $multinodeserver = "${multinode}.${site_name}" @@ -387,6 +377,13 @@ class sunetdrive::script ( warn_criteria => ['exit_status=1','max_age=3d'], } } else { + file { '/root/tasks/backupmultinodedb.sh': + ensure => absent, + } + sunet::scriptherder::cronjob { 'backupmultinodedb': + ensure => absent, + cmd => 'true', + } sunet::scriptherder::cronjob { 'backupdb': cmd => "/root/tasks/backupdb.sh ${backup_server}", hour => '2',