Merge pull request #582 from rvstaveren/rvstaveren-extension-postgresql_psql-fix

postgresql::server::extension needs to have defaults for postgresql_psql
This commit is contained in:
Hunter Haugen 2015-03-19 10:30:02 -07:00
commit 7018a5f5ad
2 changed files with 23 additions and 0 deletions

View file

@ -5,6 +5,19 @@ define postgresql::server::extension (
$package_name = undef,
$package_ensure = undef,
) {
$user = $postgresql::server::user
$group = $postgresql::server::group
$psql_path = $postgresql::server::psql_path
$port = $postgresql::server::port
# Set the defaults for the postgresql_psql resource
Postgresql_psql {
psql_user => $user,
psql_group => $group,
psql_path => $psql_path,
port => $port,
}
case $ensure {
'present': {
$command = "CREATE EXTENSION ${name}"

View file

@ -9,6 +9,16 @@ class postgresql::server::initdb {
$locale = $postgresql::server::locale
$group = $postgresql::server::group
$user = $postgresql::server::user
$psql_path = $postgresql::server::psql_path
$port = $postgresql::server::port
# Set the defaults for the postgresql_psql resource
Postgresql_psql {
psql_user => $user,
psql_group => $group,
psql_path => $psql_path,
port => $port,
}
# Make sure the data directory exists, and has the correct permissions.
file { $datadir: