The problem was that I thought github.com/puppetlabs/hiera was the hiera
puppet module.
It worked after I copied the correct puppet module
github.com/puppetlabs/hiera-puppet to the modules folder.
On Wednesday, April 4, 2012 5:26:45 PM UTC+2, Andreas Paul wrote:
>
> Hi there,
>
> for some reason I can't use hiera functions in my manifests.
> Here are the relevant config files:
>
> cat /etc/puppet/hiera.yaml
> :hierarchy:
> - %{environment}
> - common
> :backends:
> - yaml
> - puppet
> :yaml:
> :datadir: '/etc/puppet/environments/%{environment}/hieradata'
> :puppet:
> :datasource: data
>
>
> cat environments/dev/hieradata/dev.yaml
> ---
> workers : - '10.125.127.88'
>
> cat environments/dev/modules/intra3/manifests/wsp.pp
> class intra3::wsp {
>
> #$workers = [ '12.3.4.5' ]
> #$workers = $intra3::data::workers
> $workers = hiera('workers')
>
> wsp::cfg { "tc6_foobar":
> remove => false,
> vhostname => 'test-foobar',
> worker => $workers,
> portrange => 121,
> prodlevel => 7,
> wwwdir => '/www/foobar.enbw.net',
> }
>
> pluginsync is enabled on master and client.
> The client picks up changes in the hiera module /lib:
>
> touch dev/modules/hiera/lib/bla.rb
>
> results in:
>
> notice: Ignoring --listen on onetime run
> info: Retrieving plugin
> notice: /File[/var/lib/puppet/lib/bla.rb]/ensure: defined content as
> '{md5}d41d8cd98f00b204e9800998ecf8427e'
> info: Loading downloaded plugin /var/lib/puppet/lib/bla.rb
> err: Could not retrieve catalog from remote server: Error 400 on SERVER:
> Unknown function hiera at
> /etc/puppet/environments/dev/modules/intra3/manifests/wsp.pp:5 on node
>
> puppet-2.7.12
>
> gem list hiera
> hiera (0.3.0)
> hiera-puppet (0.3.0)
>
>
> Any ideas?
>
On Wednesday, April 4, 2012 5:26:45 PM UTC+2, Andreas Paul wrote:
>
> Hi there,
>
> for some reason I can't use hiera functions in my manifests.
> Here are the relevant config files:
>
> cat /etc/puppet/hiera.yaml
> :hierarchy:
> - %{environment}
> - common
> :backends:
> - yaml
> - puppet
> :yaml:
> :datadir: '/etc/puppet/environments/%{environment}/hieradata'
> :puppet:
> :datasource: data
>
>
> cat environments/dev/hieradata/dev.yaml
> ---
> workers : - '10.125.127.88'
>
> cat environments/dev/modules/intra3/manifests/wsp.pp
> class intra3::wsp {
>
> #$workers = [ '12.3.4.5' ]
> #$workers = $intra3::data::workers
> $workers = hiera('workers')
>
> wsp::cfg { "tc6_foobar":
> remove => false,
> vhostname => 'test-foobar',
> worker => $workers,
> portrange => 121,
> prodlevel => 7,
> wwwdir => '/www/foobar.enbw.net',
> }
>
> pluginsync is enabled on master and client.
> The client picks up changes in the hiera module /lib:
>
> touch dev/modules/hiera/lib/bla.rb
>
> results in:
>
> notice: Ignoring --listen on onetime run
> info: Retrieving plugin
> notice: /File[/var/lib/puppet/lib/bla.rb]/ensure: defined content as
> '{md5}d41d8cd98f00b204e9800998ecf8427e'
> info: Loading downloaded plugin /var/lib/puppet/lib/bla.rb
> err: Could not retrieve catalog from remote server: Error 400 on SERVER:
> Unknown function hiera at
> /etc/puppet/environments/dev/modules/intra3/manifests/wsp.pp:5 on node
>
> puppet-2.7.12
>
> gem list hiera
> hiera (0.3.0)
> hiera-puppet (0.3.0)
>
>
> Any ideas?
>
--
You received this message because you are subscribed to the Google Groups
"Puppet Users" group.
To view this discussion on the web visit
https://groups.google.com/d/msg/puppet-users/-/UhbbRUsqqLgJ.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/puppet-users?hl=en.