From: Peter Palfrader Date: Mon, 25 Dec 2017 12:17:35 +0000 (+0100) Subject: Move crontab pg base backup into dsa-puppet-stuff X-Git-Url: https://git.adam-barratt.org.uk/?a=commitdiff_plain;h=f39815c7f91442ee646226e3a0114edc17373593;p=mirror%2Fdsa-puppet.git Move crontab pg base backup into dsa-puppet-stuff --- diff --git a/modules/postgres/manifests/backup_server.pp b/modules/postgres/manifests/backup_server.pp index 653b5f88d..e95c4aea3 100644 --- a/modules/postgres/manifests/backup_server.pp +++ b/modules/postgres/manifests/backup_server.pp @@ -36,13 +36,22 @@ class postgres::backup_server { | EOTEMPLATE order => '99', } + file { '/etc/cron.d/puppet-postgres-make-base-backups': + ensure => absent; + } if $::hostname in [backuphost] { - file { '/etc/cron.d/puppet-postgres-make-base-backups': - content => "20 1 * * 0 debbackup chronic ${$postgres::backup_server::globals::make_base_backups}\n", + concat::fragment { 'dsa-puppet-stuff--porterbox-chroot-update': + target => '/etc/cron.d/dsa-puppet-stuff', + content => @("EOF") + 20 1 * * 0 debbackup chronic ${$postgres::backup_server::globals::make_base_backups} + | EOF } } else { - file { '/etc/cron.d/puppet-postgres-make-base-backups': - content => "20 0 * * 6 debbackup chronic ${$postgres::backup_server::globals::make_base_backups}\n", + concat::fragment { 'dsa-puppet-stuff--porterbox-chroot-update': + target => '/etc/cron.d/dsa-puppet-stuff', + content => @("EOF") + 20 0 * * 6 debbackup chronic ${$postgres::backup_server::globals::make_base_backups} + | EOF } }