Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(MODULES-7480) Set default collection in params.pp using PE version #301

Merged
merged 1 commit into from Jul 25, 2018

Conversation

ekinanp
Copy link
Contributor

@ekinanp ekinanp commented Jul 17, 2018

Previously, we'd hardcode the default collection to PC1 in the init.pp
manifest for both PE and non-PE environments. This has a couple of
issues:

  • It's impossible to make decisions based on the collection in PE
    updates, so as we change package names and paths things get hairy.
  • This is already seen with the fedora "f" in Puppet 6, and will soon be
    seen with the AIX unibuild
  • In Irving.3, we switched to correctly shipping "puppet5" repos instead
    of "PC1". This means the module now MUST be aware of how PE versions
    map to collections.

This commit calculates the collection default in params.pp using the
following logic

  • If we are in a non-PE environment OR our pe_version < 2018.1.3, use PC1
  • Else if 2018.1.3 <= pe_version < 2018.2, use puppet5
  • Else use puppet6 (pe_version >= 2018.2 here)

@ekinanp ekinanp changed the base branch from master to 1.x July 17, 2018 20:40
@ekinanp ekinanp force-pushed the MODULES-7480 branch 6 times, most recently from 629fa10 to 7c173bc Compare July 17, 2018 20:50
@ekinanp ekinanp changed the title (MODULES-7480) Set the default collection programmatically in params.pp (MODULES-7480) Set default collection in params.pp using PE version Jul 17, 2018
@ekinanp ekinanp force-pushed the MODULES-7480 branch 2 times, most recently from a3b441e to d72cb86 Compare July 17, 2018 21:37
Previously, we'd hardcode the default collection to PC1 in the init.pp
manifest for both PE and non-PE environments. This has a couple of
issues:

* It's impossible to make decisions based on the collection in PE
  updates, so as we change package names and paths things get hairy.
* This is already seen with the fedora "f" in Puppet 6, and will soon be
  seen with the AIX unibuild
* In Irving.3, we switched to correctly shipping "puppet5" repos instead
  of "PC1". This means the module now MUST be aware of how PE versions
  map to collections.

This commit calculates the collection default in params.pp using the
following logic

* If we are in a non-PE environment OR our pe_version < 2018.1.3, use PC1
* Else if 2018.1.3 <= pe_version < 2018.2, use puppet5
* Else use puppet6 (pe_version >= 2018.2 here)
@puppetcla
Copy link

CLA signed by all contributors.

@ekinanp ekinanp requested a review from branan July 23, 2018 17:24
@smcclellan smcclellan merged commit 081196b into puppetlabs:1.x Jul 25, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants