You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(#469) Upgrade: Assign correct environment to node groups (#635)
* (#469) Upgrade: Assign production environment to node groups
This makes the environment for node groups configureable. The default is
'production'. This is also the default in the node_group resource type:
https://github.com/puppetlabs/puppetlabs-node_manager/blob/main/lib/puppet/type/node_group.rb#L124
We could also default to `undef` in PEADM and rely on the node_manage
module, but explicitly setting `production` seems to be safer.
This is related to
#469 and makes the
environment configureable during upgrades.
Co-authored-by: David Mallon <[email protected]>
* (#469) Upgrade: Assign correct environment to node groups
This checks if a user configured a environment in pe.conf. If that's the
case, it will be used for the PEADM-specific node groups. Otherwise we
fall back to production.
This fixes a timing issue discovered in #469. In situations where the PE
infra isn't running in production, we cannot assume that a production
environment exists. And a node group can only reference classes from the
environment the node group belongs to.
---------
Co-authored-by: David Mallon <[email protected]>
Note: internal tickets exist for the 2 CI failures, we will merge past them for now
*[`peadm::generate_pe_conf`](#peadm--generate_pe_conf): Generate a pe.conf file in JSON format
33
+
*[`peadm::get_node_group_environment`](#peadm--get_node_group_environment): check if a custom PE environment is set in pe.conf
33
34
*[`peadm::get_pe_conf`](#peadm--get_pe_conf)
34
35
*[`peadm::get_targets`](#peadm--get_targets): Accept undef or a SingleTargetSpec, and return an Array[Target, 1, 0]. This differs from get_target() in that: - It returns an Array[Target
fail("pe_install::install::classification::pe_node_group_environment and puppet_enterprise::master::recover_configuration::pe_environment need to be set to the same value, not '${pe_install}' and '${puppet_enterprise}'")
0 commit comments