From c8e7f2f91510d995221c980aeabd3084aaadf253 Mon Sep 17 00:00:00 2001 From: Michael Scherer Date: Tue, 7 Dec 2010 02:40:35 +0000 Subject: - add the owner option, to set the user to whom the database will belong --- modules/postgresql/manifests/init.pp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/postgresql/manifests/init.pp b/modules/postgresql/manifests/init.pp index 9304fff9..2b426a96 100644 --- a/modules/postgresql/manifests/init.pp +++ b/modules/postgresql/manifests/init.pp @@ -84,7 +84,7 @@ class postgresql { # TODO convert it to a regular type ( so we can later change user and so on ) define database($description="", $user="postgres") { - exec { "createdb -U postgres $name '$description'": + exec { "createdb -O $user -U postgres $name '$description'": user => root, unless => "psql -l -U postgres | grep '^$name|'", } -- cgit v1.2.1