Uploaded image for project: 'Puppet'
  1. Puppet
  2. PUP-7334

add a default hierarchy to module hiera.yaml

    XMLWordPrintable

    Details

    • Type: New Feature
    • Status: Closed
    • Priority: Normal
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: PUP 4.10.0
    • Component/s: Docs
    • Labels:
    • Template:
    • Epic Link:
    • Team:
      Puppet Developer Experience
    • Story Points:
      2
    • Sprint:
      PDE 2017-03-22, PDE 2017-04-05
    • Release Notes:
      New Feature
    • Release Notes Summary:
      Hide
      Hiera 5 now supports a {{default_hierarchy}} that can be used in a module's hiera.yaml. It works exactly like the normal hierarchy, but the values it binds to keys are only used if the regular {{hierarchy}} (across all layers) does not result in a value. Merge options for keys in the default hierarchy can only be specified in the default hierarchy's data.
      Show
      Hiera 5 now supports a {{default_hierarchy}} that can be used in a module's hiera.yaml. It works exactly like the normal hierarchy, but the values it binds to keys are only used if the regular {{hierarchy}} (across all layers) does not result in a value. Merge options for keys in the default hierarchy can only be specified in the default hierarchy's data.
    • QA Risk Assessment:
      No Action
    • QA Risk Assessment Reason:
      covered by unit tests

      Description

      When transitioning from a "params.pp" pattern it is of importance to be able to configure the data such that the lowest "default" level in a module does not result in values that are included in a deep merge. This would mimic how the params.pp works now (its values are never considered).

      The proposed feature is to add a separate hierarchy named default_hierarchy - it works exactly like the normal hierarchy, but the values it binds to keys are only used if the normal hierarchy entries in the same module, or any or the higher precedence layers (environment/global) does not result in a value. Within this default hierarchy the normal merging rules etc. apply.

      Note that defaults_hierarchy is not allowed in environment or global - as that would greatly complicate the semantics and handling of defaults.

        Attachments

          Activity

            People

            Assignee:
            Unassigned
            Reporter:
            henrik.lindberg Henrik Lindberg
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Zendesk Support