Hi Arnau,

On 10 Nov 2015, at 14:23, Arnau <listsar...@gmail.com> wrote:

> 
> 
> 2015-11-10 14:39 GMT+01:00 Martin Alfke <tux...@gmail.com>:
> Hi Arnau
> Hi Martin,
>  
> Are your hiera data generic or specific to environments?
> 
> specific to hiera.
>  
> > …
> 
> > * Hiera works and returns the expected values:
> > #  hiera -c /etc/puppet/hiera.yaml -d  classes environment=basic_conf 
> > clientcert=XX
> 
> Here you make use of the ::environment.
> 
> Yes, because the default environment is not "basic_conf" .
> 
>  
> > My kickstart posinstall section runs puppet like:
> > puppet agent --test --tags=kickstart::bootstrap --report --pluginsync 
> > --no-noop
> 
> Here you do not specify the environment.
> 
> I've tried to run the puppet command + --environment=basic_conf inside the 
> kickstart process and it still gives me the error. I should have pasted the 
> complete command and not this one. Sorry.
> 
>  
> The reason why I specify the environment is becasue the default env in the 
> puppet master is not basic_conf. The node env  (AND ONLY NODE ENV) is defined 
> in foreman. (yes, maybe I should have talked about foreman before, but, as 
> the same command with/without environment fails, I did not consider that 
> foreman was interefering with my current issue).

I see two possible entry points for your problem:

1. environment specific hiera data
according to your hiera.yaml file you have hieradata per environment.
can you please cross check that the nagios::client::selinux key is set to false 
in all environment default.yaml files.

2. foreman providing data to modules.
check whether you set the selinux parameter for the nagios::client class in 
foreman based upon environments.


> 
>  
> Can you provide the content and location of your hiera.yaml file?
> 
>  # cat /etc/puppet/hiera.yaml
> ---
> :backend:
>   - yaml
> :hierarchy:
>   - "%{environment}/hieradb/global"
>   - "%{environment}/hieradb/cert/%{clientcert}"
>   - "%{environment}/hieradb/net/%{netlocation}"
>   - "%{environment}/hieradb/location/%{location}"
>   - "%{environment}/hieradb/env/%{environment}"
>   - "%{environment}/hieradb/dist/%{operatingsystem}/%{operatingsystemrelease}"
>   - 
> "%{environment}/hieradb/dist/%{operatingsystem}/%{operatingsystemmajrelease}"
>   - "%{environment}/hieradb/dist/%{operatingsystem}"
>   - "%{environment}/hieradb/dist/%{lsbdistid}/%{lsbdistrelease}"
>   - "%{environment}/hieradb/dist/%{lsbdistid}/%{lsbmajdistrelease}"
>   - "%{environment}/hieradb/dist/%{lsbdistid}"
>   - "%{environment}/hieradb/defaults"
> 
> :yaml:
>   :datadir: "/var/lib/puppet-deploy/XX-environments"
> 
> 
> 
> 
> Best,
> Martin
>  
> Cheers,
> Arnau
> 
> -- 
> 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 puppet-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/puppet-users/CAM69jx-JRhRtHhrSo92nW%3DgkQE4Sw7G1RVhnvh-JOjx8%2BX6axA%40mail.gmail.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/C3112600-AAB0-4E9F-8185-69171373D824%40gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to