Project

General

Profile

Actions

Bug #2369

open

Paramaterized classes persist through import after parameters have been removed

Added by Jeff Palmer over 11 years ago. Updated about 8 years ago.

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

Description

I recently tried a module from the puppet forge (for bacula)

The module included some paramaterized classes. When I importe the environment, the classes were imported correctly.

Upon reviewing the module, I decided I din't care for it, and decided to write my own.

The new module didn't use any paramaterized classes. However, even when re-importing the environment puppet would error out. It complained about things that were defined as paramaterized values.

The only way I was able to work around it was to move my module out of the puppet directory, import the env (where foreman cleaned up everything) then move my new module back and re-import the environment.

Steps to reproduce:
#1) Install a module with paramaterized classes
#2) Import environments
#3) Set a few of the paramaters (I set them globally. I assume it'd work at the hostgroup, domain, or host level as well)
#4) Remove the module with paramaterized classes
#5) Replace with a module using the same class names, but without them being paramaterized.
#6) Import environments
#7) Initiate a puppet run

I did not look at the hosts YAML output. I suspect that the resulting yaml file is still putting the paramaterized bits in play.


Related issues 2 (0 open2 closed)

Related to Foreman - Bug #7517: Puppet class parameter not removed from environment after an importClosedDominic Cleal09/18/2014Actions
Has duplicate Foreman - Bug #6859: Foreman not removing old class parametersDuplicate07/31/2014Actions
Actions #1

Updated by Dominic Cleal over 11 years ago

  • Subject changed from paramaterized classes can persist in odd instances to Paramaterized classes persist through import after parameters have been removed
  • Assignee deleted (Ohad Levy)
Actions #2

Updated by Dominic Cleal about 10 years ago

  • Has duplicate Bug #6859: Foreman not removing old class parameters added
Actions #3

Updated by Dominic Cleal about 10 years ago

  • Related to Bug #7517: Puppet class parameter not removed from environment after an import added
Actions #4

Updated by Jeff Sault about 10 years ago

Is there any plans to fix this bug?

Actions #5

Updated by Jeff Sault almost 10 years ago

This is turning into a big problem for us. With our deployments we tend to have different versions of the same class in different environments.

Whenever we remove a parameter from a new version of a class, puppet complains that an unknown parameter is being passed to the class.

Ive been working on implementing workarounds using the foreman API but its a nightmare...

- It seems its not possible to remove a smart class parameter from a class for a specific environment, its all or nothing, the parameter gets removed from all instances of the class, in all environments.

- If the class is removed from the environment then re-imported (as described above) then all the previously overridden parameters are orphaned. They show in the host/hostgroup parameters pages but the class field is empty. Theres no way that I can find to find these parameters via the API to re-associate them with the classes.

Are there any other workaround which I havent thought of? Or plans to fix the issue?

Actions #6

Updated by Dominic Cleal over 9 years ago

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

Updated by Dominic Cleal about 9 years ago

  • Related to Bug #12579: Class Parameters are not separated for different environments added
Actions #8

Updated by Dominic Cleal about 9 years ago

  • Related to deleted (Bug #10377: Re-importing an environment where class parameters were removed does not remove those parameters in Foreman's class signatures)
Actions #9

Updated by Dominic Cleal about 9 years ago

  • Related to deleted (Bug #12579: Class Parameters are not separated for different environments)
Actions #10

Updated by Chris Edester about 8 years ago

This issue seems related:
I can find no way to delete Smart class parameters.

After deleting all of my Puppet classes, all the orphaned Smart class parameters are left with no Puppet class association. Is there any way to purge the left over Smart class parameters? Shoudn't they be deleted with their respective Puppet classes?

Actions

Also available in: Atom PDF