Uploaded image for project: 'Modules'
  1. Modules
  2. MODULES-8665

puppet_agent: missing dependency on puppetlabs-facts for the install task

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Normal
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: puppet_agent
    • Labels:
      None
    • Template:
      MODULES Bug Template
    • Team:
      Night's Watch
    • Story Points:
      2
    • Sprint:
      Platform OS Kanban, Skeletor Kanban, PR - 2019-06-25, PR - 2019-07-10, PR - 2019-07-23
    • Method Found:
      Needs Assessment
    • Release Notes:
      Not Needed
    • QA Risk Assessment:
      Needs Assessment

      Description

      Basic Info
      Module Version: 2.0.1
      Puppet Version: PE 2019.0.2 (Puppet 6.0.5)
      OS Name/Version: CentOS 7

      The puppetlabs-puppet_agent module provides a puppet_agent::install task. The metadata for this task specifies some files that are provided by the puppetlabs-facts module. However, puppetlabs-facts is not listed as a dependency in the metadata.json file for puppetlabs-puppet_agent and thus is not installed as part of dependency resolution.

      Reproduction case

      • Install PE 2019.0.2 on CentOS 7
      • Make sure PE bits have been added to the PATH: source /etc/profile.d/puppet-agent.sh
      • Get a RBAC token for the admin user: puppet access login --username admin --lifetime 0
      • Install the puppetlabs-puppet_agent module: puppet module install puppetlabs-puppet_agent -v 2.0.1
      • Run: puppet task show puppet_agent::install

      Result

      The task show command fails because files provided by the puppetlabs-facts module are missing:

      [root@nc7shh0ylntr902 puppet-enterprise-2019.0.2-el-7-x86_64]# puppet module install puppetlabs-puppet_agent -v 2.0.1
      Notice: Preparing to install into /etc/puppetlabs/code/environments/production/modules ...
      Notice: Downloading from https://forgeapi.puppet.com ...
      Notice: Installing -- do not interrupt ...
      /etc/puppetlabs/code/environments/production/modules
      └─┬ puppetlabs-puppet_agent (v2.0.1)
        ├── puppetlabs-apt (v6.3.0)
        ├─┬ puppetlabs-inifile (v2.5.0)
        │ └── puppetlabs-translate (v1.2.0)
        └── puppetlabs-stdlib (v5.2.0)
       
      [root@nc7shh0ylntr902 puppet-enterprise-2019.0.2-el-7-x86_64]# puppet task show puppet_agent::install
      puppetlabs.orchestrator/invalid-task: Could not find module facts containing task file bash.sh
      

      Desired result

      The task show command succeeds:

      [root@nc7shh0ylntr902 puppet-enterprise-2019.0.2-el-7-x86_64]# puppet module install puppetlabs-facts
      Notice: Preparing to install into /etc/puppetlabs/code/environments/production/modules ...
      Notice: Downloading from https://forgeapi.puppet.com ...
      Notice: Installing -- do not interrupt ...
      /etc/puppetlabs/code/environments/production/modules
      └── puppetlabs-facts (v0.5.0)
       
      [root@nc7shh0ylntr902 puppet-enterprise-2019.0.2-el-7-x86_64]# puppet task show puppet_agent::install
       
      puppet_agent::install - Install the Puppet agent package
       
      USAGE:
      $ puppet task run puppet_agent::install [collection=<value>] [version=<value>] <[--nodes, -n <node-names>] | [--query, -q <'query'>]>
       
      PARAMETERS:
      - collection : Optional[Enum[puppet5, puppet6, puppet]]
          The Puppet collection to install from (defaults to puppet, which maps to the latest collection released)
      - version : Optional[String]
          The version of puppet-agent to install
      

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              oana.tanasoiu Oana Tanasoiu
              Reporter:
              chuck Charlie Sharpsteen
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Zendesk Support