Project

General

Profile

Actions

Bug #7517

closed

Puppet class parameter not removed from environment after an import

Added by Anthony Lapenna over 9 years ago. Updated almost 6 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
Puppet integration
Target version:
Difficulty:
Triaged:
Fixed in Releases:
Found in Releases:

Description

Here is a description of my problem:

I've a Puppet class class_A and 2 environments env_A and env_B.

Here is a description of my class present in env_A AND env_B:

class class_A ($param_A) {
...
}

I want to upgrade the definition of the class in env_B only with the following:

class class_A ($param_B, $param_C) {
...
}

So I upload my new module definition to the puppetmaster and trigger an import on Foreman.

Now, if I check in Configure > Puppet classes > class_A > Smartclass parameters I can see that:

  • My new parameters param_B and param_C are present for the environment env_B only
  • The parameter param_A is still present in env_B

It is annoying because if I try to a Puppet run on a host from env_B, it can't run saying unable to locate parameter param_A.

I had to delete the param_A from my Puppet classe, which also removed the parameter from the environment env_A causing error in the puppet runs for that environment.


Related issues 4 (1 open3 closed)

Related to Foreman - Bug #2369: Paramaterized classes persist through import after parameters have been removedNew04/02/2013Actions
Has duplicate Foreman - Bug #10377: Re-importing an environment where class parameters were removed does not remove those parameters in Foreman's class signaturesDuplicate05/05/2015Actions
Has duplicate Foreman - Bug #12579: Class Parameters are not separated for different environmentsDuplicate11/24/2015Actions
Has duplicate Foreman - Bug #3086: Import puppet classes fails to update classesDuplicate09/13/2013Actions
Actions #1

Updated by Dominic Cleal over 9 years ago

  • Category set to Puppet integration
Actions #2

Updated by Dominic Cleal over 9 years ago

  • Related to Bug #2369: Paramaterized classes persist through import after parameters have been removed added
Actions #3

Updated by Dominic Cleal over 8 years ago

  • Has duplicate Bug #10377: Re-importing an environment where class parameters were removed does not remove those parameters in Foreman's class signatures added
Actions #4

Updated by Dominic Cleal over 8 years ago

  • Has duplicate Bug #12579: Class Parameters are not separated for different environments added
Actions #5

Updated by Dominic Cleal over 8 years ago

  • Status changed from New to Assigned
  • Assignee set to Dominic Cleal

This happens when the parameter is overridden, Foreman won't remove it from any environment when the override flag is set. I suspect this is intended as a safety mechanism so that parameters with data attached aren't accidentally deleted, and/or possibly that early Puppet versions with parameterised class support didn't mind the extra parameters.

Actions #6

Updated by The Foreman Bot over 8 years ago

  • Status changed from Assigned to Ready For Testing
  • Pull request https://github.com/theforeman/foreman/pull/2932 added
Actions #7

Updated by Dominic Cleal over 8 years ago

  • Has duplicate Bug #3086: Import puppet classes fails to update classes added
Actions #8

Updated by Dominic Cleal over 8 years ago

  • Status changed from Ready For Testing to Closed
  • % Done changed from 0 to 100
Actions #9

Updated by Dominic Cleal over 8 years ago

  • translation missing: en.field_release set to 104
Actions

Also available in: Atom PDF