8000 New feature: Show data in modules · Issue #331 · betadots/hdm · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
New feature: Show data in modules #331
Closed
@tuxmea

Description

@tuxmea

Discussed in #243

Originally posted by tuxmea December 22, 2023

Request

As a Puppet admin I want to be able to see the module data in case that I select a key with a module name

Solution

Within HDM -> environments -> node -> Key

Check if the selected key first part of the name is a module name by:

  • reading the environment.conf modulepath setting (use modules as default, multiple entries are separated by colon :, can also be absolute path)
    • Example:
      modulepath = site-modules:modules:/etc/puppetlabs/puppet/modules:../global
      
    • Default:
      modulepath = modules:$basemodulepath
      
      Basemodulepath: Puppet.settings('basemodulepath')
      Default:
      basemodulepath = /etc/puppetlabs/code/modules:/opt/puppetlabs/puppet/modules
      
  • parse the modulepath directories in order for a directory with the same name
  • if the directory exists
    • check for hiera.yaml inside the directory
    • if the hiera.yaml file exists
      • show the module button
    • if not
      • dont show the module button
  • if not
    • dont show the module button

If module data exist, a button module will show up next to the key.

Now HDM switches into module data view.
There should be a button environment which leads back to the environment data (ideally the one where we switched to module data view).

Within the key list, only module data are shown.
The hiera data directory/file structured is build in the same way as we do it now with environment data.
When selecting a key, one sees the same view as in environment data.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

    0