projects
/
mirror
/
dsa-puppet.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
f730778
)
postgresql_key -> postgres_key
author
Peter Palfrader
<peter@palfrader.org>
Sat, 7 Sep 2019 15:23:56 +0000
(17:23 +0200)
committer
Peter Palfrader
<peter@palfrader.org>
Sat, 7 Sep 2019 15:23:56 +0000
(17:23 +0200)
modules/debian_org/lib/facter/roleaccounts.rb
patch
|
blob
|
history
modules/postgres/manifests/backup_server/register_backup_clienthost.pp
patch
|
blob
|
history
modules/postgres/manifests/backup_source.pp
patch
|
blob
|
history
spec/octocatalog/facts/godard.debian.org.json
patch
|
blob
|
history
spec/octocatalog/facts/sibelius.debian.org.json
patch
|
blob
|
history
diff --git
a/modules/debian_org/lib/facter/roleaccounts.rb
b/modules/debian_org/lib/facter/roleaccounts.rb
index
f00623f
..
fc6a620
100644
(file)
--- a/
modules/debian_org/lib/facter/roleaccounts.rb
+++ b/
modules/debian_org/lib/facter/roleaccounts.rb
@@
-1,7
+1,7
@@
begin
require 'etc'
begin
require 'etc'
- %w{git}.each do |user|
+ %w{git
postgres
}.each do |user|
Facter.add("#{user}_user_exists") do
setcode do
result = false
Facter.add("#{user}_user_exists") do
setcode do
result = false
@@
-33,17
+33,6
@@
begin
end
end
end
end
- Facter.add("postgresql_key") do
- setcode do
- key = nil
- keyfile = '/var/lib/postgresql/.ssh/id_rsa.pub'
- if FileTest.exist?(keyfile)
- key = File.open(keyfile).read.chomp
- end
- key
- end
- end
-
Facter.add("staticsync_key") do
setcode do
key = nil
Facter.add("staticsync_key") do
setcode do
key = nil
diff --git
a/modules/postgres/manifests/backup_server/register_backup_clienthost.pp
b/modules/postgres/manifests/backup_server/register_backup_clienthost.pp
index
e6c27d1
..
189d371
100644
(file)
--- a/
modules/postgres/manifests/backup_server/register_backup_clienthost.pp
+++ b/
modules/postgres/manifests/backup_server/register_backup_clienthost.pp
@@
-1,6
+1,6
@@
#
define postgres::backup_server::register_backup_clienthost (
#
define postgres::backup_server::register_backup_clienthost (
- $sshpubkey = $::postgres
ql
_key,
+ $sshpubkey = $::postgres_key,
$ipaddrlist = join(getfromhash($site::nodeinfo, 'ldap', 'ipHostNumber'), ","),
$hostname = $::hostname,
) {
$ipaddrlist = join(getfromhash($site::nodeinfo, 'ldap', 'ipHostNumber'), ","),
$hostname = $::hostname,
) {
diff --git
a/modules/postgres/manifests/backup_source.pp
b/modules/postgres/manifests/backup_source.pp
index
04a324d
..
d67f675
100644
(file)
--- a/
modules/postgres/manifests/backup_source.pp
+++ b/
modules/postgres/manifests/backup_source.pp
@@
-14,8
+14,8
@@
class postgres::backup_source {
content => template('roles/postgresql_server/pg-backup-file.conf.erb'),
}
content => template('roles/postgresql_server/pg-backup-file.conf.erb'),
}
- if ! $::postgres
ql
_key {
- exec { 'create-postgres
ql
-key':
+ if ! $::postgres_key {
+ exec { 'create-postgres-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 ]'
}
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 ]'
}
diff --git
a/spec/octocatalog/facts/godard.debian.org.json
b/spec/octocatalog/facts/godard.debian.org.json
index
3d59924
..
5243599
100644
(file)
--- a/
spec/octocatalog/facts/godard.debian.org.json
+++ b/
spec/octocatalog/facts/godard.debian.org.json
@@
-197,7
+197,7
@@
"mptraid": false,
"aacraid": false,
"swraid": false,
"mptraid": false,
"aacraid": false,
"swraid": false,
- "postgres
ql
_key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC1eOzsdKsfcHFyn4fimLNeT8+KhtDqtRceH71j6k3yBUzsNzdQyjx+iSNONRLB7VYGuhRI8o1uZ4kLnpVZLDBGswBKg8Ndf89l36Fsw3BtCsgGITALWKPJ3mW3YToofbQtq9NWY9bkjA4KoUmIK4c/BJzdX6TvF8H1lWvsdphONe6p8Po3USvo5VQaQcxWzPcGlzKwsaX4djn+UVVPr+CsCZqXW9SOFxOEZEDCn4hIiJnVzh1/r0aOJfFWXrXRLmGX1CJwMUCUVZc4g39mPFfEzh0gWxPmMSP5Q0vsYK7RgQH+JKdmxYiqasfY06px87Wp5Xl2+UzToHUURSOnM+s3 postgres@godard (2017-09-01)",
+ "postgres_key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC1eOzsdKsfcHFyn4fimLNeT8+KhtDqtRceH71j6k3yBUzsNzdQyjx+iSNONRLB7VYGuhRI8o1uZ4kLnpVZLDBGswBKg8Ndf89l36Fsw3BtCsgGITALWKPJ3mW3YToofbQtq9NWY9bkjA4KoUmIK4c/BJzdX6TvF8H1lWvsdphONe6p8Po3USvo5VQaQcxWzPcGlzKwsaX4djn+UVVPr+CsCZqXW9SOFxOEZEDCn4hIiJnVzh1/r0aOJfFWXrXRLmGX1CJwMUCUVZc4g39mPFfEzh0gWxPmMSP5Q0vsYK7RgQH+JKdmxYiqasfY06px87Wp5Xl2+UzToHUURSOnM+s3 postgres@godard (2017-09-01)",
"staticsync_user_exists": false,
"weblogsync_user_exists": false,
"buildd_user_exists": false,
"staticsync_user_exists": false,
"weblogsync_user_exists": false,
"buildd_user_exists": false,
diff --git
a/spec/octocatalog/facts/sibelius.debian.org.json
b/spec/octocatalog/facts/sibelius.debian.org.json
index
cd535eb
..
d5f5d33
100644
(file)
--- a/
spec/octocatalog/facts/sibelius.debian.org.json
+++ b/
spec/octocatalog/facts/sibelius.debian.org.json
@@
-261,7
+261,7
@@
"puppet_server": "puppet",
"systemproductname": "Sun Fire X4200 Server",
"hw_can_temp_sensors": false,
"puppet_server": "puppet",
"systemproductname": "Sun Fire X4200 Server",
"hw_can_temp_sensors": false,
- "postgres
ql
_key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDH4f+v9s9qvOX028ZEiaxxvpj+VOlQ0tT5rtsJ1Q5tp9tZM1KVnM3EIgEmaDE5x4aXgdmfEpAEAl5Uq5Eyv1vh8a7VIvvlaYz6UXqp8fgljAUTKsP1RwB31PxqZ2xXXS/UPY7Ubrcxz+L/Jl0hrWh7PTC1waMZDOXeqPKUdpLOQJi+RmprrbfxGkTtASwpfRl5fCLcNFKA97flN6Sfg01m8kqHVHmoBstQcQzVEWmUSf3USFmJ0bzrOUEL4qi9Mh/7+YTlCfcwWhDHMrtg6dzB0HbE7U1DjcG70ZCVdoPhqAMm+GU011VrC1mY8Tba54CK0oUcAVvoakLYhvpEHNLb postgres@sibelius (20101213)",
+ "postgres_key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDH4f+v9s9qvOX028ZEiaxxvpj+VOlQ0tT5rtsJ1Q5tp9tZM1KVnM3EIgEmaDE5x4aXgdmfEpAEAl5Uq5Eyv1vh8a7VIvvlaYz6UXqp8fgljAUTKsP1RwB31PxqZ2xXXS/UPY7Ubrcxz+L/Jl0hrWh7PTC1waMZDOXeqPKUdpLOQJi+RmprrbfxGkTtASwpfRl5fCLcNFKA97flN6Sfg01m8kqHVHmoBstQcQzVEWmUSf3USFmJ0bzrOUEL4qi9Mh/7+YTlCfcwWhDHMrtg6dzB0HbE7U1DjcG70ZCVdoPhqAMm+GU011VrC1mY8Tba54CK0oUcAVvoakLYhvpEHNLb postgres@sibelius (20101213)",
"staticsync_user_exists": false,
"weblogsync_user_exists": false,
"buildd_user_exists": false,
"staticsync_user_exists": false,
"weblogsync_user_exists": false,
"buildd_user_exists": false,