From f0fa975d8ace31004298430f628fc53d04e2b5be Mon Sep 17 00:00:00 2001 From: Tim Meusel Date: Tue, 29 Aug 2023 12:06:43 +0200 Subject: [PATCH] Revert "puppetlabs/stdlib: Require 9.x" --- manifests/backup/pg_dump.pp | 6 +++--- manifests/server/extension.pp | 2 +- manifests/server/instance/config.pp | 2 +- manifests/server/instance/passwd.pp | 4 ++-- metadata.json | 2 +- 5 files changed, 8 insertions(+), 8 deletions(-) diff --git a/manifests/backup/pg_dump.pp b/manifests/backup/pg_dump.pp index 64ac5cfb4f..e46b45c2e4 100644 --- a/manifests/backup/pg_dump.pp +++ b/manifests/backup/pg_dump.pp @@ -68,13 +68,13 @@ ) { # Install required packages if $package_name { - stdlib::ensure_packages($package_name) + ensure_packages($package_name) } if $install_cron { if $facts['os']['family'] == 'RedHat' { - stdlib::ensure_packages('cronie') + ensure_packages('cronie') } elsif $facts['os']['family'] != 'FreeBSD' { - stdlib::ensure_packages('cron') + ensure_packages('cron') } } diff --git a/manifests/server/extension.pp b/manifests/server/extension.pp index c64eb11da7..6063329003 100644 --- a/manifests/server/extension.pp +++ b/manifests/server/extension.pp @@ -137,7 +137,7 @@ default => $package_ensure, } - stdlib::ensure_packages($package_name, { + ensure_packages($package_name, { ensure => $_package_ensure, tag => 'puppetlabs-postgresql', }) diff --git a/manifests/server/instance/config.pp b/manifests/server/instance/config.pp index 55e55d85ef..7b8e08b2a9 100644 --- a/manifests/server/instance/config.pp +++ b/manifests/server/instance/config.pp @@ -189,7 +189,7 @@ } } - stdlib::ensure_packages([$package_name]) + ensure_packages([$package_name]) $exec_command = ['/usr/sbin/semanage', 'port', '-a', '-t', 'postgresql_port_t', '-p', 'tcp', $port] $exec_unless = "/usr/sbin/semanage port -l | grep -qw ${port}" diff --git a/manifests/server/instance/passwd.pp b/manifests/server/instance/passwd.pp index 97d4a2b01c..85ee0ce754 100644 --- a/manifests/server/instance/passwd.pp +++ b/manifests/server/instance/passwd.pp @@ -34,7 +34,7 @@ # psql will default to connecting as $user if you don't specify name $_datbase_user_same = $database == $user $_dboption = $_datbase_user_same ? { - false => " --dbname ${stdlib::shell_escape($database)}", + false => " --dbname ${shell_escape($database)}", default => '' } @@ -44,7 +44,7 @@ # without specifying a password ('ident' or 'trust' security). This is # the default for pg_hba.conf. $escaped = postgresql::postgresql_escape($real_postgres_password) - $exec_command = "${stdlib::shell_escape($psql_path)}${_dboption} -c \"ALTER ROLE \\\"${stdlib::shell_escape($user)}\\\" PASSWORD \${NEWPASSWD_ESCAPED}\"" # lint:ignore:140chars + $exec_command = "${shell_escape($psql_path)}${_dboption} -c \"ALTER ROLE \\\"${shell_escape($user)}\\\" PASSWORD \${NEWPASSWD_ESCAPED}\"" # lint:ignore:140chars exec { 'set_postgres_postgrespw': # This command works w/no password because we run it as postgres system # user diff --git a/metadata.json b/metadata.json index 2443217f39..aae032a220 100644 --- a/metadata.json +++ b/metadata.json @@ -10,7 +10,7 @@ "dependencies": [ { "name": "puppetlabs/stdlib", - "version_requirement": ">= 9.0.0 < 10.0.0" + "version_requirement": ">= 5.2.0 < 10.0.0" }, { "name": "puppetlabs/apt",