diff options
-rw-r--r-- | modules/postgresql/manifests/init.pp | 2 |
1 files changed, 1 insertions, 1 deletions
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|'", } |