[Ovirt-devel] [PATCH server] update postgres for ipv6 support, or db:migrate will fail
Joey Boggs
jboggs at redhat.com
Fri Jun 5 20:52:15 UTC 2009
If the ::1 ipv6 loopback entry is missing in pg_hba.conf rake db:migrate will fail
rake aborted!
FATAL: no pg_hba.conf entry for host "::1", user "ovirt", database "ovirt_development", SSL off
---
installer/modules/ovirt/manifests/postgres.pp | 8 +++++++-
1 files changed, 7 insertions(+), 1 deletions(-)
diff --git a/installer/modules/ovirt/manifests/postgres.pp b/installer/modules/ovirt/manifests/postgres.pp
index 6620a88..1cea6a1 100644
--- a/installer/modules/ovirt/manifests/postgres.pp
+++ b/installer/modules/ovirt/manifests/postgres.pp
@@ -78,9 +78,15 @@ class postgres::bundled{
notify => Service[postgresql]
}
+ single_exec{"postgres_add_ipv6_localhost_trust":
+ command => "/bin/echo 'host all all ::1/128 trust' >> /var/lib/pgsql/data/pg_hba.conf",
+ require => Exec[postgres_add_localhost_trust],
+ notify => Service[postgresql]
+ }
+
file { "/etc/ovirt-server/" :
ensure => directory,
- require => Exec[postgres_add_localhost_trust]
+ require => [Exec[postgres_add_localhost_trust],Single_exec[postgres_add_ipv6_localhost_trust]]
}
file { "/etc/ovirt-server/db/" :
--
1.6.0.6
More information about the ovirt-devel
mailing list