postgresql
Version information
This version is compatible with:
- Puppet Enterprise 2023.2.x, 2023.1.x, 2023.0.x, 2021.7.x, 2021.6.x, 2021.5.x, 2021.4.x, 2021.3.x, 2021.2.x, 2021.1.x, 2021.0.x, 2019.8.x
- Puppet >= 6.24.0 < 8.0.0
- , , , , , , , ,
Tasks:
- sql
Start using this module
Add this module to your Puppetfile:
mod 'puppetlabs-postgresql', '8.3.0'
Learn more about managing modules with a PuppetfileDocumentation
postgresql
Table of Contents
- Module Description - What does the module do?
- Setup - The basics of getting started with postgresql module
- Usage - Configuration options and additional functionality
- Reference - An under-the-hood peek at what the module is doing and how
- Limitations - OS compatibility, etc.
- Development - Guide for contributing to the module
- Tests
- Contributors - List of module contributors
Module description
The postgresql module allows you to manage PostgreSQL databases with Puppet.
PostgreSQL is a high-performance, free, open-source relational database server. The postgresql module allows you to manage packages, services, databases, users, and common security settings in PostgreSQL.
Setup
What postgresql affects
- Package, service, and configuration files for PostgreSQL
- Listened-to ports
- IP and mask (optional)
Getting started with postgresql
To configure a basic default PostgreSQL server, declare the postgresql::server
class.
class { 'postgresql::server':
}
Usage
Configure a server
For default settings, declare the postgresql::server
class as above. To customize PostgreSQL server settings, specify the parameters you want to change:
class { 'postgresql::server':
ip_mask_deny_postgres_user => '0.0.0.0/32',
ip_mask_allow_all_users => '0.0.0.0/0',
ipv4acls => ['hostssl all johndoe 192.168.0.0/24 cert'],
postgres_password => 'TPSrep0rt!',
}
After configuration, test your settings from the command line:
psql -h localhost -U postgres
psql -h my.postgres.server -U
If you get an error message from these commands, your permission settings restrict access from the location you're trying to connect from. Depending on whether you want to allow connections from that location, you might need to adjust your permissions.
For more details about server configuration parameters, consult the PostgreSQL Runtime Configuration documentation.
Create a database
You can set up a variety of PostgreSQL databases with the postgresql::server::db
defined type. For instance, to set up a database for PuppetDB:
class { 'postgresql::server':
}
postgresql::server::db { 'mydatabasename':
user => 'mydatabaseuser',
password => postgresql::postgresql_password('mydatabaseuser', 'mypassword'),
}
Manage users, roles, and permissions
To manage users, roles, and permissions:
class { 'postgresql::server':
}
postgresql::server::role { 'marmot':
password_hash => postgresql::postgresql_password('marmot', 'mypasswd'),
}
postgresql::server::database_grant { 'test1':
privilege => 'ALL',
db => 'test1',
role => 'marmot',
}
postgresql::server::table_grant { 'my_table of test2':
privilege => 'ALL',
table => 'my_table',
db => 'test2',
role => 'marmot',
}
This example grants all privileges on the test1 database and on the my_table
table of the test2 database to the specified user or group. After the values are added into the PuppetDB config file, this database would be ready for use.
Manage ownership of DB objects
To change the ownership of all objects within a database using REASSIGN OWNED:
postgresql::server::reassign_owned_by { 'new owner is meerkat':
db => 'test_db',
old_role => 'marmot',
new_role => 'meerkat',
}
This would run the PostgreSQL statement 'REASSIGN OWNED' to update to ownership of all tables, sequences, functions and views currently owned by the role 'marmot' to be owned by the role 'meerkat' instead.
This applies to objects within the nominated database, 'test_db' only.
For Postgresql >= 9.3, the ownership of the database is also updated.
Manage default permissions (PostgreSQL >= 9.6)
To change default permissions for newly created objects using ALTER DEFAULT PRIVILEGES:
postgresql::server::default_privileges { 'marmot access to new tables on test_db':
db => 'test_db',
role => 'marmot',
privilege => 'ALL',
object_type => 'TABLES',
}
Override defaults
The postgresql::globals
class allows you to configure the main settings for this module globally, so that other classes and defined resources can use them. By itself, it does nothing.
For example, to overwrite the default locale
and encoding
for all classes, use the following:
class { 'postgresql::globals':
encoding => 'UTF-8',
locale => 'en_US.UTF-8',
}
class { 'postgresql::server':
}
To use a specific version of the PostgreSQL package:
class { 'postgresql::globals':
manage_package_repo => true,
version => '9.2',
}
class { 'postgresql::server':
}
Manage remote users, roles, and permissions
Remote SQL objects are managed using the same Puppet resources as local SQL objects, along with a connect_settings
hash. This provides control over how Puppet connects to the remote Postgres instances and which version is used for generating SQL commands.
The connect_settings
hash can contain environment variables to control Postgres client connections, such as 'PGHOST', 'PGPORT', 'PGPASSWORD', and 'PGSSLKEY'. See the PostgreSQL Environment Variables documentation for a complete list of variables.
Additionally, you can specify the target database version with the special value of 'DBVERSION'. If the connect_settings
hash is omitted or empty, then Puppet connects to the local PostgreSQL instance.
You can provide a connect_settings
hash for each of the Puppet resources, or you can set a default connect_settings
hash in postgresql::globals
. Configuring connect_settings
per resource allows SQL objects to be created on multiple databases by multiple users.
$connection_settings_super2 = {
'PGUSER' => 'super2',
'PGPASSWORD' => 'foobar2',
'PGHOST' => '127.0.0.1',
'PGPORT' => '5432',
'PGDATABASE' => 'postgres',
}
include postgresql::server
# Connect with no special settings, i.e domain sockets, user postgres
postgresql::server::role { 'super2':
password_hash => 'foobar2',
superuser => true,
connect_settings => {},
}
# Now using this new user connect via TCP
postgresql::server::database { 'db1':
connect_settings => $connection_settings_super2,
require => Postgresql::Server::Role['super2'],
}
Create an access rule for pg_hba.conf
To create an access rule for pg_hba.conf
:
postgresql::server::pg_hba_rule { 'allow application network to access app database':
description => 'Open up PostgreSQL for access from 200.1.2.0/24',
type => 'host',
database => 'app',
user => 'app',
address => '200.1.2.0/24',
auth_method => 'md5',
}
This would create a ruleset in pg_hba.conf
similar to:
# Rule Name: allow application network to access app database
# Description: Open up PostgreSQL for access from 200.1.2.0/24
# Order: 150
host app app 200.1.2.0/24 md5
By default, pg_hba_rule
requires that you include postgresql::server
. However, you can override that behavior by setting target and postgresql_version when declaring your rule. That might look like the following:
postgresql::server::pg_hba_rule { 'allow application network to access app database':
description => 'Open up postgresql for access from 200.1.2.0/24',
type => 'host',
database => 'app',
user => 'app',
address => '200.1.2.0/24',
auth_method => 'md5',
target => '/path/to/pg_hba.conf',
postgresql_version => '9.4',
}
Create user name maps for pg_ident.conf
To create a user name map for the pg_ident.conf:
postgresql::server::pg_ident_rule { 'Map the SSL certificate of the backup server as a replication user':
map_name => 'sslrepli',
system_username => 'repli1.example.com',
database_username => 'replication',
}
This would create a user name map in pg_ident.conf
similar to:
#Rule Name: Map the SSL certificate of the backup server as a replication user
#Description: none
#Order: 150
sslrepli repli1.example.com replication
Create recovery configuration
To create the recovery configuration file (recovery.conf
):
postgresql::server::recovery { 'Create a recovery.conf file with the following defined parameters':
restore_command => 'cp /mnt/server/archivedir/%f %p',
archive_cleanup_command => undef,
recovery_end_command => undef,
recovery_target_name => 'daily backup 2015-01-26',
recovery_target_time => '2015-02-08 22:39:00 EST',
recovery_target_xid => undef,
recovery_target_inclusive => true,
recovery_target => 'immediate',
recovery_target_timeline => 'latest',
pause_at_recovery_target => true,
standby_mode => 'on',
primary_conninfo => 'host=localhost port=5432',
primary_slot_name => undef,
trigger_file => undef,
recovery_min_apply_delay => 0,
}
The above creates this recovery.conf
config file:
restore_command = 'cp /mnt/server/archivedir/%f %p'
recovery_target_name = 'daily backup 2015-01-26'
recovery_target_time = '2015-02-08 22:39:00 EST'
recovery_target_inclusive = true
recovery_target = 'immediate'
recovery_target_timeline = 'latest'
pause_at_recovery_target = true
standby_mode = 'on'
primary_conninfo = 'host=localhost port=5432'
recovery_min_apply_delay = 0
Only the specified parameters are recognized in the template. The recovery.conf
is only created if at least one parameter is set and manage_recovery_conf is set to true.
Validate connectivity
To validate client connections to a remote PostgreSQL database before starting dependent tasks, use the postgresql_conn_validator
resource. You can use this on any node where the PostgreSQL client software is installed. It is often chained to other tasks such as starting an application server or performing a database migration.
Example usage:
postgresql_conn_validator { 'validate my postgres connection':
host => 'my.postgres.host',
db_username => 'mydbuser',
db_password => 'mydbpassword',
db_name => 'mydbname',
psql_path => '/usr/bin/psql',
}
-> exec { 'rake db:migrate':
cwd => '/opt/myrubyapp',
}
Backups
This example demonstrates how to configure PostgreSQL backups with "pg_dump". This sets up a daily cron job to perform a full backup. Each backup will create a new directory. A cleanup job will automatically remove backups that are older than 15 days.
class { 'postgresql::server':
backup_enable => true,
backup_provider => 'pg_dump',
backup_options => {
db_user => 'backupuser',
db_password => 'secret',
manage_user => true,
rotate => 15,
},
...
}
It is possible to set parameter $ensure
to absent
in order to remove the backup job, user/role, backup script and password file. However, the actual backup files and directories will remain untouched.
Reference
For information on the classes and types, see the REFERENCE.md
Limitations
Works with versions of PostgreSQL on supported OSes.
For an extensive list of supported operating systems, see metadata.json
Apt module support
While this module supports both 1.x and 2.x versions of the 'puppetlabs-apt' module, it does not support 'puppetlabs-apt' 2.0.0 or 2.0.1.
PostGIS support
PostGIS is currently considered an unsupported feature, as it doesn't work on all platforms correctly.
All versions of RHEL/CentOS with manage_selinux => false
If you have SELinux enabled and you are not using the selinux module to manage SELinux (this is the default configuration) you will need to label any custom ports you use with the postgresql_port_t
context. The postgresql service will not start until this is done. To label a port use the semanage command as follows:
semanage port -a -t postgresql_port_t -p tcp $customport
Development
Puppet Labs modules on the Puppet Forge are open projects, and community contributions are essential for keeping them great. We can’t access the huge number of platforms and myriad hardware, software, and deployment configurations that Puppet is intended to serve. We want to keep it as easy as possible to contribute changes so that our modules work in your environment. There are a few guidelines that we need contributors to follow so that we can have a chance of keeping on top of things. For more information, see our module contribution guide.
Tests
There are two types of tests distributed with this module. Unit tests with rspec-puppet
and system tests using rspec-system
.
For unit testing, make sure you have:
- rake
- bundler
Install the necessary gems:
bundle install --path=vendor
And then run the unit tests:
bundle exec rake spec
The unit tests are run in Travis-CI as well. If you want to see the results of your own tests, register the service hook through Travis-CI via the accounts section for your GitHub clone of this project.
To run the system tests, make sure you also have:
- Vagrant > 1.2.x
- VirtualBox > 4.2.10
Then run the tests using:
bundle exec rspec spec/acceptance
To run the tests on different operating systems, see the sets available in .nodeset.yml
and run the specific set with the following syntax:
RSPEC_SET=debian-607-x64 bundle exec rspec spec/acceptance
Contributors
View the full list of contributors on Github.
Reference
Table of Contents
Classes
Public Classes
postgresql::client
: Installs PostgreSQL client software. Set the following parameters if you have a custom version you would like to install.postgresql::globals
: Class for setting cross-class global overrides.postgresql::lib::devel
: This class installs postgresql development libraries.postgresql::lib::docs
: Installs PostgreSQL bindings for Postgres-Docs. Set the following parameters if you have a custom version you would like to install.postgresql::lib::java
: This class installs the postgresql jdbc connector.postgresql::lib::perl
: This class installs the perl libs for postgresql.postgresql::lib::python
: This class installs the python libs for postgresql.postgresql::server
: This installs a PostgreSQL serverpostgresql::server::contrib
: Install the contrib postgresql packaging.postgresql::server::plperl
: This class installs the PL/Perl procedural language for postgresql.postgresql::server::plpython
: This class installs the PL/Python procedural language for postgresql.postgresql::server::postgis
: Install the postgis postgresql packaging.
Private Classes
postgresql::backup::pg_dump
: "Provider" for pg_dump backuppostgresql::dnfmodule
: Manage the DNF modulepostgresql::params
postgresql::repo
postgresql::repo::apt_postgresql_org
postgresql::repo::yum_postgresql_org
postgresql::server::config
postgresql::server::initdb
postgresql::server::install
postgresql::server::late_initdb
: Manage the default encoding when database initialization is managed by the packagepostgresql::server::passwd
postgresql::server::reload
postgresql::server::service
Defined types
postgresql::server::config_entry
: Manage a postgresql.conf entry.postgresql::server::database
: Define for creating a database.postgresql::server::database_grant
: Manage a database grant.postgresql::server::db
: Define for conveniently creating a role, database and assigning the correctpermissions.postgresql::server::default_privileges
: Manage a database defaults privileges. Only works with PostgreSQL version 9.6 and above.postgresql::server::extension
: Activate an extension on a postgresql database.postgresql::server::grant
: Define for granting permissions to roles.postgresql::server::grant_role
: Define for granting membership to a role.postgresql::server::pg_hba_rule
: This resource manages an individual rule that applies to the file defined in target.postgresql::server::pg_ident_rule
: This resource manages an individual rule that applies to the file defined in target.postgresql::server::reassign_owned_by
: Define for reassigning the ownership of objects within a database.postgresql::server::recovery
: This resource manages the parameters that applies to the recovery.conf template.postgresql::server::role
: Define for creating a database role.postgresql::server::schema
: Create a new schema.postgresql::server::table_grant
: This resource wraps the grant resource to manage table grants specifically.postgresql::server::tablespace
: This module creates tablespace.postgresql::validate_db_connection
: This type validates that a successful postgres connection.
Resource types
postgresql_conf
: This type allows puppet to manage postgresql.conf parameters.postgresql_conn_validator
: Verify if a connection can be successfully establishedpostgresql_psql
: An arbitrary tag for your own reference; the name of the message.postgresql_replication_slot
: Manages Postgresql replication slots.
Functions
Public Functions
postgresql::default
: This function pull default values from theparams
class orglobals
class if the value is not present inparams
.postgresql::postgresql_escape
: This function escapes a string using Dollar Quoting using a randomly generated tag if required.postgresql::postgresql_password
: This function returns the postgresql password hash from the clear text username / passwordpostgresql::prepend_sql_password
: This function exists for usage of a role password that is a deferred functionpostgresql_escape
: DEPRECATED. Use the namespaced functionpostgresql::postgresql_escape
instead.postgresql_password
: DEPRECATED. Use the namespaced functionpostgresql::postgresql_password
instead.
Private Functions
postgresql::postgresql_acls_to_resources_hash
: This internal function translates the ipv(4|6)acls format into a resource suitable for create_resources.
Tasks
sql
: Allows you to execute arbitary SQL
Classes
postgresql::client
Installs PostgreSQL client software. Set the following parameters if you have a custom version you would like to install.
- Note Make sure to add any necessary yum or apt repositories if specifying a custom version.
Parameters
The following parameters are available in the postgresql::client
class:
file_ensure
Data type: Enum['file', 'absent']
Ensure the connection validation script is present
Default value: 'file'
validcon_script_path
Data type: Stdlib::Absolutepath
Optional. Absolute path for the postgresql connection validation script.
Default value: $postgresql::params::validcon_script_path
package_name
Data type: String[1]
Sets the name of the PostgreSQL client package.
Default value: $postgresql::params::client_package_name
package_ensure
Data type: String[1]
Ensure the client package is installed
Default value: 'present'
postgresql::globals
Class for setting cross-class global overrides.
- Note Most server-specific defaults should be overridden in the postgresql::server class. This class should be used only if you are using a non-standard OS, or if you are changing elements that can only be changed here, such as version or manage_package_repo.
Parameters
The following parameters are available in the postgresql::globals
class:
client_package_name
server_package_name
contrib_package_name
devel_package_name
java_package_name
docs_package_name
perl_package_name
plperl_package_name
plpython_package_name
python_package_name
postgis_package_name
service_name
service_provider
service_status
default_database
validcon_script_path
initdb_path
createdb_path
psql_path
pg_hba_conf_path
pg_ident_conf_path
postgresql_conf_path
postgresql_conf_mode
recovery_conf_path
default_connect_settings
pg_hba_conf_defaults
datadir
confdir
bindir
xlogdir
logdir
log_line_prefix
user
group
version
postgis_version
repo_proxy
repo_baseurl
yum_repo_commonurl
needs_initdb
encoding
locale
data_checksums
timezone
manage_pg_hba_conf
manage_pg_ident_conf
manage_recovery_conf
manage_postgresql_conf_perms
manage_datadir
manage_logdir
manage_xlogdir
manage_package_repo
manage_dnf_module
module_workdir
manage_selinux
client_package_name
Data type: Any
Overrides the default PostgreSQL client package name.
Default value: undef
server_package_name
Data type: Any
Overrides the default PostgreSQL server package name.
Default value: undef
contrib_package_name
Data type: Any
Overrides the default PostgreSQL contrib package name.
Default value: undef
devel_package_name
Data type: Any
Overrides the default PostgreSQL devel package name.
Default value: undef
java_package_name
Data type: Any
Overrides the default PostgreSQL java package name.
Default value: undef
docs_package_name
Data type: Any
Overrides the default PostgreSQL docs package name.
Default value: undef
perl_package_name
Data type: Any
Overrides the default PostgreSQL Perl package name.
Default value: undef
plperl_package_name
Data type: Any
Overrides the default PostgreSQL PL/Perl package name.
Default value: undef
plpython_package_name
Data type: Any
Overrides the default PostgreSQL PL/Python package name.
Default value: undef
python_package_name
Data type: Any
Overrides the default PostgreSQL Python package name.
Default value: undef
postgis_package_name
Data type: Any
Overrides the default PostgreSQL PostGIS package name.
Default value: undef
service_name
Data type: Any
Overrides the default PostgreSQL service name.
Default value: undef
service_provider
Data type: Any
Overrides the default PostgreSQL service provider.
Default value: undef
service_status
Data type: Any
Overrides the default status check command for your PostgreSQL service.
Default value: undef
default_database
Data type: Any
Specifies the name of the default database to connect with.
Default value: undef
validcon_script_path
Data type: Any
Scipt path for the connection validation check.
Default value: undef
initdb_path
Data type: Any
Path to the initdb command.
Default value: undef
createdb_path
Data type: Any
Deprecated. Path to the createdb command.
Default value: undef
psql_path
Data type: Any
Sets the path to the psql command.
Default value: undef
pg_hba_conf_path
Data type: Any
Specifies the path to your pg_hba.conf file.
Default value: undef
pg_ident_conf_path
Data type: Any
Specifies the path to your pg_ident.conf file.
Default value: undef
postgresql_conf_path
Data type: Any
Sets the path to your postgresql.conf file.
Default value: undef
postgresql_conf_mode
Data type: Optional[Stdlib::Filemode]
Sets the mode of your postgresql.conf file. Only relevant if manage_postgresql_conf_perms is true.
Default value: undef
recovery_conf_path
Data type: Any
Path to your recovery.conf file.
Default value: undef
default_connect_settings
Data type: Any
Default connection settings.
Default value: {}
pg_hba_conf_defaults
Data type: Any
Disables the defaults supplied with the module for pg_hba.conf if set to false.
Default value: undef
datadir
Data type: Any
Overrides the default PostgreSQL data directory for the target platform. Changing the datadir after installation causes the server to come to a full stop before making the change. For Red Hat systems, the data directory must be labeled appropriately for SELinux. On Ubuntu, you must explicitly set needs_initdb = true to allow Puppet to initialize the database in the new datadir (needs_initdb defaults to true on other systems). Warning! If datadir is changed from the default, Puppet does not manage purging of the original data directory, which causes it to fail if the data directory is changed back to the original
Default value: undef
confdir
Data type: Any
Overrides the default PostgreSQL configuration directory for the target platform.
Default value: undef
bindir
Data type: Any
Overrides the default PostgreSQL binaries directory for the target platform.
Default value: undef
xlogdir
Data type: Any
Overrides the default PostgreSQL xlog directory.
Default value: undef
logdir
Data type: Any
Overrides the default PostgreSQL log directory.
Default value: undef
log_line_prefix
Data type: Any
Overrides the default PostgreSQL log prefix.
Default value: undef
user
Data type: Any
Overrides the default PostgreSQL super user and owner of PostgreSQL related files in the file system.
Default value: undef
group
Data type: Any
Overrides the default postgres user group to be used for related files in the file system.
Default value: undef
version
Data type: Any
The version of PostgreSQL to install and manage.
Default value: undef
postgis_version
Data type: Any
Defines the version of PostGIS to install, if you install PostGIS.
Default value: undef
repo_proxy
Data type: Any
Sets the proxy option for the official PostgreSQL yum-repositories only.
Default value: undef
repo_baseurl
Data type: Any
Sets the baseurl for the PostgreSQL repository. Useful if you host your own mirror of the repository.
Default value: undef
yum_repo_commonurl
Data type: Any
Sets the url for the PostgreSQL common Yum repository. Useful if you host your own mirror of the YUM repository.
Default value: undef
needs_initdb
Data type: Any
Explicitly calls the initdb operation after the server package is installed and before the PostgreSQL service is started.
Default value: undef
encoding
Data type: Any
Sets the default encoding for all databases created with this module. On certain operating systems, this is also used during the template1 initialization, so it becomes a default outside of the module as well.
Default value: undef
locale
Data type: Any
Sets the default database locale for all databases created with this module. On certain operating systems, this is also used during the template1 initialization, so it becomes a default outside of the module as well. On Debian, you'll need to ensure that the 'locales-all' package is installed for full functionality of PostgreSQL.
Default value: undef
data_checksums
Data type: Any
Use checksums on data pages to help detect corruption by the I/O system that would otherwise be silent. Warning: This option is used during initialization by initdb, and cannot be changed later.
Default value: undef
timezone
Data type: Any
Sets the default timezone of the postgresql server. The postgresql built-in default is taking the systems timezone information.
Default value: undef
manage_pg_hba_conf
Data type: Any
Allow Puppet to manage the pg_hba.conf file.
Default value: undef
manage_pg_ident_conf
Data type: Any
Allow Puppet to manage the pg_ident.conf file.
Default value: undef
manage_recovery_conf
Data type: Any
Allow Puppet to manage the recovery.conf file.
Default value: undef
manage_postgresql_conf_perms
Data type: Any
Whether to manage the postgresql conf file permissions. This means owner, group and mode. Contents are not managed but should be managed through postgresql::server::config_entry.
Default value: undef
manage_datadir
Data type: Any
Set to false if you have file{ $datadir: } already defined
Default value: undef
manage_logdir
Data type: Any
Set to false if you have file{ $logdir: } already defined
Default value: undef
manage_xlogdir
Data type: Any
Set to false if you have file{ $xlogdir: } already defined
Default value: undef
manage_package_repo
Data type: Any
Sets up official PostgreSQL repositories on your host if set to true.
Default value: undef
manage_dnf_module
Data type: Boolean
Manage the DNF module. This only makes sense on distributions that use DNF package manager, such as EL8 or Fedora. It also requires Puppet 5.5.20+ or Puppet 6.15.0+ since they ship the dnfmodule provider.
Default value: false
module_workdir
Data type: Any
Specifies working directory under which the psql command should be executed. May need to specify if '/tmp' is on volume mounted with noexec option.
Default value: undef
manage_selinux
Data type: Any
Default value: undef
postgresql::lib::devel
This class installs postgresql development libraries.
Parameters
The following parameters are available in the postgresql::lib::devel
class:
package_name
Data type: String
Override devel package name
Default value: $postgresql::params::devel_package_name
package_ensure
Data type: String[1]
Ensure the development libraries are installed
Default value: 'present'
link_pg_config
Data type: Boolean
If the bin directory used by the PostgreSQL page is not /usr/bin or /usr/local/bin, symlinks pg_config from the package's bin dir into usr/bin (not applicable to Debian systems). Set to false to disable this behavior.
Default value: $postgresql::params::link_pg_config
postgresql::lib::docs
Installs PostgreSQL bindings for Postgres-Docs. Set the following parameters if you have a custom version you would like to install.
- Note Make sure to add any necessary yum or apt repositories if specifying a custom version.
Parameters
The following parameters are available in the postgresql::lib::docs
class:
package_name
Data type: String
Specifies the name of the PostgreSQL docs package.
Default value: $postgresql::params::docs_package_name
package_ensure
Data type: String[1]
Whether the PostgreSQL docs package resource should be present.
Default value: 'present'
postgresql::lib::java
This class installs the postgresql jdbc connector.
- Note Make sure to add any necessary yum or apt repositories if specifying a custom version.
Parameters
The following parameters are available in the postgresql::lib::java
class:
package_name
Data type: String
Specifies the name of the PostgreSQL java package.
Default value: $postgresql::params::java_package_name
package_ensure
Data type: String[1]
Specifies whether the package is present.
Default value: 'present'
postgresql::lib::perl
This class installs the perl libs for postgresql.
Parameters
The following parameters are available in the postgresql::lib::perl
class:
package_name
Data type: String
Specifies the name of the PostgreSQL perl package to install.
Default value: $postgresql::params::perl_package_name
package_ensure
Data type: String[1]
Ensure the perl libs for postgresql are installed.
Default value: 'present'
postgresql::lib::python
This class installs the python libs for postgresql.
Parameters
The following parameters are available in the postgresql::lib::python
class:
package_name
Data type: String[1]
The name of the PostgreSQL Python package.
Default value: $postgresql::params::python_package_name
package_ensure
Data type: String[1]
Ensure the python libs for postgresql are installed.
Default value: 'present'
postgresql::server
This installs a PostgreSQL server
Parameters
The following parameters are available in the postgresql::server
class:
postgres_password
package_name
package_ensure
plperl_package_name
plpython_package_name
service_ensure
service_enable
service_manage
service_name
service_restart_on_change
service_provider
service_reload
service_status
default_database
default_connect_settings
listen_addresses
port
ip_mask_deny_postgres_user
ip_mask_allow_all_users
ipv4acls
ipv6acls
initdb_path
createdb_path
psql_path
pg_hba_conf_path
pg_ident_conf_path
postgresql_conf_path
postgresql_conf_mode
recovery_conf_path
datadir
xlogdir
logdir
log_line_prefix
pg_hba_conf_defaults
user
group
needs_initdb
encoding
locale
data_checksums
timezone
manage_pg_hba_conf
manage_pg_ident_conf
manage_recovery_conf
manage_postgresql_conf_perms
module_workdir
manage_datadir
manage_logdir
manage_xlogdir
roles
config_entries
pg_hba_rules
backup_enable
backup_options
backup_provider
version
extra_systemd_config
manage_selinux
password_encryption
postgres_password
Data type: Optional[Variant[String[1], Sensitive[String[1]], Integer]]
Sets the password for the postgres user to your specified value. By default, this setting uses the superuser account in the Postgres database, with a user called postgres and no password.
Default value: undef
package_name
Data type: Any
Specifies the name of the package to use for installing the server software.
Default value: $postgresql::params::server_package_name
package_ensure
Data type: Any
Passes a value through to the package resource when creating the server instance.
Default value: $postgresql::params::package_ensure
plperl_package_name
Data type: Any
Sets the default package name for the PL/Perl extension.
Default value: $postgresql::params::plperl_package_name
plpython_package_name
Data type: Any
Sets the default package name for the PL/Python extension.
Default value: $postgresql::params::plpython_package_name
service_ensure
Data type: Any
Ensure service is installed
Default value: $postgresql::params::service_ensure
service_enable
Data type: Any
Enable the PostgreSQL service
Default value: $postgresql::params::service_enable
service_manage
Data type: Any
Defines whether or not Puppet should manage the service.
Default value: $postgresql::params::service_manage
service_name
Data type: Any
Overrides the default PostgreSQL service name.
Default value: $postgresql::params::service_name
service_restart_on_change
Data type: Any
Overrides the default behavior to restart your PostgreSQL service when a config entry has been changed that requires a service restart to become active.
Default value: $postgresql::params::service_restart_on_change
service_provider
Data type: Any
Overrides the default PostgreSQL service provider.
Default value: $postgresql::params::service_provider
service_reload
Data type: Any
Overrides the default reload command for your PostgreSQL service.
Default value: $postgresql::params::service_reload
service_status
Data type: Any
Overrides the default status check command for your PostgreSQL service.
Default value: $postgresql::params::service_status
default_database
Data type: Any
Specifies the name of the default database to connect with. On most systems this is 'postgres'.
Default value: $postgresql::params::default_database
default_connect_settings
Data type: Any
Specifies a hash of environment variables used when connecting to a remote server. Becomes the default for other defined types, such as postgresql::server::role.
Default value: $postgresql::globals::default_connect_settings
listen_addresses
Data type: Any
Address list on which the PostgreSQL service will listen
Default value: $postgresql::params::listen_addresses
port
Data type: Any
Specifies the port for the PostgreSQL server to listen on. Note: The same port number is used for all IP addresses the server listens on. Also, for Red Hat systems and early Debian systems, changing the port causes the server to come to a full stop before being able to make the change. Default value: 5432. Meaning the Postgres server listens on TCP port 5432.
Default value: $postgresql::params::port
ip_mask_deny_postgres_user
Data type: Any
Specifies the IP mask from which remote connections should be denied for the postgres superuser. Default value: '0.0.0.0/0', which denies any remote connection.
Default value: $postgresql::params::ip_mask_deny_postgres_user
ip_mask_allow_all_users
Data type: Any
Overrides PostgreSQL defaults for remote connections. By default, PostgreSQL does not allow database user accounts to connect via TCP from remote machines. If you'd like to allow this, you can override this setting. Set to '0.0.0.0/0' to allow database users to connect from any remote machine, or '192.168.0.0/1' to allow connections from any machine on your local '192.168' subnet. Default value: '127.0.0.1/32'.
Default value: $postgresql::params::ip_mask_allow_all_users
ipv4acls
Data type: Array[String[1]]
Lists strings for access control for connection method, users, databases, IPv4 addresses;
Default value: $postgresql::params::ipv4acls
ipv6acls
Data type: Array[String[1]]
Lists strings for access control for connection method, users, databases, IPv6 addresses.
Default value: $postgresql::params::ipv6acls
initdb_path
Data type: Any
Specifies the path to the initdb command.
Default value: $postgresql::params::initdb_path
createdb_path
Data type: Any
Deprecated. Specifies the path to the createdb command.
Default value: $postgresql::params::createdb_path
psql_path
Data type: Any
Specifies the path to the psql command.
Default value: $postgresql::params::psql_path
pg_hba_conf_path
Data type: Any
Specifies the path to your pg_hba.conf file.
Default value: $postgresql::params::pg_hba_conf_path
pg_ident_conf_path
Data type: Any
Specifies the path to your pg_ident.conf file.
Default value: $postgresql::params::pg_ident_conf_path
postgresql_conf_path
Data type: Any
Specifies the path to your postgresql.conf file.
Default value: $postgresql::params::postgresql_conf_path
postgresql_conf_mode
Data type: Optional[Stdlib::Filemode]
Sets the mode of your postgresql.conf file. Only relevant if manage_postgresql_conf_perms is true.
Default value: $postgresql::params::postgresql_conf_mode
recovery_conf_path
Data type: Any
Specifies the path to your recovery.conf file.
Default value: $postgresql::params::recovery_conf_path
datadir
Data type: Any
PostgreSQL data directory
Default value: $postgresql::params::datadir
xlogdir
Data type: Any
PostgreSQL xlog directory
Default value: $postgresql::params::xlogdir
logdir
Data type: Any
PostgreSQL log directory
Default value: $postgresql::params::logdir
log_line_prefix
Data type: Any
PostgreSQL log line prefix
Default value: $postgresql::params::log_line_prefix
pg_hba_conf_defaults
Data type: Any
If false, disables the defaults supplied with the module for pg_hba.conf. This is useful if you disagree with the defaults and wish to override them yourself. Be sure that your changes of course align with the rest of the module, as some access is required to perform basic psql operations for example.
Default value: $postgresql::params::pg_hba_conf_defaults
user
Data type: Any
Overrides the default PostgreSQL super user and owner of PostgreSQL related files in the file system.
Default value: $postgresql::params::user
group
Data type: Any
Overrides the default postgres user group to be used for related files in the file system.
Default value: $postgresql::params::group
needs_initdb
Data type: Any
Explicitly calls the initdb operation after server package is installed, and before the PostgreSQL service is started.
Default value: $postgresql::params::needs_initdb
encoding
Data type: Any
Sets the default encoding for all databases created with this module. On certain operating systems this is also used during the template1 initialization, so it becomes a default outside of the module as well.
Default value: $postgresql::params::encoding
locale
Data type: Any
Sets the default database locale for all databases created with this module. On certain operating systems this is used during the template1 initialization as well, so it becomes a default outside of the module.
Default value: $postgresql::params::locale
data_checksums
Data type: Any
Boolean. Use checksums on data pages to help detect corruption by the I/O system that would otherwise be silent. Warning: This option is used during initialization by initdb, and cannot be changed later. If set, checksums are calculated for all objects, in all databases.
Default value: $postgresql::params::data_checksums
timezone
Data type: Any
Set timezone for the PostgreSQL instance
Default value: $postgresql::params::timezone
manage_pg_hba_conf
Data type: Any
Boolean. Whether to manage the pg_hba.conf.
Default value: $postgresql::params::manage_pg_hba_conf
manage_pg_ident_conf
Data type: Any
Boolean. Overwrites the pg_ident.conf file.
Default value: $postgresql::params::manage_pg_ident_conf
manage_recovery_conf
Data type: Any
Boolean. Specifies whether or not manage the recovery.conf.
Default value: $postgresql::params::manage_recovery_conf
manage_postgresql_conf_perms
Data type: Boolean
Whether to manage the postgresql conf file permissions. This means owner, group and mode. Contents are not managed but should be managed through postgresql::server::config_entry.
Default value: $postgresql::params::manage_postgresql_conf_perms
module_workdir
Data type: Any
Working directory for the PostgreSQL module
Default value: $postgresql::params::module_workdir
manage_datadir
Data type: Any
Set to false if you have file{ $datadir: } already defined
Default value: $postgresql::params::manage_datadir
manage_logdir
Data type: Any
Set to false if you have file{ $logdir: } already defined
Default value: $postgresql::params::manage_logdir
manage_xlogdir
Data type: Any
Set to false if you have file{ $xlogdir: } already defined
Default value: $postgresql::params::manage_xlogdir
roles
Data type: Hash[String, Hash]
Specifies a hash from which to generate postgresql::server::role resources.
Default value: {}
config_entries
Data type: Hash[String, Any]
Specifies a hash from which to generate postgresql::server::config_entry resources.
Default value: {}
pg_hba_rules
Data type: Hash[String, Hash]
Specifies a hash from which to generate postgresql::server::pg_hba_rule resources.
Default value: {}
backup_enable
Data type: Boolean
Whether a backup job should be enabled.
Default value: $postgresql::params::backup_enable
backup_options
Data type: Hash
A hash of options that should be passed through to the backup provider.
Default value: {}
backup_provider
Data type: Enum['pg_dump']
Specifies the backup provider to use.
Default value: $postgresql::params::backup_provider
version
Data type: Any
Deprecated. Use postgresql::globals instead. Sets PostgreSQL version
Default value: undef
extra_systemd_config
Data type: Any
Adds extra config to systemd config file, can for instance be used to add extra openfiles. This can be a multi line string
Default value: $postgresql::params::extra_systemd_config
manage_selinux
Data type: Boolean
Default value: $postgresql::params::manage_selinux
password_encryption
Data type: Any
Default value: $postgresql::params::password_encryption
postgresql::server::contrib
Install the contrib postgresql packaging.
Parameters
The following parameters are available in the postgresql::server::contrib
class:
package_name
Data type: Optional[String[1]]
The name of the PostgreSQL contrib package.
Default value: $postgresql::params::contrib_package_name
package_ensure
Data type: String[1]
Ensure the contrib package is installed.
Default value: 'present'
postgresql::server::plperl
This class installs the PL/Perl procedural language for postgresql.
Parameters
The following parameters are available in the postgresql::server::plperl
class:
package_ensure
Data type: Any
The ensure parameter passed on to PostgreSQL PL/Perl package resource.
Default value: 'present'
package_name
Data type: Any
The name of the PostgreSQL PL/Perl package.
Default value: $postgresql::server::plperl_package_name
postgresql::server::plpython
This class installs the PL/Python procedural language for postgresql.
Parameters
The following parameters are available in the postgresql::server::plpython
class:
package_ensure
Data type: Any
Specifies whether the package is present.
Default value: 'present'
package_name
Data type: Any
Specifies the name of the postgresql PL/Python package.
Default value: $postgresql::server::plpython_package_name
postgresql::server::postgis
Install the postgis postgresql packaging.
Parameters
The following parameters are available in the postgresql::server::postgis
class:
package_name
Data type: String
Sets the package name.
Default value: $postgresql::params::postgis_package_name
package_ensure
Data type: String[1]
Specifies if the package is present or not.
Default value: 'present'
Defined types
postgresql::server::config_entry
Manage a postgresql.conf entry.
Parameters
The following parameters are available in the postgresql::server::config_entry
defined type:
ensure
Data type: Enum['present', 'absent']
Removes an entry if set to 'absent'.
Default value: 'present'
value
Data type: Any
Defines the value for the setting.
Default value: undef
path
Data type: Any
Path for postgresql.conf
Default value: false
postgresql::server::database
Define for creating a database.
Parameters
The following parameters are available in the postgresql::server::database
defined type:
comment
Data type: Any
Sets a comment on the database.
Default value: undef
dbname
Data type: Any
Sets the name of the database.
Default value: $title
owner
Data type: Any
Sets name of the database owner.
Default value: undef
tablespace
Data type: Any
Sets tablespace for where to create this database.
Default value: undef
template
Data type: Any
Specifies the name of the template database from which to build this database. Default value: 'template0'.
Default value: 'template0'
encoding
Data type: Any
Overrides the character set during creation of the database.
Default value: $postgresql::server::encoding
locale
Data type: Any
Overrides the locale during creation of the database.
Default value: $postgresql::server::locale
istemplate
Data type: Any
Defines the database as a template if set to true.
Default value: false
connect_settings
Data type: Any
Specifies a hash of environment variables used when connecting to a remote server.
Default value: $postgresql::server::default_connect_settings
postgresql::server::database_grant
Manage a database grant.
Parameters
The following parameters are available in the postgresql::server::database_grant
defined type:
privilege
Data type: Any
Specifies comma-separated list of privileges to grant. Valid options: 'ALL', 'CREATE', 'CONNECT', 'TEMPORARY', 'TEMP'.
db
Data type: Any
Specifies the database to which you are granting access.
role
Data type: Any
Specifies the role or user whom you are granting access to.
ensure
Data type: Any
Specifies whether to grant or revoke the privilege. Revoke or 'absent' works only in PostgreSQL version 9.1.24 or later.
Default value: undef
psql_db
Data type: Any
Defines the database to execute the grant against. This should not ordinarily be changed from the default
Default value: undef
psql_user
Data type: Any
Specifies the OS user for running psql. Default value: The default user for the module, usually 'postgres'.
Default value: undef
connect_settings
Data type: Any
Specifies a hash of environment variables used when connecting to a remote server.
Default value: undef
postgresql::server::db
Define for conveniently creating a role, database and assigning the correctpermissions.
Parameters
The following parameters are available in the postgresql::server::db
defined type:
user
Data type: Any
User to assign access to the database upon creation (will be created if not defined elsewhere). Mandatory.
password
Data type: Optional[Variant[String, Sensitive[String]]]
Sets the password for the created user (if a user is created).
Default value: undef
comment
Data type: Any
Defines a comment to be stored about the database using the PostgreSQL COMMENT command.
Default value: undef
dbname
Data type: Any
Sets the name of the database to be created.
Default value: $title
encoding
Data type: Any
Overrides the character set during creation of the database.
Default value: $postgresql::server::encoding
locale
Data type: Any
Overrides the locale during creation of the database.
Default value: $postgresql::server::locale
grant
Data type: Any
Specifies the permissions to grant during creation. Default value: 'ALL'.
Default value: 'ALL'
tablespace
Data type: Any
Defines the name of the tablespace to allocate the created database to.
Default value: undef
template
Data type: Any
Specifies the name of the template database from which to build this database. Defaults value: template0.
Default value: 'template0'
istemplate
Data type: Any
Specifies that the database is a template, if set to true.
Default value: false
owner
Data type: Any
Sets a user as the owner of the database.
Default value: undef
postgresql::server::default_privileges
Manage a database defaults privileges. Only works with PostgreSQL version 9.6 and above.
Parameters
The following parameters are available in the postgresql::server::default_privileges
defined type:
target_role
ensure
role
db
object_type
privilege
schema
psql_db
psql_user
psql_path
port
connect_settings
psql_path
group
target_role
Data type: Optional[String]
Target role whose created objects will receive the default privileges. Defaults to the current user.
Default value: undef
ensure
Data type: Enum['present', 'absent']
Specifies whether to grant or revoke the privilege.
Default value: 'present'
role
Data type: String
Specifies the role or user whom you are granting access to.
db
Data type: String
Specifies the database to which you are granting access.
object_type
Data type: Pattern[ /(?i:^FUNCTIONS$)/, /(?i:^ROUTINES$)/, /(?i:^SEQUENCES$)/, /(?i:^TABLES$)/, /(?i:^TYPES$)/, /(?i:^SCHEMAS$)/ ]
Specify target object type: 'FUNCTIONS', 'ROUTINES', 'SEQUENCES', 'TABLES', 'TYPES'.
privilege
Data type: String
Specifies comma-separated list of privileges to grant. Valid options: depends on object type.
schema
Data type: String
Target schema. Defaults to 'public'. Can be set to '' to apply to all schemas.
Default value: 'public'
psql_db
Data type: String
Defines the database to execute the grant against. This should not ordinarily be changed from the default.
Default value: $postgresql::server::default_database
psql_user
Data type: String
Specifies the OS user for running psql. Default value: The default user for the module, usually 'postgres'.
Default value: $postgresql::server::user
psql_path
Data type: String
Specifies the OS user for running psql. Default value: The default user for the module, usually 'postgres'.
Default value: $postgresql::server::psql_path
port
Data type: Integer
Specifies the port to access the server. Default value: The default user for the module, usually '5432'.
Default value: $postgresql::server::port
connect_settings
Data type: Hash
Specifies a hash of environment variables used when connecting to a remote server.
Default value: $postgresql::server::default_connect_settings
psql_path
Specifies the path to the psql command.
Default value: $postgresql::server::psql_path
group
Data type: String
Default value: $postgresql::server::group
postgresql::server::extension
Activate an extension on a postgresql database.
Parameters
The following parameters are available in the postgresql::server::extension
defined type:
database
extension
schema
version
ensure
package_name
package_ensure
port
connect_settings
database_resource_name
database
Data type: Any
Specifies the database on which to activate the extension.
extension
Data type: Any
Specifies the extension to activate. If left blank, uses the name of the resource.
Default value: $name
schema
Data type: Optional[String[1]]
Specifies the schema on which to activate the extension.
Default value: undef
version
Data type: Optional[String[1]]
Specifies the version of the extension which the database uses. When an extension package is updated, this does not automatically change the effective version in each database. This needs be updated using the PostgreSQL-specific SQL ALTER EXTENSION... version may be set to latest, in which case the SQL ALTER EXTENSION "extension" UPDATE is applied to this database (only). version may be set to a specific version, in which case the extension is updated using ALTER EXTENSION "extension" UPDATE TO 'version' eg. If extension is set to postgis and version is set to 2.3.3, this will apply the SQL ALTER EXTENSION "postgis" UPDATE TO '2.3.3' to this database only. version may be omitted, in which case no ALTER EXTENSION... SQL is applied, and the version will be left unchanged.
Default value: undef
ensure
Data type: String[1]
Specifies whether to activate or deactivate the extension. Valid options: 'present' or 'absent'.
Default value: 'present'
package_name
Data type: Any
Specifies a package to install prior to activating the extension.
Default value: undef
package_ensure
Data type: Any
Overrides default package deletion behavior. By default, the package specified with package_name is installed when the extension is activated and removed when the extension is deactivated. To override this behavior, set the ensure value for the package.
Default value: undef
port
Data type: Optional[Integer]
Port to use when connecting.
Default value: undef
connect_settings
Data type: Any
Specifies a hash of environment variables used when connecting to a remote server.
Default value: postgresql::default('default_connect_settings')
database_resource_name
Data type: Any
Specifies the resource name of the DB being managed. Defaults to the parameter $database, if left blank.
Default value: $database
postgresql::server::grant
Define for granting permissions to roles.
Parameters
The following parameters are available in the postgresql::server::grant
defined type:
role
db
privilege
object_type
object_name
psql_db
psql_user
port
onlyif_exists
connect_settings
ensure
group
psql_path
object_arguments
role
Data type: String
Specifies the role or user whom you are granting access to.
db
Data type: String
Specifies the database to which you are granting access.
privilege
Data type: String
Specifies the privilege to grant. Valid options: 'ALL', 'ALL PRIVILEGES' or 'object_type' dependent string.
Default value: ''
object_type
Data type: Pattern[#/(?i:^COLUMN$)/, /(?i:^ALL SEQUENCES IN SCHEMA$)/, /(?i:^ALL TABLES IN SCHEMA$)/, /(?i:^DATABASE$)/, #/(?i:^FOREIGN DATA WRAPPER$)/, #/(?i:^FOREIGN SERVER$)/, /(?i:^FUNCTION$)/, /(?i:^LANGUAGE$)/, #/(?i:^PROCEDURAL LANGUAGE$)/, /(?i:^TABLE$)/, #/(?i:^TABLESPACE$)/, /(?i:^SCHEMA$)/, /(?i:^SEQUENCE$)/ #/(?i:^VIEW$)/ ]
Specifies the type of object to which you are granting privileges. Valid options: 'DATABASE', 'SCHEMA', 'SEQUENCE', 'ALL SEQUENCES IN SCHEMA', 'TABLE' or 'ALL TABLES IN SCHEMA'.
Default value: 'database'
object_name
Data type: Optional[Variant[Array[String,2,2],String[1]]]
Specifies name of object_type to which to grant access, can be either a string or a two element array. String: 'object_name' Array: ['schema_name', 'object_name']
Default value: undef
psql_db
Data type: String
Specifies the database to execute the grant against. This should not ordinarily be changed from the default
Default value: $postgresql::server::default_database
psql_user
Data type: String
Sets the OS user to run psql.
Default value: $postgresql::server::user
port
Data type: Integer
Port to use when connecting.
Default value: $postgresql::server::port
onlyif_exists
Data type: Boolean
Create grant only if doesn't exist
Default value: false
connect_settings
Data type: Hash
Specifies a hash of environment variables used when connecting to a remote server.
Default value: $postgresql::server::default_connect_settings
ensure
Data type: Enum['present', 'absent']
Specifies whether to grant or revoke the privilege. Default is to grant the privilege. Valid values: 'present', 'absent'.
Default value: 'present'
group
Data type: String
Sets the OS group to run psql
Default value: $postgresql::server::group
psql_path
Data type: String
Sets the path to psql command
Default value: $postgresql::server::psql_path
object_arguments
Data type: Array[String[1],0]
Default value: []
postgresql::server::grant_role
Define for granting membership to a role.
Parameters
The following parameters are available in the postgresql::server::grant_role
defined type:
group
Data type: String[1]
Specifies the group role to which you are assigning a role.
role
Data type: String[1]
Specifies the role you want to assign to a group. If left blank, uses the name of the resource.
Default value: $name
ensure
Data type: Enum['present', 'absent']
Specifies whether to grant or revoke the membership. Valid options: 'present' or 'absent'.
Default value: 'present'
psql_db
Data type: Any
Specifies the database to execute the grant against. This should not ordinarily be changed from the default
Default value: $postgresql::server::default_database
psql_user
Data type: Any
Sets the OS user to run psql.
Default value: $postgresql::server::user
port
Data type: Any
Port to use when connecting.
Default value: $postgresql::server::port
connect_settings
Data type: Any
Specifies a hash of environment variables used when connecting to a remote server.
Default value: $postgresql::server::default_connect_settings
postgresql::server::pg_hba_rule
This resource manages an individual rule that applies to the file defined in target.
Parameters
The following parameters are available in the postgresql::server::pg_hba_rule
defined type:
type
Data type: Enum['local', 'host', 'hostssl', 'hostnossl', 'hostgssenc']
Sets the type of rule. Enum['local','host','hostssl','hostnossl','hostgssenc'].
database
Data type: String
Sets a comma-separated list of databases that this rule matches.
user
Data type: String
Sets a comma-separated list of users that this rule matches.
auth_method
Data type: String
Provides the method that is used for authentication for the connection that this rule matches. Described further in the PostgreSQL pg_hba.conf documentation.
address
Data type: Optional[String]
Sets a CIDR based address for this rule matching when the type is not 'local'.
Default value: undef
description
Data type: String
Defines a longer description for this rule, if required. This description is placed in the comments above the rule in pg_hba.conf. Default value: 'none'.
Default value: 'none'
auth_option
Data type: Optional[String]
For certain auth_method settings there are extra options that can be passed. Consult the PostgreSQL pg_hba.conf documentation for further details.
Default value: undef
order
Data type: Variant[String, Integer]
Sets an order for placing the rule in pg_hba.conf. This can be either a string or an integer. If it is an integer, it will be converted to a string by zero-padding it to three digits. E.g. 42 will be zero-padded to the string '042'. The pg_hba_rule fragments are sorted using the alpha sorting order. Default value: 150.
Default value: 150
target
Data type: Stdlib::Absolutepath
Provides the target for the rule, and is generally an internal only property. Use with caution.
Default value: $postgresql::server::pg_hba_conf_path
postgresql_version
Data type: String
Manages pg_hba.conf without managing the entire PostgreSQL instance.
Default value: $postgresql::server::_version
postgresql::server::pg_ident_rule
This resource manages an individual rule that applies to the file defined in target.
Parameters
The following parameters are available in the postgresql::server::pg_ident_rule
defined type:
map_name
Data type: Any
Sets the name of the user map that is used to refer to this mapping in pg_hba.conf.
system_username
Data type: Any
Specifies the operating system user name (the user name used to connect to the database).
database_username
Data type: Any
Specifies the user name of the database user. The system_username is mapped to this user name.
description
Data type: Any
Sets a longer description for this rule if required. This description is placed in the comments above the rule in pg_ident.conf. Default value: 'none'.
Default value: 'none'
order
Data type: Any
Defines an order for placing the mapping in pg_ident.conf. Default value: 150.
Default value: '150'
target
Data type: Any
Provides the target for the rule and is generally an internal only property. Use with caution.
Default value: $postgresql::server::pg_ident_conf_path
postgresql::server::reassign_owned_by
Define for reassigning the ownership of objects within a database.
- Note This enables us to force the a particular ownership for objects within a database
Parameters
The following parameters are available in the postgresql::server::reassign_owned_by
defined type:
old_role
Data type: String
Specifies the role or user who is the current owner of the objects in the specified db
new_role
Data type: String
Specifies the role or user who will be the new owner of these objects
db
Data type: String
Specifies the database to which the 'REASSIGN OWNED' will be applied
psql_user
Data type: String
Specifies the OS user for running psql.
Default value: $postgresql::server::user
port
Data type: Integer
Port to use when connecting.
Default value: $postgresql::server::port
connect_settings
Data type: Hash
Specifies a hash of environment variables used when connecting to a remote server.
Default value: $postgresql::server::default_connect_settings
postgresql::server::recovery
This resource manages the parameters that applies to the recovery.conf template.
- Note Allows you to create the content for recovery.conf. For more details see the usage example and the PostgreSQL documentation. Every parameter value is a string set in the template except recovery_target_inclusive, pause_at_recovery_target, standby_mode and recovery_min_apply_delay. A detailed description of all listed parameters can be found in the PostgreSQL documentation. Only the specified parameters are recognized in the template. The recovery.conf is only created if at least one parameter is set and manage_recovery_conf is set to true.
Parameters
The following parameters are available in the postgresql::server::recovery
defined type:
restore_command
archive_cleanup_command
recovery_end_command
recovery_target_name
recovery_target_time
recovery_target_xid
recovery_target_inclusive
recovery_target
recovery_target_timeline
pause_at_recovery_target
standby_mode
primary_conninfo
primary_slot_name
trigger_file
recovery_min_apply_delay
target
restore_command
Data type: Any
The shell command to execute to retrieve an archived segment of the WAL file series.
Default value: undef
archive_cleanup_command
Data type: Any
This optional parameter specifies a shell command that will be executed at every restartpoint.
Default value: undef
recovery_end_command
Data type: Any
This parameter specifies a shell command that will be executed once only at the end of recovery.
Default value: undef
recovery_target_name
Data type: Any
This parameter specifies the named restore point (created with pg_create_restore_point()) to which recovery will proceed.
Default value: undef
recovery_target_time
Data type: Any
This parameter specifies the time stamp up to which recovery will proceed.
Default value: undef
recovery_target_xid
Data type: Any
This parameter specifies the transaction ID up to which recovery will proceed.
Default value: undef
recovery_target_inclusive
Data type: Any
Specifies whether to stop just after the specified recovery target (true), or just before the recovery target (false).
Default value: undef
recovery_target
Data type: Any
This parameter specifies that recovery should end as soon as a consistent state is reached, i.e. as early as possible.
Default value: undef
recovery_target_timeline
Data type: Any
Specifies recovering into a particular timeline.
Default value: undef
pause_at_recovery_target
Data type: Any
Specifies whether recovery should pause when the recovery target is reached.
Default value: undef
standby_mode
Data type: Any
Specifies whether to start the PostgreSQL server as a standby.
Default value: undef
primary_conninfo
Data type: Any
Specifies a connection string to be used for the standby server to connect with the primary.
Default value: undef
primary_slot_name
Data type: Any
Optionally specifies an existing replication slot to be used when connecting to the primary via streaming replication to control resource removal on the upstream node.
Default value: undef
trigger_file
Data type: Any
Specifies a trigger file whose presence ends recovery in the standby.
Default value: undef
recovery_min_apply_delay
Data type: Any
This parameter allows you to delay recovery by a fixed period of time, measured in milliseconds if no unit is specified.
Default value: undef
target
Data type: Any
Provides the target for the rule, and is generally an internal only property. Use with caution.
Default value: $postgresql::server::recovery_conf_path
postgresql::server::role
Define for creating a database role.
Parameters
The following parameters are available in the postgresql::server::role
defined type:
update_password
password_hash
createdb
createrole
db
port
login
inherit
superuser
replication
connection_limit
username
connect_settings
ensure
psql_user
psql_group
psql_path
module_workdir
hash
salt
update_password
Data type: Any
If set to true, updates the password on changes. Set this to false to not modify the role's password after creation.
Default value: true
password_hash
Data type: Variant[Boolean, String, Sensitive[String]]
Sets the hash to use during password creation.
Default value: false
createdb
Data type: Any
Specifies whether to grant the ability to create new databases with this role.
Default value: false
createrole
Data type: Any
Specifies whether to grant the ability to create new roles with this role.
Default value: false
db
Data type: Any
Database used to connect to.
Default value: $postgresql::server::default_database
port
Data type: Any
Port to use when connecting.
Default value: undef
login
Data type: Any
Specifies whether to grant login capability for the new role.
Default value: true
inherit
Data type: Any
Specifies whether to grant inherit capability for the new role.
Default value: true
superuser
Data type: Any
Specifies whether to grant super user capability for the new role.
Default value: false
replication
Data type: Any
Provides provides replication capabilities for this role if set to true.
Default value: false
connection_limit
Data type: Any
Specifies how many concurrent connections the role can make. Default value: '-1', meaning no limit.
Default value: '-1'
username
Data type: Any
Defines the username of the role to create.
Default value: $title
connect_settings
Data type: Any
Specifies a hash of environment variables used when connecting to a remote server.
Default value: $postgresql::server::default_connect_settings
ensure
Data type: Enum['present', 'absent']
Specify whether to create or drop the role. Specifying 'present' creates the role. Specifying 'absent' drops the role.
Default value: 'present'
psql_user
Data type: Any
Sets the OS user to run psql
Default value: $postgresql::server::user
psql_group
Data type: Any
Sets the OS group to run psql
Default value: $postgresql::server::group
psql_path
Data type: Any
Sets path to psql command
Default value: $postgresql::server::psql_path
module_workdir
Data type: Any
Specifies working directory under which the psql command should be executed. May need to specify if '/tmp' is on volume mounted with noexec option.
Default value: $postgresql::server::module_workdir
hash
Data type: Enum['md5', 'scram-sha-256']
Specify the hash method for pg password
Default value: 'md5'
salt
Data type: Optional[Variant[String[1], Integer]]
Specify the salt use for the scram-sha-256 encoding password (default username)
Default value: undef
postgresql::server::schema
Create a new schema.
- Note The database must exist and the PostgreSQL user should have enough privileges
Examples
postgresql::server::schema {'private':
db => 'template1',
}
Parameters
The following parameters are available in the postgresql::server::schema
defined type:
db
Data type: Any
Required. Sets the name of the database in which to create this schema.
Default value: $postgresql::server::default_database
owner
Data type: Any
Sets the default owner of the schema.
Default value: undef
schema
Data type: Any
Sets the name of the schema.
Default value: $title
connect_settings
Data type: Any
Specifies a hash of environment variables used when connecting to a remote server.
Default value: $postgresql::server::default_connect_settings
postgresql::server::table_grant
This resource wraps the grant resource to manage table grants specifically.
Parameters
The following parameters are available in the postgresql::server::table_grant
defined type:
privilege
Data type: Any
Specifies comma-separated list of privileges to grant. Valid options: 'ALL', 'SELECT', 'INSERT', 'UPDATE', 'DELETE', 'TRUNCATE', 'REFERENCES', 'TRIGGER'.
table
Data type: Any
Specifies the table to which you are granting access.
db
Data type: Any
Specifies which database the table is in.
role
Data type: Any
Specifies the role or user to whom you are granting access.
ensure
Data type: Any
Specifies whether to grant or revoke the privilege. Default is to grant the privilege.
Default value: undef
port
Data type: Any
Port to use when connecting.
Default value: undef
psql_db
Data type: Any
Specifies the database to execute the grant against. This should not ordinarily be changed from the default.
Default value: undef
psql_user
Data type: Any
Specifies the OS user for running psql.
Default value: undef
connect_settings
Data type: Any
Specifies a hash of environment variables used when connecting to a remote server.
Default value: undef
onlyif_exists
Data type: Any
Create grant only if it doesn't exist.
Default value: false
postgresql::server::tablespace
This module creates tablespace.
Parameters
The following parameters are available in the postgresql::server::tablespace
defined type:
location
Data type: Any
Specifies the path to locate this tablespace.
manage_location
Data type: Any
Set to false if you have file{ $location: } already defined
Default value: true
owner
Data type: Any
Specifies the default owner of the tablespace.
Default value: undef
spcname
Data type: Any
Specifies the name of the tablespace.
Default value: $title
connect_settings
Data type: Any
Specifies a hash of environment variables used when connecting to a remote server.
Default value: $postgresql::server::default_connect_settings
postgresql::validate_db_connection
This validated if the postgres connection can be established between the node on which this resource is run and a specified postgres instance (host/port/user/password/database name).
Parameters
The following parameters are available in the postgresql::validate_db_connection
defined type:
database_host
database_name
database_password
database_username
database_port
connect_settings
run_as
sleep
tries
create_db_first
database_host
Data type: Any
Database host address
Default value: undef
database_name
Data type: Any
Specifies the name of the database you wish to test.
Default value: undef
database_password
Data type: Optional[Variant[String, Sensitive[String]]]
Specifies the password to connect with.
Default value: undef
database_username
Data type: Any
Specifies the username to connect with.
Default value: undef
database_port
Data type: Any
Defines the port to use when connecting.
Default value: undef
connect_settings
Data type: Any
Specifies a hash of environment variables used when connecting to a remote server.
Default value: undef
run_as
Data type: Any
Specifies the user to run the psql command as.
Default value: undef
sleep
Data type: Any
Sets the number of seconds to sleep for before trying again after a failure.
Default value: 2
tries
Data type: Any
Sets the number of attempts after failure before giving up and failing the resource.
Default value: 10
create_db_first
Data type: Any
Creates the database when obtaining a successful connection.
Default value: true
Resource types
postgresql_conf
This type allows puppet to manage postgresql.conf parameters.
Properties
The following properties are available in the postgresql_conf
type.
ensure
Valid values: present
, absent
The basic property that the resource should be in.
Default value: present
target
The path to postgresql.conf
value
The value to set for this parameter.
Parameters
The following parameters are available in the postgresql_conf
type.
name
Valid values: %r{^[\w\.]+$}
namevar
The postgresql parameter name to manage.
provider
The specific backend to use for this postgresql_conf
resource. You will seldom need to specify this --- Puppet will
usually discover the appropriate provider for your platform.
postgresql_conn_validator
Verify that a connection can be successfully established between a node and the PostgreSQL server. Its primary use is as a precondition to prevent configuration changes from being applied if the PostgreSQL server cannot be reached, but it could potentially be used for other purposes such as monitoring.
Properties
The following properties are available in the postgresql_conn_validator
type.
ensure
Valid values: present
, absent
Ensure connection validation
Default value: present
Parameters
The following parameters are available in the postgresql_conn_validator
type.
command
connect_settings
db_name
db_password
db_username
host
name
port
provider
psql_path
run_as
sleep
tries
command
Command to run against target database.
Default value: SELECT 1
connect_settings
Hash of environment variables for connection to a db.
db_name
The name of the database you are trying to validate a connection with.
db_password
The password required to access the target PostgreSQL database.
db_username
A user that has access to the target PostgreSQL database.
host
The DNS name or IP address of the server where PostgreSQL should be running.
name
namevar
An arbitrary name used as the identity of the resource.
port
The port that the PostgreSQL server should be listening on.
provider
The specific backend to use for this postgresql_conn_validator
resource. You will seldom need to specify this ---
Puppet will usually discover the appropriate provider for your platform.
psql_path
Path to the psql command.
run_as
System user that will run the psql command.
sleep
The length of sleep time between connection tries.
Default value: 2
tries
The number of tries to validate the connection to the target PostgreSQL database.
Default value: 10
postgresql_psql
An arbitrary tag for your own reference; the name of the message.
Properties
The following properties are available in the postgresql_psql
type.
command
The SQL command to execute via psql.
Parameters
The following parameters are available in the postgresql_psql
type.
connect_settings
cwd
db
environment
name
onlyif
port
provider
psql_group
psql_path
psql_user
refreshonly
search_path
sensitive
unless
connect_settings
Connection settings that will be used when connecting to postgres
cwd
The working directory under which the psql command should be executed.
Default value: /tmp
db
The name of the database to execute the SQL command against, this overrides any PGDATABASE value in connect_settings
environment
Any additional environment variables you want to set for a SQL command. Multiple environment variables should be specified as an array.
name
namevar
An arbitrary tag for your own reference; the name of the message.
onlyif
An optional SQL command to execute prior to the main :command; this is generally intended to be used for idempotency, to check for the existence of an object in the database to determine whether or not the main SQL command needs to be executed at all.
port
The port of the database server to execute the SQL command against, this overrides any PGPORT value in connect_settings.
provider
The specific backend to use for this postgresql_psql
resource. You will seldom need to specify this --- Puppet will
usually discover the appropriate provider for your platform.
psql_group
The system user group account under which the psql command should be executed.
Default value: postgres
psql_path
The path to psql executable.
Default value: psql
psql_user
The system user account under which the psql command should be executed.
Default value: postgres
refreshonly
Valid values: true
, false
If 'true', then the SQL will only be executed via a notify/subscribe event.
Default value: false
search_path
The schema search path to use when executing the SQL command
sensitive
Valid values: true
, false
If 'true', then the executed command will not be echoed into the log. Use this to protect sensitive information passing through.
Default value: false
unless
An optional SQL command to execute prior to the main :command; this is generally intended to be used for idempotency, to check for the existence of an object in the database to determine whether or not the main SQL command needs to be executed at all.'
postgresql_replication_slot
This type allows to create and destroy replication slots to register warm standby replication on a Postgresql primary server.
Properties
The following properties are available in the postgresql_replication_slot
type.
ensure
Valid values: present
, absent
The basic property that the resource should be in.
Default value: present
Parameters
The following parameters are available in the postgresql_replication_slot
type.
name
Valid values: %r{^[a-z0-9_]+$}
namevar
The name of the slot to create. Must be a valid replication slot name.
provider
The specific backend to use for this postgresql_replication_slot
resource. You will seldom need to specify this ---
Puppet will usually discover the appropriate provider for your platform.
Functions
postgresql::default
Type: Puppet Language
This function pull default values from the params
class or globals
class if the value is not present in params
.
Examples
postgresql::default('variable')
postgresql::default(String $parameter_name)
The postgresql::default function.
Returns: Any
Examples
postgresql::default('variable')
parameter_name
Data type: String
postgresql::postgresql_escape
Type: Ruby 4.x API
This function escapes a string using Dollar Quoting using a randomly generated tag if required.
postgresql::postgresql_escape(String[1] $input_string)
The postgresql::postgresql_escape function.
Returns: String
A Dollar Quoted
string
input_string
Data type: String[1]
The unescaped string you want to escape using dollar quoting
postgresql::postgresql_password
Type: Ruby 4.x API
This function returns the postgresql password hash from the clear text username / password
postgresql::postgresql_password(Variant[String[1], Integer] $username, Variant[String[1], Sensitive[String[1]], Integer] $password, Optional[Boolean] $sensitive, Optional[Optional[Enum['md5', 'scram-sha-256']]] $hash, Optional[Optional[Variant[String[1], Integer]]] $salt)
The postgresql::postgresql_password function.
Returns: Variant[String, Sensitive[String]]
The postgresql password hash from the clear text username / password.
username
Data type: Variant[String[1], Integer]
The clear text username
password
Data type: Variant[String[1], Sensitive[String[1]], Integer]
The clear text password
sensitive
Data type: Optional[Boolean]
If the Postgresql-Passwordhash should be of Datatype Sensitive[String]
hash
Data type: Optional[Optional[Enum['md5', 'scram-sha-256']]]
Set type for password hash
salt
Data type: Optional[Optional[Variant[String[1], Integer]]]
Use a specific salt value for scram-sha-256, default is username
postgresql::prepend_sql_password
Type: Ruby 4.x API
This function exists for usage of a role password that is a deferred function
postgresql::prepend_sql_password(String $password)
The postgresql::prepend_sql_password function.
Returns: String
password
Data type: String
The clear text password
postgresql_escape
Type: Ruby 4.x API
DEPRECATED. Use the namespaced function postgresql::postgresql_escape
instead.
postgresql_escape(Any *$args)
The postgresql_escape function.
Returns: Any
*args
Data type: Any
postgresql_password
Type: Ruby 4.x API
DEPRECATED. Use the namespaced function postgresql::postgresql_password
instead.
postgresql_password(Any *$args)
The postgresql_password function.
Returns: Any
*args
Data type: Any
Tasks
sql
Allows you to execute arbitary SQL
Supports noop? false
Parameters
database
Data type: Optional[String[1]]
Database to connect to
host
Data type: Optional[String[1]]
Hostname to connect to
password
Data type: Optional[String[1]]
The password
port
Data type: Optional[String[1]]
The port
sql
Data type: String[1]
The SQL you want to execute
user
Data type: Optional[String[1]]
The user
What are tasks?
Modules can contain tasks that take action outside of a desired state managed by Puppet. It’s perfect for troubleshooting or deploying one-off changes, distributing scripts to run across your infrastructure, or automating changes that need to happen in a particular order as part of an application deployment.
Tasks in this module release
Changelog
All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog and this project adheres to Semantic Versioning.
v8.3.0 - 2023-04-21
Added
- convert ERB templates to EPP #1399 (SimonHoenscheid)
- (CONT-361) Syntax update #1397 (LukasAud)
- Add multi instance support, refactoring reload.pp (6/x) #1392 (SimonHoenscheid)
- Add multi instance support, refactoring password.pp (5/x) #1391 (SimonHoenscheid)
- Add multi instance support, refactoring late_initdb.pp (3/x) #1384 (SimonHoenscheid)
- Add multi instance support, refactoring initdb.pp (2/x) #1383 (SimonHoenscheid)
- Add multi instance support, refactoring config.pp (1/x) #1382 (SimonHoenscheid)
- pg_hba_rule: Validate userinput in postgresql::server #1376 (bastelfreak)
- pg_hba_rule: Move
type
datatype to own type #1375 (bastelfreak) - pg_hba_rule does not properly verify address parameter #1372 (tuxmea)
Fixed
- Ubuntu 14/16/17: Drop code leftovers #1388 (bastelfreak)
- remove debian 8 and 9 corpses #1387 (SimonHoenscheid)
- Archlinux client and server package names were swapped around #1381 (tobixen)
- apt::source: configure repo only for current architecture #1380 (bastelfreak)
- pdksync - (CONT-189) Remove support for RedHat6 / OracleLinux6 / Scientific6 #1371 (david22swan)
- pdksync - (CONT-130) - Dropping Support for Debian 9 #1368 (jordanbreen28)
- (maint) Codebase Hardening #1366 (david22swan)
- Fix table grant with schema #1315 (vaol)
v8.2.1 - 2022-08-24
Fixed
- Fix puppet-strings documentation #1363 (ekohl)
- (GH-1360) Reverting REFERENCE.md changes #1361 (pmcmaw)
- Only require password when used #1356 (arjenz)
v8.2.0 - 2022-08-23
Added
- pdksync - (GH-cat-11) Certify Support for Ubuntu 22.04 #1355 (david22swan)
- (MODULES-11251) Add support for backup provider "pg_dump" #1319 (fraenki)
Fixed
v8.1.0 - 2022-07-21
Added
- Fix service status detection on Debian-based OSes #1349 (arjenz)
- (FM-8971) allow deferred function for role pwd #1347 (tvpartytonight)
- Set version for Fedora 36 #1345 (lweller)
- Add Red Hat Enterprise Linux 9 support #1303 (ekohl)
Fixed
- (GH-1352) - Updating postgresql service version on SLES #1353 (pmcmaw)
- Respect $service_status on Red Hat-based distros #1351 (ekohl)
- Add version for Ubuntu 22.04 #1350 (arjenz)
- README.md: correct postgresql_conn_validator example #1332 (bastelfreak)
- pdksync - (GH-iac-334) Remove Support for Ubuntu 14.04/16.04 #1331 (david22swan)
- Remove unused variable in reload.pp #1327 (ekohl)
- Use systemctl reload on EL 7 and higher #1326 (ekohl)
v8.0.0 - 2022-03-03
Added
- add default version for Fedora 35 #1317 (jflorian)
- add scram-sha-256 support #1313 (fe80)
- add support for Ubuntu Hirsute and Impish #1312 (nicholascioli)
- Allow systemd to mask postgresql service file #1310 (kim-sondrup)
- Make ::contrib a noop on OSes without a contrib package #1309 (carlosduelo)
- pdksync - (IAC-1753) - Add Support for AlmaLinux 8 #1308 (david22swan)
- MODULES-11201: add service_name for Ubuntu 18.04 and later #1306 (moritz-makandra)
- pdksync - (IAC-1751) - Add Support for Rocky 8 #1305 (david22swan)
- Default privileges support schemas #1300 (fish-face)
- Support target_role in default_privileges #1297 (fish-face)
Changed
Fixed
- pdksync - (IAC-1787) Remove Support for CentOS 6 #1324 (david22swan)
- Fix python package name in RHEL/CentOS 8 #1316 (kajinamit)
- Drop further code for Debian 6 and Ubuntu 10 #1307 (ekohl)
v7.5.0 - 2021-09-28
Added
Fixed
- (IAC-1598) - Remove Support for Debian 8 #1302 (david22swan)
- Inline file contents in the catalog #1299 (ekohl)
- Fix changing default encoding #1296 (smortex)
v7.4.1 - 2021-08-25
Fixed
v7.4.0 - 2021-08-24
Added
- pdksync - (IAC-1709) - Add Support for Debian 11 #1288 (david22swan)
Fixed
v7.3.0 - 2021-08-03
Added
- MODULES-11049 - Implement default privileges changes #1267 (mtancoigne)
Fixed
- Do not add version component to repo definition #1282 (weastur)
- (MODULES-8700) Autorequire the service in postgresql_psql #1276 (ekohl)
v7.2.0 - 2021-05-24
Added
- (MODULES-11069) add default version for fedora 34 #1272 (lweller)
- MODULES-11047 - Allow managing rights for PUBLIC role #1266 (mtancoigne)
v7.1.0 - 2021-04-12
Added
v7.0.3 - 2021-04-12
v7.0.2 - 2021-03-15
Fixed
- (MODULES-10957) Override the set_sensitive_parameters method #1258 (sheenaajay)
v7.0.1 - 2021-03-08
Fixed
v7.0.0 - 2021-03-04
Added
Changed
- pdksync - (MAINT) Remove SLES 11 support #1247 (sanfrancrisko)
- pdksync - (MAINT) Remove RHEL 5 family support #1246 (sanfrancrisko)
- pdksync - Remove Puppet 5 from testing and bump minimal version to 6.0.0 #1238 (carabasdaniel)
v6.10.2 - 2021-02-22
Fixed
v6.10.1 - 2021-02-09
v6.10.0 - 2021-02-08
Added
- Set default PostgreSQL version for FreeBSD #1227 (olevole)
- Clean up globals logic to support CentOS 8 stream #1225 (ekohl)
Fixed
- Also perform systemd daemon-reload on Puppet 6.1+ #1233 (ekohl)
- (bug) fix systemd daemon-reload order when updating service files #1230 (sheenaajay)
- Fix postgresql::sql task when password is not set #1226 (smortex)
v6.9.0 - 2021-01-18
Added
- pdksync - (feat) - Add support for puppet 7 #1215 (daianamezdrea)
- Manage postgresql_conf_path file permissions #1199 (ekohl)
Fixed
- (maint) updated defaults for rhel7 policycoreutils #1212 (sheenaajay)
- (IAC-1189) - Fix for SLES 15 SP 1 and later #1209 (david22swan)
- Change - Use systemd drop-in directory for unit overrides #1201 (blackknight36)
v6.8.0 - 2020-09-29
Added
- add hostgssenc type to pg_hba rules #1195 (osijan)
- Allow removal of config_entries via main class #1187 (ekohl)
Fixed
v6.7.0 - 2020-08-28
Added
- pdksync - (IAC-973) - Update travis/appveyor to run on new default branch
main
#1182 (david22swan)
v6.6.0 - 2020-06-22
Added
- (IAC-746) - Add ubuntu 20.04 support #1172 (david22swan)
Fixed
- Invert psql/package dependency logic #1179 (raphink)
- Fix custom port in extension #1165 (Vampouille)
v6.5.0 - 2020-05-13
Added
- service_ensure => true is now an allowed value (aliased to running) #1167 (binford2k)
- Finish conversion of
postgresql_acls_to_resources_hash
function #1163 (alexjfisher) - Finish conversion of
postgresql_escape
function #1162 (alexjfisher) - Finish conversion of
postgresql_password
function #1161 (alexjfisher) - Allow usage of grant and role when not managing postgresql::server #1159 (tuxmea)
- Add version configs for SLES 12 SP 3 to 5 #1158 (XnS)
- Add extra parameter "extra_systemd_config" #1156 (veninga)
Fixed
- (MODULES-10610) Use correct lower bound for concat version #1160 (ghoneycutt)
v6.4.0 - 2020-03-17
Added
- Add Fedora 31 compatibility #1141 (blackknight36)
- feat: enable different database resource name in extension #1136 (jfroche)
- pdksync - (FM-8581) - Debian 10 added to travis and provision file refactored #1130 (david22swan)
- Puppet 4 functions #1129 (binford2k)
Fixed
- Fix incorrectly quoted GRANT cmd on functions #1150 (olifre)
- Correct versioncmp logic in config.pp #1137 (boydtom)
- Treat $version as an integer for comparison, defaults to string #1135 (boydtom)
- Allow usage of PUBLIC role #1134 (Vampouille)
- fix missing systemd override config for EL8 (CentOS and RHEL) #1131 (david-barbion)
v6.3.0 - 2019-12-18
Added
- Add support for granting privileges on functions #1118 (crispygoth)
- (FM-8679) - Support added for CentOS 8 #1117 (david22swan)
- MODULES-10041 - allow define password_encryption for version above 10 #1111 (k2patel)
Fixed
- Remove duplicate REFERENCE.md file with strange unicode character at end of filename #1108 (nudgegoonies)
v6.2.0 - 2019-09-13
Added
- FM-8408 - add support on Debian10 #1103 (lionce)
- Fix/directory defined twice #1089 (arcenik)
- Adding SLES 15 #1087 (msurato)
- (FM-7500) conversion to use litmus #1081 (tphoney)
Fixed
- (MODULES-9658) - custom ports are not labeled correctly #1099 (blackknight36)
- Fix: When assigning a tablespace to a database, no equal sign is needed in the query #1098 (biertie)
- Grant all tables in schema fixup #1096 (georgehansper)
- (MODULES-9219) - puppetlabs-postgresql : catalog compilation fails when the service command is not installed #1093 (blackknight36)
v6.1.0 - 2019-06-04
Added
v6.0.0 - 2019-05-14
Added
- Add Fedora 30 compatibility #1067 (blackknight36)
- Include EL8 version for config checks #1060 (ehelms)
Changed
- pdksync - (MODULES-8444) - Raise lower Puppet bound #1070 (david22swan)
- (maint) remove inconsistent extra variable #1044 (binford2k)
Fixed
- Support current version of puppetlabs/apt. #1073 (pillarsdotnet)
- change username/group/datadir defaults for FreeBSD #1063 (olevole)
5.12.1 - 2019-02-14
Fixed
- (FM-7811) - Use postgresql 9.4 for SLES 11 sp4 #1057 (david22swan)
- (MODULES-8553) Further cleanup for package tag issues #1055 (HelenCampbell)
5.12.0 - 2019-02-01
Added
Fixed
- (MODULES-8553) Fix dependency on apt by explicitly using 'puppetlabs-postgresql' as tag #1052 (HelenCampbell)
- (MODULES-8352) Don't use empty encoding string on initdb #1043 (binford2k)
- pdksync - (FM-7655) Fix rubygems-update for ruby < 2.3 #1042 (tphoney)
5.11.0 - 2018-11-21
Added
Fixed
- Strip quotes from role names #1034 (jstuart)
- Ignore .psqlrc so output is clean and doesn't break Puppet #1021 (flaviogurgel)
- Change initdb option '--xlogdir' to '-X' for PG10 compatibility #976 (fcanovai)
5.10.0 - 2018-09-27
Added
5.9.0 - 2018-09-07
Added
5.8.0 - 2018-08-07
Added
- metadata.json: bump allowed version of puppetlabs-apt to 6.0.0 #1012 (mateusz-gozdek-sociomantic)
5.7.0 - 2018-07-20
Added
- (MODULES-7479) Update postgresql to support Ubuntu 18.04 #1005 (david22swan)
- (MODULES-6542) - Adding SLES 11 & 12 to metadata #1001 (pmcmaw)
Fixed
- (MODULES-7479) Ensure net-tools is installed when testing on Ubuntu 18.04 #1006 (david22swan)
- (MODULES-7460) - Updating grant table to include INSERT privileges #1004 (pmcmaw)
- Fix packages choice for ubuntu 17.10 #1000 (fflorens)
5.6.0 - 2018-06-21
5.5.0 - 2018-06-19
Added
- Add compatibility for Fedora 28 #994 (jflorian)
- (MODULES-5994) Add debian 9 #992 (hunner)
- Adding default Postgresql version for Ubuntu 18.04 #981 (lutaylor)
- Parameters
roles
,config_entires
, andpg_hba_rules
topostgresql::server
for hiera #950 (ekohl)
Changed
Fixed
5.4.0 - 2018-03-27
Added
- (MODULES-6330) PDK convert 1.4.1 #961 (pmcmaw)
- Parameter
ensure
onpostgresql::server::grant
andpostgresql::server::database_grant
#891 (georgehansper)
Fixed
- Documentation error,
reassign_owned_by
uses*_role
not*_owner
. #958 (computermouth)
5.3.0 - 2018-02-26
Fixed
Other
- (maint) - Skip run_puppet_access_login on LTS #956 (pmcmaw)
- add task listing to README, edit #955 (jbondpdx)
- 5.3.0 Pre Release #954 (david22swan)
- Rubocop Process Complete #953 (david22swan)
- (MODULES-6608) - Adding puppet requirement for tasks versioncmp in beaker-task_helper #952 (pmcmaw)
- Support extension schemas #948 (hasegeli)
- (maint) modulesync 65530a4 Update Travis #946 (michaeltlombardi)
- Inherit 9.6 settings for later PgSQL version on FreeBSD #945 (olevole)
- (maint) - modulesync 384f4c1 #944 (tphoney)
- According to the puppet doc, Pattern should be a list of regex. #942 (PierreR)
- MODULES-6194 - Add scram-sha-256 as a valid pg_hba_rule auth method #941 (f3nry)
- (maint) - modulesync 1d81b6a #939 (pmcmaw)
- Merge back release (5.2.1) into master #938 (glennsarti)
- (MODULES-6014) Add support for Fedora 27 to puppetlabs-postgresql #937 (blackknight36)
- This pull request fixes an augeas warning #935 (iakovgan)
- FM-6445 add a task #930 (tphoney)
- add ensure=>absent to postgresql::server::role #897 (georgehansper)
5.2.1 - 2017-11-14
Fixed
- add parameter "version" to postgresql::server::extension - fix dependency on database #932 (georgehansper)
Other
- (maint) - Removing Debian 9 #936 (pmcmaw)
- (MODULES-5956) fixes for postgresql release #934 (jbondpdx)
- (MODULES-5955) release prep for 5.2.1 #933 (eputnam)
- 5.2.0 Release Mergeback #928 (HelenCampbell)
5.2.0 - 2017-10-09
Other
- Updates to Changelog for release prep #927 (pmcmaw)
- Merge master into release #926 (HelenCampbell)
- (PUP-8008) monkey patch spec_helper_acceptance #925 (eputnam)
- (PUP-8008) monkey patch spec_helper_acceptance #924 (eputnam)
- (FM-6386) Minor docs fixup for 5.2.0 release #923 (HAIL9000)
- Removing Debian 6 and adding Debian 9 #921 (pmcmaw)
- 5.2.0 Release Prep #920 (HelenCampbell)
- Updates test to reflect new error message #919 (HelenCampbell)
- (maint) modulesync 892c4cf #918 (HAIL9000)
- enhance --data-checksums on initdb #915 (mmoll)
- use postgresql 9.6 for the newest SLES and openSUSE releases #914 (tampakrap)
- Change - Add support for Fedora 26 #913 (blackknight36)
- (MODULES-5501) - Remove unsupported Ubuntu #912 (pmcmaw)
- Added default posgresql version of Ubuntu 17.4 version to the global… #911 (hozmaster)
- (MODULES-4854) remove allow_deprecations #910 (eputnam)
- MODULES-5378 fix the change in error message #909 (tphoney)
- MODULES-5378 fix error message checking in test #908 (tphoney)
- (maint) modulesync 915cde70e20 #907 (glennsarti)
- (MODULES-5232) - Updating docs formatting. #905 (pmcmaw)
- 5.1.0 Release Mergeback #904 (HelenCampbell)
- Replace deprecated function calls #901 (matonb)
- Default contcat order #900 (matonb)
- Deprecated tests #899 (matonb)
- add parameter "version" to postgresql::server::extension to update the extension version #896 (georgehansper)
- (MODULES-4682) Pass default_connect_settings to validate service #862 (vinzent)
5.1.0 - 2017-07-17
Other
- (MODULES-4711) - 5.1.0 Release Prep #903 (pmcmaw)
- Adding a space for header formatting #902 (pmcmaw)
- (FM-6240) only run test on postgresql >= 9.0 #898 (tphoney)
- (MODULES-5187) mysnc puppet 5 and ruby 2.4 #895 (eputnam)
- add defined type postgresql::server::reassign_owned_by #894 (georgehansper)
- Allow order parameter to be string value #893 (matonb)
- Fix Ruby 2.4 deprecation in postgresql_acls_to_resources_hash #892 (mmoll)
- (MODULES-5144) Prep for puppet 5 #889 (hunner)
- use https for apt.postgresql.org repo #888 (hex2a)
- 5.0.0 mergeback #887 (hunner)
- MODULES-2989 parameter ensure of custom resource postgresql_replication_slot is not documented #884 (MartyEwings)
- add data_checksums option to initdb #878 (tjikkun)
5.0.0 - 2017-06-21
Changed
- Unset default log_line_prefix #870 (hasegeli)
- Let listen_addresses be defined independently #865 (hasegeli)
Other
- (maint) address more changelog cleanup #886 (eputnam)
- (maint) changelog cleanup for 5.0.0 #885 (eputnam)
- (MODULES-5062) release prep 5.0.0 #883 (eputnam)
- (maint) fix for connection validator #882 (eputnam)
- (MODULES-5050) Fix for grant_schema_spec #881 (eputnam)
- (MODULES-5050) pass auth_option in grant_role_spec #880 (eputnam)
- (MODULES-1394) replace validate_db_connection type with custom type #879 (eputnam)
- Cleanup README #877 (hasegeli)
- (maint) mock structured facts #875 (eputnam)
- (maint) Fix docs for #870 #873 (hunner)
- MODULES-4826 puppetlabs-postgresql: Update the version compatibility to >= 4.7.0 < 5.0.0 #871 (marsmensch)
- (MODULES-4947) bump apt dependency in metadata + fixtures #869 (bastelfreak)
- Maintain config entries for PostgreSQL 10 #868 (hasegeli)
- (MODULES-4906) Add support for concat 3.0.0 and 4.0.0 #867 (dhollinger)
- Release mergeback #866 (hunner)
- MODULES-4324 - README Updates for Translation. #864 (pmcmaw)
- [MODULES-4598] Revert "Revert "fix default params for SUSE family OSes"" #863 (mmoll)
- [msync] 786266 Implement puppet-module-gems, a45803 Remove metadata.json from locales config #860 (wilson208)
- [MODULES-4598] Revert "fix default params for SUSE family OSes" #858 (wilson208)
- (FM-6116) - Adding POT file for metadata.json #857 (pmcmaw)
- [MODULES-4528] Replace Puppet.version.to_f version comparison from spec_helper.rb #856 (wilson208)
- Align postgis default version with postgres version #854 (georgehansper)
- (maint) Fix CI issue where acceptance tests fail on SLES #853 (wilson208)
- Migrate to puppet4 datatypes #852 (bastelfreak)
- fix default params for SUSE family OSes #851 (tampakrap)
- Allowo to disable managing passwords for users #846 (bjoernhaeuser)
- Change - Remove deprecated force parameter on concat resources #843 (blackknight36)
- Remove deprecated force parameter from concat #831 (ekohl)
4.9.0 - 2017-03-09
Changed
Other
- release prep for 4.9.0 #849 (eputnam)
- Update $allowed_auth_methods for newer PostgreSQL versions 9.5 and 9.6 #848 (ardrigh)
- (MODULES-1707) add logic to params.pp for jdbc driver package on Debian #847 (eputnam)
- (MODULES-1508) add support for unix_socket_directories #845 (eputnam)
- (maint) accomodate old pgsql version #844 (eputnam)
- support Debian/stretch and Ubuntu/yakkety #842 (mmoll)
- (maint) fix grant_spec test #841 (eputnam)
- (maint) Schemas for a db should come after db #840 (hunner)
- (MODULES-1127) allow LANGUAGE as valid object_type #838 (eputnam)
- Fix typo: hostnosssl #837 (df7cb)
- Implement beaker-module_install_helper and cleanup spec_helper_acceptance.rb #836 (wilson208)
- (MODULES-4098) Sync the rest of the files #835 (hunner)
- Fix validation script to work with dash #833 (sathieu)
- (MODULES-4097) Sync travis.yml #832 (hunner)
- Remove unnecessary
client_package_name
parameter from server. #830 (tdevelioglu) - F25 update #829 (blackknight36)
- (FM-5972) gettext and spec.opts #828 (eputnam)
- Change - Ensure that the postgres data dir has proper selinux context #827 (blackknight36)
- (maint) fixes for grant_spec #826 (eputnam)
- (FM-5939) removes spec.opts #825 (eputnam)
- (MODULES-3631) msync Gemfile for 1.9 frozen strings #824 (hunner)
- Support granting SELECT and UPDATE permission on sequences (MODULES-4158) #823 (chris-reeves)
- Pick 808 #821 (tphoney)
- Override repo urls #820 (DavidS)
- Set permissions/ownership on rpm gpg key #819 (benpillet)
- (MODULES-4051) updates yum repo #818 (eputnam)
- Change default user, group and data directory to proper value on Free… #816 (olevole)
- (MODULES-3704) Update gemfile template to be identical #815 (hunner)
- MODULES-3816 no release 3.4.3 fixing changelog #814 (tphoney)
- Fix grant documentation #813 (hasegeli)
- Change - Add default postgres version for Fedora 24 to globals class #811 (blackknight36)
- Add support for Gentoo-based operatingsystems #810 (optiz0r)
- Fixed unless check in grant_role so that it can grant roles to superusers #809 (crispygoth)
- (MODULES-3983) Update parallel_tests for ruby 2.0.0 #807 (pmcmaw)
- (MODULES-1850) replace validate_string by validate_re for real verification on input #806 (jhooyberghs)
- globals: add postgis version for 9.6 #804 (costela)
- Adding a negative test case for grant role #802 (pmcmaw)
- (MODULES-3844) adds single revoke test #800 (eputnam)
- Update modulesync_config [51f469d][#799](https://github.com/puppetlabs/puppetlabs-postgresql/pull/799) (DavidS)
- Remove duplicate RedHat default section #798 (jesusaurus)
- Support changing database tablespaces #795 (hasegeli)
- Fix SQL style on role.pp #794 (hasegeli)
- Default role of grant_role to namevar #793 (hasegeli)
- Improvements around changing owners #792 (hasegeli)
- Revert "Update config_entry.pp add ability to set log_min_duration_statement" #791 (hasegeli)
- (#3858) Fix unless check in grant_role to work with roles as well as users #788 (thunderkeys)
- Update modulesync_config [a3fe424][#787](https://github.com/puppetlabs/puppetlabs-postgresql/pull/787) (DavidS)
- Allow working directory to be configurable via globals (instead of always using /tmp) #786 (hdeadman)
- handle case where default database name is not the same as user #785 (hdeadman)
- Merge back #783 (DavidS)
- (MAINT) Update for modulesync_config 72d19f184 #782 (DavidS)
- Add .erb suffix to recovery.conf template #777 (tdevelioglu)
- Allow username and password as integers #774 (sathieu)
- Grant role with unit tests #762 (janfabry)
4.8.0 - 2016-07-26
Other
- Prep for 4.8.0 #781 (DavidS)
- (MODULES-3247) Enable schema and database ownership change #779 (ntpttr)
- (MODULES-3581) modulesync [067d08a][#778](https://github.com/puppetlabs/puppetlabs-postgresql/pull/778) (DavidS)
- {maint} modulesync 0794b2c #776 (tphoney)
- Update config_entry.pp add ability to set log_min_duration_statement #773 (micah-uber)
- Let the module handle OpenBSD 6.x versions #772 (buzzdeee)
- (MODULES-3442) Use empty array for missing resource relationships #771 (domcleal)
- don't create empty lines in recovery template #769 (bastelfreak)
- (maint) fix broken links in readme #767 (wkalt)
- (MODULES-3416) Add Fedora 24 with PostgreSQL 9.5 #766 (domcleal)
- Don't overwrite or calculate the environment twice #761 (janfabry)
- Fix validation script to work with FreeBSD. #760 (blackknight36)
- Update to newest modulesync_configs [9ca280f][#759](https://github.com/puppetlabs/puppetlabs-postgresql/pull/759) (DavidS)
- (MODULES-3241) Add fedora 23 #758 (hunner)
- (maint) fix test to run under strict variables #755 (DavidS)
- Adds timestamps into logs by default #754 (xprazak2)
- Minor Fixes on the Documentation #752 (hasegeli)
- prevent information leak of database user password #749 (buzzdeee)
- Remove unused variable and update template comment #748 (hunner)
- Fix issues with missing parameters in
server
class #747 (cyberious) - Ubuntu/vidid and newer use systemd #746 (mmoll)
- Mergeback 4.7.x to master #745 (bmjen)
4.7.1 - 2016-02-18
Other
- Update quoting because addresses are not floats #744 (hunner)
- 4.7.1 Release Prep #743 (bmjen)
- Revert "Add postgresql_version fact" #742 (bmjen)
- (FM-4046) Update to current msync configs [006831f][#741](https://github.com/puppetlabs/puppetlabs-postgresql/pull/741) (DavidS)
- Add missing onlyif_function to sequence grant code #738 (cfrantsen)
- correcting formatting error in README #737 (jbondpdx)
- postgres server init script naming on amazon linux ami #736 (Aselinux)
- Correctly set $service_provider #735 (antaflos)
- Archlinux service reload parameter is incorrect. #734 (gfokkema)
- Fix markdown error in README #732 (martijn)
- amazon linux defaults to postgresql92 now #731 (shawn-sterling)
- 4.7.x mergeback to master #730 (bmjen)
- Fix quoting #729 (hunner)
- Allow puppetlabs-concat 2.x #725 (brandonweeks)
- Add postgresql_version fact #720 (jyaworski)
- Fix password change failing #719 (matonb)
4.7.0 - 2016-02-02
Other
- (MODULES-3024) Quote database objects when creating databases #727 (supercow)
- Escape case where password ends with '$'. #726 (Farzy)
- Changelog, metadata and nodeset update for 4.7.0 #724 (HelenCampbell)
- Whoops #723 (hunner)
- MODULES-3019 - Schedule apt update after install of repo #722 (erikanderson)
- (MODULES-2960) Allow float postgresql_conf values #721 (hunner)
- FM-4657: postgresql edit pass #718 (jbondpdx)
- Fix postgresql::server acceptance test descriptions #717 (gerhardsam)
- Add default postgis version for 9.5 #716 (hunner)
- (FM-4049) update to modulesync_configs #715 (DavidS)
- DOC-1496: README re-write. #714 (jtappa)
- OpenBSD 5.9 will also ship a PostgreSQL 9.4 version #712 (buzzdeee)
- Add support for Ubuntu 15.10 #711 (pherjung)
- 4.6.x Mergeback #710 (HelenCampbell)
- readme update: postgresql::server::db is a defined type not a class #709 (jessereynolds)
4.6.1 - 2015-12-04
Added
Other
- fix quote around locale options #708 (freegenie)
- 4.6.1 release prep #707 (tphoney)
- (maint) removes ruby 1.8.7 and puppet 2.7 from travis-ci jobs #706 (bmjen)
- OpenBSD version is now 9.4 #705 (oriold)
- Fix default paths for Amazon Linux #704 (downsj2)
- Fix line endings #703 (karyon)
- Use double qoutes around database name. #702 (stintel)
- Remove extra blanks and backslashes. #701 (smortex)
- syntax error near UTF8 #700 (BobVanB)
- "fedora 22 postgresql version 9.4" #698 (nibalizer)
- Change apt::pin to apt_postgresql_org to prevent error message #695 (Danie)
- MODULES-2525 - updated systemd-override to support fedora and CentOS paths for systemd #694 (jbehrends)
- Fixes MODULES_2059 - adds extension argument #693 (frconil)
- 4.6.x mergeback to master #692 (bmjen)
- updates metadata.json to match Puppet 4.x PMT output #691 (bmjen)
- removed inherits postgresql::params #679 (vicinus)
4.6.0 - 2015-09-01
Other
- (MAINT) do not run the multi-node tests by default #689 (DavidS)
- (MODULES-661) Remote DB support #688 (DavidS)
- 4_6_0 release prep #682 (tphoney)
- Decouple pg_hba_rule from postgresql::server #678 (npwalker)
- (MODULES-2211) Fixed systemd-override for RedHat systems with unmanag… #677 (cavaliercoder)
- Fix postgis default package name on RedHat #674 (ckaenzig)
- Add proxy option for yum repositories #672 (GoozeyX)
- Allow for undefined PostGIS version. #671 (SteveMaddison)
4.5.0 - 2015-07-28
Other
4.4.2 - 2015-07-08
Added
Other
- Fix incorrect metadata #669 (hunner)
- updates metadata.json to include support for pe 2015.2 #668 (bmjen)
- 4.4.2 prep #667 (bmjen)
- Support granting permission on sequences. #665 (bmjen)
- (MODULES-2185) Fix
withenv
execution under Puppet 2.7 #664 (domcleal) - 4.4.x mergeback #662 (bmjen)
- Add default values for more openSUSE and SLES distro versions #615 (tampakrap)
4.4.1 - 2015-07-01
Other
- Increment version number for 4.4.1 #660 (DavidS)
- (MODULES-2181) Fix variable scope for systemd-override #659 (kbarber)
4.4.0 - 2015-06-30
Other
- fixes postgresql::server:recovery acceptance tests #658 (bmjen)
- adds acceptance tests for postgresql::server::recovery resource #657 (bmjen)
- updates release date on CHANGELOG #655 (bmjen)
- (FM-2931) fixes logic problem with onlyif type param validation. #654 (bmjen)
- (FM-2923) install net-tools for tests #653 (bmjen)
- (FM-2923) install net-tools for tests #651 (DavidS)
- (maint) Fix tests from #527 merge - Looks like copy tests mismatched logic of when it should expect changes #650 (cyberious)
- Sync with master #648 (bmjen)
- Unpins apt 1.8 dependency in fixtures.yml and spec_helper_acceptance. #647 (bmjen)
- Release 4.4.0 prep #646 (bmjen)
- (maint) Add beaker-puppet_install_helper and fix fact bug #645 (cyberious)
- Update dependencies #644 (underscorgan)
- Show support for Puppet v4 in the metadata #643 (ghoneycutt)
- tightens concat dependency to < 2.0.0 #641 (bmjen)
- Fixed systemd override for manage_repo package versions #639 (cdenneen)
- Updated travisci file to remove allow_failures on Puppet 4 #635 (jonnytdevops)
- Add plpython and postgresql-docs classes #634 (DavidS)
- disabling pg_hba_conf_defaults should not disable ipv4acls and ipv6ac… #633 (b0e)
- Copy snakeoil certificate and key instead of symlinking #629 (mcanevet)
- Support puppetlabs-concat 2.x #626 (domcleal)
- add ubuntu/vivid support #624 (saimonn)
- (#2049) Make title of psql resource for schema creation unique #623 (dirkweinhardt)
- Modulesync updates #619 (underscorgan)
- Apt fix #618 (tphoney)
- (MODULES-2007) Fix Puppet.newtype deprecation warning #616 (roman-mueller)
- update fixtures file with new concat dependencies #612 (bmjen)
- Antaflos patch 2 #609 (hunner)
- MODULES-1923 - Use the correct command with Puppet < 3.4 #608 (underscorgan)
- Merge 4.3.x back to master #605 (hunner)
- (MODULES-1761) Provide defined resource for managing recovery.conf #603 (dacrome)
- Reorder environment and require parameter, to unbreak #602 (buzzdeee)
- Fix URLs in metadata.json #599 (raphink)
- (BKR-147) add Gemfile setting for BEAKER_VERSION for puppet... #596 (anodelman)
- Update apt key to full 40characters #591 (exptom)
- Add param for specifying validate connection script in postgresql::client. #410 (riton)
4.3.0 - 2015-03-25
Other
- Update readme with types docs #598 (hunner)
- Update changelog for merge of #591 #597 (hunner)
- Supported Release 4.3.0 #595 (hunner)
- Testing updates #593 (cmurphy)
- (MODULES-1878) properly quote create and drop extension statements #592 (exi)
- Since this was in an osfamily block it was getting picked up on ubuntu #588 (underscorgan)
- Fix acceptance tests for EL #587 (underscorgan)
- Adjust $service_status for Debian Jessie #586 (raphink)
- Use space. Join seems to be defaulting to comma. #585 (kwolf-zz)
- Fix specs for #567 #584 (hunner)
- Fix the handling of run_unless_sql_command in puppet 4 #583 (hunner)
- postgresql::server::extension needs to have defaults for postgresql_psql #582 (rvstaveren)
- Merge 4.2.x to master #581 (underscorgan)
- Replication type #580 (raphink)
- (MODULES-1834) Be less strict when changing template1 encoding #579 (sathieu)
- Make granting on ALL TABLES IN SCHEMA idempotent #564 (antaflos)
- Allowing validation of db connection for more than one user and port #560 (uuid0)
4.2.0 - 2015-03-10
Other
- Remove references to host parameter since the vote was to revert that #578 (underscorgan)
- Revert "(MODULES-661) Add host parameter to psql commands" #577 (underscorgan)
- 4.2.0 prep #576 (underscorgan)
- Rework defaults for
$object_name
inpostgresql::server::grant
#574 (underscorgan) - Openbsd support #573 (underscorgan)
- README had outdated upgrade info #572 (underscorgan)
- (MAINT) Fixes incorrect rspec it description #570 (petems)
- (MODULES-661) Add host parameter to psql commands #568 (petems)
- Use correct TCP port when checking password #567 (antaflos)
- Fix for future parser #566 (mcanevet)
- create role before database #565 (gerhardsam)
- This wasn't matching anything other than psql 8 #562 (hunner)
- doc links should point to /current/ rather than a specific version #561 (igalic)
- Fix comment detection #559 (hunner)
- Fix comment detection #558 (hunner)
- Require server package before user permissions #557 (hunner)
- Pin rspec gems #556 (cmurphy)
- change example of postgresql::server::role definition to version 3 #555 (phaf)
- FreeBSD PostgreSQL wouldn't start first time #554 (leepa)
- Replace require by include #553 (PierreR)
- Fix lint warnings #552 (juniorsysadmin)
- (MODULES-1153) Add database comment parameter #551 (juniorsysadmin)
- Fix invalid byte sequence in US-ASCII error #549 (arioch)
- Add IntelliJ files to the ignore list #548 (cmurphy)
- Update .travis.yml, Gemfile, Rakefile, and CONTRIBUTING.md #544 (cmurphy)
- Update README.md #542 (dhoppe)
- Minor README internal resource linking fixes. #541 (bemosior)
- Fix/encoding #540 (mcanevet)
- MODULES-1522 Add service_manage parameter #539 (juniorsysadmin)
- Allow per-schema grants and support for 'ALL TABLES IN SCHEMA' #538 (mattbostock)
- Update for using Geppetto plugin in CI #537 (justinstoller)
- Fixing autodetected version for Debian Jessie, which should use postgresql 9.4 #535 (Zouuup)
- MODULES-1485 Reverted to default behavior for Debian systems as pg_config should not be overridden #534 (cyberious)
- FM-1523: Added module summary to metadata.json #532 (jbondpdx)
- add utopic support #529 (pherjung)
- merge 4.1.x into master #526 (underscorgan)
- Add postgresql::server::extension definition #521 (raphink)
4.1.0 - 2014-11-04
Other
- Let's actually have the version number #525 (underscorgan)
- Fix errors with future parser #520 (underscorgan)
- 4.1.0 prep #519 (underscorgan)
- Fix data directory handling #517 (cmurphy)
- Added fc21 default version #516 (david-caro)
- Link to the sysconfig file for the init script of the PGDG postgresql se... #515 (lofic)
- Adds support for PGDATA changing #514 (mixacha)
- Update PE compatibility info in metadata #512 (cmurphy)
- Add some missing params documentation #508 (ckaenzig)
- $login parameter in server/role.pp defaults to true. doc says false. #506 (tobyw4n)
- fix future parser error #504 (steeef)
- Fixed description for schema example #503 (petehayes)
- Fix some typo's in Readme and specfile. #502 (aswen)
- postgresql.org now has a RHEL7 repo available #501 (cfeskens)
- ticket/MODULES-1298 #484 (tbartelmess)
4.0.0 - 2014-09-10
Other
- We don't test on Scientific 7 #499 (underscorgan)
- Include postgresql::server class for specs #497 (hunner)
- Update metadata for 4.0 #496 (underscorgan)
- Force concat install #493 (underscorgan)
- Force concat install #492 (underscorgan)
- Remove trailing whitespace. #489 (apenney)
- Fix port changing. #488 (apenney)
- Allow failures. #487 (apenney)
- Fix the spec helper to apply selinux to agents only. #486 (apenney)
- This can't be refreshonly. #485 (apenney)
- Unfortunately this didn't work on > 9.3 in practice. #483 (apenney)
- Revert "Support changing PGDATA on RedHat" #481 (apenney)
- Update spec_helper for more consistency #480 (underscorgan)
- Fix indentation. #479 (apenney)
- Fix lsbmajdistreleasee fact for Ubuntu #477 (kbarber)
- Remove firewall management #476 (hunner)
- Bump deps for postgresql 4.0 release #475 (hunner)
- Don't test on 3.5.0.rc3 any more #474 (hunner)
- Support changing PGDATA on RedHat #473 (mhjacks)
- Fixed deprecation warning for class param in server.pp. #471 (poikilotherm)
- remove duplicatie "description" line from Metadata.json #470 (igalic)
- Fixes the accidental erasing of pg_ident.conf #464 (txaj)
- doc: Fix anchor links in README TOC #459 (juxtin)
- Add correct documentation for pg_ident_rule type #458 (stdietrich)
- MODULES-1213 link pg_config binary into /usr/bin if not already in /usr/bin or /usr/local/bin #450 (jantman)
- Initdb should create xlogdir if it has been set. #448 (aswen)
- Add support for SLES 11 #437 (dinerroger)
3.4.2 - 2014-08-06
Other
- This seems to fix up selinux for tablespace. #463 (apenney)
- Prepare 3.4.2 release. #462 (apenney)
- Make sure this works on Fedora as well as RHEL7. #461 (apenney)
- Manage pg_ident.conf by default #460 (hunner)
- doc: use postgresql::server::tablespace in example #457 (igalic)
- defined type for creating database schemas #456 (igalic)
- Merge 3.4.x changes into master. #454 (apenney)
- Fix Fedora support by configuring systemd, not /etc/sysconfig #453 (kbarber)
- Create the pg_ident_rule defined type #452 (txaj)
3.4.1 - 2014-07-21
Other
- Prepare a 3.4.1 release. #451 (apenney)
- Spec tests rewrite #449 (apenney)
- Remove the ensure => absent uninstall code. #442 (apenney)
3.4.0 - 2014-07-09
Added
Fixed
Other
Dependencies
- puppetlabs/stdlib (>= 4.13.1 < 9.0.0)
- puppetlabs/apt (>= 2.0.0 < 10.0.0)
- puppet/systemd (>= 4.0.1 < 5.0.0)
- puppetlabs/concat (>= 4.1.0 < 8.0.0)
Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and (b) You must cause any modified files to carry prominent notices stating that You changed the files; and (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "[]" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives. Copyright [yyyy] [name of copyright owner] Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Quality checks
We run a couple of automated scans to help you assess a module’s quality. Each module is given a score based on how well the author has formatted their code and documentation and select modules are also checked for malware using VirusTotal.
Please note, the information below is for guidance only and neither of these methods should be considered an endorsement by Puppet.
Malware scan results
The malware detection service on Puppet Forge is an automated process that identifies known malware in module releases before they’re published. It is not intended to replace your own virus scanning solution.
Learn more about malware scans- Module name:
- puppetlabs-postgresql
- Module version:
- 8.3.0
- Scan initiated:
- April 21st 2023, 3:16:23
- Detections:
- 0 / 60
- Scan stats:
- 59 undetected
- 0 harmless
- 1 failures
- 0 timeouts
- 0 malicious
- 0 suspicious
- 14 unsupported
- Scan report:
- View the detailed scan report