X-Git-Url: https://git.adam-barratt.org.uk/?a=blobdiff_plain;f=modules%2Fpostgres%2Fmanifests%2Fbackup_source.pp;h=146726ace08e0693398358ae040c9194d44cbd15;hb=4b78dc516ce80bf4a76c2851a6d9d1962d1f7084;hp=04a324d3b775190cc2411d46d957c4d2498c18f5;hpb=73fb938ab3d2a34960e3b0024d356ff226ccec0a;p=mirror%2Fdsa-puppet.git diff --git a/modules/postgres/manifests/backup_source.pp b/modules/postgres/manifests/backup_source.pp index 04a324d3b..146726ace 100644 --- a/modules/postgres/manifests/backup_source.pp +++ b/modules/postgres/manifests/backup_source.pp @@ -14,12 +14,7 @@ class postgres::backup_source { content => template('roles/postgresql_server/pg-backup-file.conf.erb'), } - if ! $::postgresql_key { - exec { 'create-postgresql-key': - command => '/bin/su - postgres -c \'mkdir -p -m 02700 .ssh && ssh-keygen -C "`whoami`@`hostname` (`date +%Y-%m-%d`)" -P "" -f .ssh/id_rsa -q\'', - onlyif => '/usr/bin/getent passwd postgres > /dev/null && ! [ -e /var/lib/postgresql/.ssh/id_rsa ]' - } - } + ssh::keygen {'postgres': } if $::hostname in [melartin, vittoria] {