XMLWordPrintable

Details

    • Task
    • Status: Closed
    • Normal
    • Resolution: Incomplete
    • HI 3.2.0
    • None
    • UX
    • CentOS Linux release 7.2.1511 (Core)
      Puppet 4.5.3 (2016.2.1)strong text
      Hiera 3.2.0

    Description

      I have a working puppet 2016.2.1 using code manager (r10k) and environments (dev, staging, prod). This is working great. I than started to utilize hiera. When setting the hiera.yaml (as shown below). I'm getting the error "Cannot find datafile /etc/puppetlabs/code/environments*//*hieradata/common.yaml, skipping"

      #################################
      ---
      :backends:
        - yaml
       
      :hierarchy:
        - "nodes/%{::trusted.certname}"
        - "%{environment}"
        - "puppet_role/%{puppet_role}"  
        - common
       
      :yaml:
      :datadir: "/etc/puppetlabs/code/environments/%{::environment}/hieradata"
      #############################################################
      

      I notice the double backslash which is a problem. If I replace the environment variable with an actual environment name (e.g. :datadir: "/etc/puppetlabs/code/environments/development/hieradata") and run hiera --debug i get back results. Has anyone run into this?

      Attachments

        Activity

          People

            jenny Jenny Mahmoudi
            paultath81 Paul T
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Zendesk Support