If you want to test a puppet patch on just one labs slave, you have to disable puppet on all the slaves (via salt), then cherry-pick onto the integration-puppetmaster, and re-enable puppet on one of the slaves. This sucks. There should be a better way to do this.
Description
Related Objects
- Mentioned Here
- T161675: Re-think puppet management for deployment-prep
Event Timeline
The use case fits what Puppet calls "environments" (which I think is where production for the default branch comes from as the default puppetmaster environment is called that). I'm unsure whether 3.4 supports all features (documentation is at http://docs.puppetlabs.com/puppet/3/reference/).
I suggest a parameter environments to role::puppet::self à la:
environments => {
'sandbox-legoktm' => ['instance1', 'instance2'],
'fix-T4711' => undef,
}This would create environments at /etc/puppet/environments/sandbox-legoktm and /etc/puppet/environments/fix-T4711, set up the cron jobs for git-sync-upstream accordingly and set the environment for instance1 and instance2 to sandbox-legoktm, with production for all others.
@scfc great teaser. I would like to know more about environments.
Is all that logic already in operations/puppet.git ?
What would be the content of /etc/puppet/environments/sandbox-legoktm , would it be an independent clone of puppet.git where one can cherry pick patches or is it something more complicated.
Unfortunately no :-). That was just a proposal how the different environments could be defined.
What would be the content of /etc/puppet/environments/sandbox-legoktm , would it be an independent clone of puppet.git where one can cherry pick patches or is it something more complicated.
Environments each have (at least) their own manifests and modules directories, so basically multiple clones of operations/puppet. Each could have different cherry-picks & Co.
(NB: Everything untested, based on https://docs.puppet.com/puppet/4.9/environments_suggestions.html & Co.)
There is a related task to add Puppet environments to Beta-Cluster-Infrastructure : T161675: Re-think puppet management for deployment-prep
The jobs now run in Docker containers and the hosts have a very straightforward puppet manifest. Since puppet changes are rare nowadays and have no impact to the test environments (which are in Docker), we don't really need to test puppet patches anymore.