Skip to content

Commit 5d39ac5

Browse files
committed
Merge tag 'v10.6.1' into feature/create-extension-version
2 parents 7769f8a + 1bbeeb0 commit 5d39ac5

8 files changed

Lines changed: 25 additions & 15 deletions

File tree

CHANGELOG.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,15 @@ All notable changes to this project will be documented in this file.
55

66
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](http://semver.org).
77

8+
## [v10.6.1](https://github.com/puppetlabs/puppetlabs-postgresql/tree/v10.6.1) - 2025-12-26
9+
10+
[Full Changelog](https://github.com/puppetlabs/puppetlabs-postgresql/compare/v10.6.0...v10.6.1)
11+
12+
### Fixed
13+
14+
- Replace systemctl `status` with systemctl `is-active` [#1652](https://github.com/puppetlabs/puppetlabs-postgresql/pull/1652) ([bastelfreak](https://github.com/bastelfreak))
15+
- Don't use type alias in `postgresql_password` parameter [#1611](https://github.com/puppetlabs/puppetlabs-postgresql/pull/1611) ([figless](https://github.com/figless))
16+
817
## [v10.6.0](https://github.com/puppetlabs/puppetlabs-postgresql/tree/v10.6.0) - 2025-10-13
918

1019
[Full Changelog](https://github.com/puppetlabs/puppetlabs-postgresql/compare/v10.5.0...v10.6.0)

REFERENCE.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1006,7 +1006,7 @@ Default value: `$postgresql::params::service_reload`
10061006

10071007
##### <a name="-postgresql--server--service_status"></a>`service_status`
10081008

1009-
Data type: `Optional[String[1]]`
1009+
Data type: `Optional[Variant[Array[String[1]],String[1]]]`
10101010

10111011
Overrides the default status check command for your PostgreSQL service.
10121012

@@ -4742,7 +4742,7 @@ Type: Ruby 4.x API
47424742

47434743
This function returns the postgresql password hash from the clear text username / password
47444744

4745-
#### `postgresql::postgresql_password(Variant[String[1], Integer] $username, Variant[String[1], Sensitive[String[1]], Integer] $password, Optional[Boolean] $sensitive, Optional[Optional[Postgresql::Pg_password_encryption]] $hash, Optional[Optional[Variant[String[1], Integer]]] $salt)`
4745+
#### `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)`
47464746

47474747
The postgresql::postgresql_password function.
47484748

@@ -4768,7 +4768,7 @@ If the Postgresql-Passwordhash should be of Datatype Sensitive[String]
47684768

47694769
##### `hash`
47704770

4771-
Data type: `Optional[Optional[Postgresql::Pg_password_encryption]]`
4771+
Data type: `Optional[Optional[Enum["md5", "scram-sha-256"]]]`
47724772

47734773
Set type for password hash
47744774

@@ -4889,7 +4889,8 @@ Alias of `Hash[String[1], Postgresql::Pg_hba_rule]`
48894889

48904890
### <a name="Postgresql--Pg_password_encryption"></a>`Postgresql::Pg_password_encryption`
48914891

4892-
the supported password_encryption
4892+
Note that this Enum is also defined in:
4893+
lib/puppet/functions/postgresql/postgresql_password.rb
48934894

48944895
Alias of `Enum['md5', 'scram-sha-256']`
48954896

manifests/params.pp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@
8686
}
8787

8888
$service_reload = "systemctl reload ${service_name}"
89-
$service_status = pick($service_status, "systemctl status ${service_name}")
89+
$service_status = pick($service_status, "systemctl is-active --quiet ${service_name}")
9090

9191
$psql_path = pick($psql_path, "${bindir}/psql")
9292

@@ -130,7 +130,7 @@
130130
$confdir = pick($confdir, $datadir)
131131
$psql_path = pick($psql_path, "${bindir}/psql")
132132

133-
$service_status = pick($service_status, "systemctl status ${service_name}")
133+
$service_status = pick($service_status, "systemctl is-active --quiet ${service_name}")
134134
$service_reload = "systemctl reload ${service_name}"
135135
$python_package_name = pick($python_package_name, 'python-psycopg2')
136136
# Archlinux does not have a perl::DBD::Pg package
@@ -173,7 +173,7 @@
173173
$datadir = pick($datadir, "/var/lib/postgresql/${version}/main")
174174
$confdir = pick($confdir, "/etc/postgresql/${version}/main")
175175
$service_reload = "systemctl reload ${service_name}"
176-
$service_status = pick($service_status, "systemctl status ${service_name}")
176+
$service_status = pick($service_status, "systemctl is-active --quiet ${service_name}")
177177
$psql_path = pick($psql_path, '/usr/bin/psql')
178178
$postgresql_conf_mode = pick($postgresql_conf_mode, '0644')
179179
}
@@ -194,7 +194,7 @@
194194
$bindir = pick($bindir, "/usr/lib/postgresql-${version}/bin")
195195
$datadir = pick($datadir, "/var/lib/postgresql/${version}_data")
196196
$confdir = pick($confdir, "/etc/postgresql-${version}")
197-
$service_status = pick($service_status, "systemctl status ${service_name}")
197+
$service_status = pick($service_status, "systemctl is-active --quiet ${service_name}")
198198
$service_reload = "systemctl reload ${service_name}"
199199
$psql_path = pick($psql_path, "${bindir}/psql")
200200

@@ -267,7 +267,7 @@
267267
$bindir = pick($bindir, "/usr/lib/postgresql${version}/bin")
268268
$datadir = pick($datadir, '/var/lib/pgsql/data')
269269
$confdir = pick($confdir, $datadir)
270-
$service_status = pick($service_status, "systemctl status ${service_name}")
270+
$service_status = pick($service_status, "systemctl is-active --quiet ${service_name}")
271271
$service_reload = "systemctl reload ${service_name}"
272272
$psql_path = pick($psql_path, "${bindir}/psql")
273273

manifests/server.pp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@
130130
Boolean $service_restart_on_change = $postgresql::params::service_restart_on_change,
131131
Optional[String[1]] $service_provider = $postgresql::params::service_provider,
132132
String[1] $service_reload = $postgresql::params::service_reload,
133-
Optional[String[1]] $service_status = $postgresql::params::service_status,
133+
Optional[Variant[Array[String[1]],String[1]]] $service_status = $postgresql::params::service_status,
134134
String[1] $default_database = $postgresql::params::default_database,
135135
Hash $default_connect_settings = $postgresql::globals::default_connect_settings,
136136
Optional[Variant[String[1], Array[String[1]]]] $listen_addresses = $postgresql::params::listen_addresses,

metadata.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "puppetlabs-postgresql",
3-
"version": "10.6.0",
3+
"version": "10.6.1",
44
"author": "puppetlabs",
55
"summary": "Offers support for basic management of PostgreSQL databases.",
66
"license": "Apache-2.0",

spec/acceptance/server_instance_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ class { 'postgresql::server':
4646
},
4747
service_settings => {
4848
'service_name' => 'postgresql@13-test1',
49-
'service_status' => 'systemctl status postgresql@13-test1.service',
49+
'service_status' => 'systemctl is-active --quiet postgresql@13-test1.service',
5050
'service_ensure' => 'running',
5151
'service_enable' => true,
5252
},

spec/classes/server/service_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,5 +10,5 @@
1010
end
1111

1212
it { is_expected.to contain_class('postgresql::server::service') }
13-
it { is_expected.to contain_service('postgresqld_instance_main').with_name('postgresql').with_status('systemctl status postgresql') }
13+
it { is_expected.to contain_service('postgresqld_instance_main').with_name('postgresql').with_status('systemctl is-active --quiet postgresql') }
1414
end

spec/defines/server_instance_spec.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ class { 'postgresql::server':
4242
'port' => 5433,
4343
'pg_hba_conf_defaults' => false },
4444
'service_settings': { 'service_name' => 'postgresql@13-test1',
45-
'service_status' => 'systemctl status postgresql@13-test1.service',
45+
'service_status' => 'systemctl is-active --quiet postgresql@13-test1.service',
4646
'service_ensure' => 'running',
4747
'service_enable' => true },
4848
'initdb_settings': { 'auth_local' => 'peer',
@@ -120,7 +120,7 @@ class { 'postgresql::server':
120120
it { is_expected.to contain_postgresql__server_instance('test1') }
121121
it { is_expected.to contain_user('ins_test1') }
122122
it { is_expected.to contain_group('ins_test1') }
123-
it { is_expected.to contain_service('postgresqld_instance_test1').with_name('postgresql@13-test1').with_status('systemctl status postgresql@13-test1.service') }
123+
it { is_expected.to contain_service('postgresqld_instance_test1').with_name('postgresql@13-test1').with_status('systemctl is-active --quiet postgresql@13-test1.service') }
124124
it { is_expected.to contain_systemd__dropin_file('postgresql@13-test1.conf') }
125125
it { is_expected.to contain_postgresql_conn_validator('validate_service_is_running_instance_test1') }
126126
it { is_expected.to contain_postgresql_conf('port_for_instance_test1') }

0 commit comments

Comments
 (0)