RE: [Puppet Users] hiera query yaml parameters

2013-02-03 Thread Steven Nemetz
You can read the hash directly, create_resource is not needed (may or may not be desired) $user_defs = hiera('os_users') will give you the full hash What I tend to do for this type of data structure is: $user_defs = hiera('os_users') $user_keys = keys($user_defs) if is_array($user_keys) { pr

Re: [Puppet Users] help with define

2013-02-03 Thread Peter Brown
Hi, I am reasonably sure using a - in a variable name doesn't work or does strange things. I would suggest trying naming the ssh_authorized_key resource for the git key to "${title}_git" like so ssh_authorized_key { ${title}_git: ensure => 'present', u

Re: [Puppet Users] storeconfigs and exported resources?

2013-02-03 Thread Jakov Sosic
On 02/03/2013 10:19 PM, Ken Barber wrote: Also your routes.yaml doesn't match the documentation I gave you either, nor should you be setting thin_storeconfigs any more as stated in another section. Yeah, but if I remove the section for catalog, I don't get "replacing catalogs" in puppetdb log.

Re: [Puppet Users] storeconfigs and exported resources?

2013-02-03 Thread Jakov Sosic
On 02/03/2013 10:11 PM, Ken Barber wrote: You can see that the section is called [master] not [puppetmasterd]. This needs to be changed, and then you'll need to restart your puppetmaster. Damn.. I'm really ashamed now :-/ -- Jakov Sosic www.srce.unizg.hr -- You received this message bec

Re: [Puppet Users] hiera query yaml parameters

2013-02-03 Thread Dan White
Could you show your solution, please ? I would like to see how you did it. On Feb 3, 2013, at 6:46 PM, roadtest wrote: > I figure out the solution. > > Using the create_resource to convert YAML to a hash array, then I can query > retrieve every individual value. If there is better way, feel

[Puppet Users] Re: hiera query yaml parameters

2013-02-03 Thread roadtest
I figure out the solution. Using the create_resource to convert YAML to a hash array, then I can query retrieve every individual value. If there is better way, feel free to share with group. carl On Saturday, February 2, 2013 3:25:33 PM UTC-5, roadtest wrote: > > Hello, > > I have a yaml dat

Re: [Puppet Users] storeconfigs and exported resources?

2013-02-03 Thread Ken Barber
Also your routes.yaml doesn't match the documentation I gave you either, nor should you be setting thin_storeconfigs any more as stated in another section. You probably want to take a fresh top to bottom look through the documentation, like I said its fairly precise and you shouldn't go stray if y

Re: [Puppet Users] storeconfigs and exported resources?

2013-02-03 Thread Ken Barber
> I followed the howto, but exported resources just don't get applied on > agents... The documentation is fairly precise, looking at your configuration snippet: > # cat /etc/puppet/puppet.conf > [main] > logdir = /var/log/puppet > rundir = /var/run/puppet > ssldir = $vardir/ssl >

Re: [Puppet Users] Re: Another "function does not return a value" problem

2013-02-03 Thread R.I.Pienaar
- Original Message - > From: "Andriy Yurchuk" > To: puppet-users@googlegroups.com > Sent: Sunday, February 3, 2013 9:28:58 PM > Subject: [Puppet Users] Re: Another "function does not return a value" problem > > For some unknown reason it works after enabling PuppetDB. I guess you resta

[Puppet Users] Re: Another "function does not return a value" problem

2013-02-03 Thread Andriy Yurchuk
For some unknown reason it works after enabling PuppetDB. On Sunday, February 3, 2013 8:26:18 PM UTC+2, Andriy Yurchuk wrote: > > Here's the function: > > module Puppet::Parser::Functions > newfunction(:fact_to_array, :type => :rvalue) do |args| > args[0].split(',') > end > end > > Here's

Re: [Puppet Users] storeconfigs and exported resources?

2013-02-03 Thread Jakov Sosic
On 02/02/2013 12:31 PM, Ken Barber wrote: > Here is the documentation for wiring up the puppetmaster to puppetdb: > > http://docs.puppetlabs.com/puppetdb/1.1/connect_puppet_master.html > > Make sure you follow all of these steps and see how you go. Also > remember to restart your puppetmaster :-)

[Puppet Users] Another "function does not return a value" problem

2013-02-03 Thread Andriy Yurchuk
Here's the function: module Puppet::Parser::Functions newfunction(:fact_to_array, :type => :rvalue) do |args| args[0].split(',') end end Here's the class I'm trying to use it in: class oms::all_config { file { '/var/lib/oms/config': source => 'puppet:///deployment/deployment',

[Puppet Users] Re: Resource ordering problem...

2013-02-03 Thread Gavin Williams
After all that, it looks like the function was doing exactly what it was designed to... Filtering out irrelevant data... However feeding it incorrect filters meant that it was filtering everything... Doh... Cheers Gavin On Thursday, 31 January 2013 22:37:30 UTC, jcbollinger wrote: > > > > O