You would need to have sac in your hiera.yaml hierarchy unless you are 
defining this somewhere in a variable?  Is that what nt_location is?  Also, 
if you changed hiera.yaml, you have to restart puppetserver.

On Monday, June 20, 2016 at 7:52:21 AM UTC-5, chris wrote:
>
> Given this /etc/puppetlabs/code/hiera.yaml
>
>
> ---
> :backends: 
>   - json
> :hierarchy: 
>   - "%{hostname}.%{nt_environment}.%{nt_location}"
>   - "%{nt_type}.%{nt_environment}.%{nt_location}"
>   - "%{nt_type}.%{nt_environment}"
>   - "%{nt_environment}.%{nt_location}"
>   - "%{nt_environment}"
>   - "%{nt_location}"
>   - world
>   - default
> :logger: console # debug
> :json:
>     :datadir: '/etc/puppetlabs/code/environments/%{::environment}/hieradata' 
> # this is the default anyway
>
> and there exists 
> /etc/puppetlabs/code/environments/prod/hieradata/sac.json, this cmd
>
>
> puppet lookup --debug icinga_servers --environment prod
>
>
> produces
>
>
> Debug: hiera(): Looking for data source puppetmaster.opsDebug: hiera(): 
> Looking for data source ops.sacDebug: hiera(): Looking for data source 
> opsDebug: hiera(): Looking for data source sacDebug: hiera(): Looking for 
> data source worldDebug: hiera(): Looking for data source default
>
> (& lots more of course).
>
>
> Why can't it find the 
> /etc/puppetlabs/code/environments/prod/hieradata/sac.json file which 
> contains the key I'm looking for ? 
> (Puppet server 2.4)
>
>
> Thanks
>
> Chris
>

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/e826ef72-f745-4c33-9117-0b686a282735%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to