Describe the Bug
While upgrading the module from 9.1.0 to 10.5.0 we ran into the issue of a dependency cycle, when setting a value for postgresql::globals::encoding.
Info: Applying configuration version '*****.puppetserver01-atm_10130-1e601b89123d47539e44cf03bd0dce23a8d9a166'
Error: Found 1 dependency cycle:
(Anchor[postgresql::server::service::begin::main] => Postgresql_psql[Set template1 encoding to UTF-8] => Postgresql::Server::Instance::Late_initdb[main] => Postgresql::Server::Instance::Initdb[main] => Postgresql_conf[port_for_instance_main] => Postgresql::Server::Instance::Service[main] => Anchor[postgresql::server::service::begin::main])
Expected Behavior
No dependency cycle.
Steps to Reproduce (hiera)
---
classes:
- postgresql::server
postgresql::globals::encoding: 'UTF-8'
Steps to Reproduce (docker)
docker run -it --rm ubuntu:22.04 bash
apt-get update
apt-get install -y wget
wget https://apt.puppetlabs.com/puppet-release-jammy.deb
dpkg -i puppet-release-jammy.deb
apt-get update
apt-get install -y puppet-agent
/opt/puppetlabs/bin/puppet module install puppetlabs-postgresql
/opt/puppetlabs/bin/puppet apply -e "
class { 'postgresql::globals': encoding => 'UTF-8', }
class { 'postgresql::server': }
"
Environment
- Module version 10.5.0
- Ubuntu 20.04, Ubuntu 22.04, Ubuntu 24.04
Additional Context
Removing the value will compile and apply successful.
Describe the Bug
While upgrading the module from 9.1.0 to 10.5.0 we ran into the issue of a dependency cycle, when setting a value for
postgresql::globals::encoding.Expected Behavior
No dependency cycle.
Steps to Reproduce (hiera)
Steps to Reproduce (docker)
Environment
Additional Context
Removing the value will compile and apply successful.