Re: [Puppet Users] Re: How to use variables in a puppet class

2014-07-25 Thread José Luis Ledesma
If you interpolate variable you have to use instead of '. So it should be source = puppet:///modules/repo/rhel-${::lsbdistrelease}_64.repo, Regards, El 25/07/2014 01:44, Vikas Kumar vikas...@gmail.com escribió: Hi CD, Just tried these too, but somehow puppet is not honoring any variables in

[Puppet Users] Re: Hiera - how to include all files inside a directory

2014-07-25 Thread Juan Moreno
Thanks Pete and John. Now we've got a puppet module that use a unique file in hiera, inside this file (associative hash), we've all the customers and the specific data from each one. This allow us to create Vhosts in Apache, creates specific tomcat webapps, set quotas in distributed file

Re: [Puppet Users] Re: How to use variables in a puppet class

2014-07-25 Thread Vikas Kumar
Hi Jose, I tried this, didn't worked for me :( '6': { file {'/etc/yum.repos.d/RHEL-6.4.repo': ensure = present, mode = '0644', owner = 'root', group = 'root', source = 'puppet:///modules/repo/rhel-${::lsbdistrelease}_64.repo', }

Re: [Puppet Users] Re: How to use variables in a puppet class

2014-07-25 Thread Johan De Wit
use double quotes in your source attribute : |source =puppet:///modules/repo/rhel-${::lsbdistrelease}_64.repo, | On 25/07/14 09:22, Vikas Kumar wrote: Hi Jose, I tried this, didn't worked for me :( | '6':{ file {'/etc/yum.repos.d/RHEL-6.4.repo': ensure=present, mode

Re: [Puppet Users] using a template, how do you create multiple files whose names come from an array?

2014-07-25 Thread Cristian Falcas
Feed the array to a define where you call the template. On Fri, Jul 25, 2014 at 3:08 AM, senorsmile senorsm...@gmail.com wrote: For example, I have an array like this: clusters = [ 'cluster1', 'cluster2', 'cluster3', 'cluster4', ] I then have a cluster.init.erb that looks

Re: [Puppet Users] Re: How to use variables in a puppet class

2014-07-25 Thread Vikas Kumar
Super Johan !! Thanks a ton. You made my day. Now, these statements are working fine. baseurl = http://192.168.1.100/centos/rhel-${::lsbdistrelease}_64.repo;, and source = puppet:///modules/repo/rhel-${::lsbdistrelease}_64.repo, Regards, Vikas On Friday, 25 July 2014 17:56:37 UTC+10,

Re: [Puppet Users] Re: Passing undef as argument to classes defines overrides default parameter

2014-07-25 Thread Cristian Falcas
thank you On Wed, Jul 23, 2014 at 11:59 PM, jcbollinger john.bollin...@stjude.org wrote: On Wednesday, July 23, 2014 7:32:15 AM UTC-5, Cristian Falcas wrote: Hello all, Regarding my question with automated data binding. Here is how we set this via the yaml backend:

Re: [Puppet Users] exported resources question

2014-07-25 Thread Cristian Falcas
Thank you. Best regards, Cristian Falcas On Wed, Jul 23, 2014 at 11:05 PM, Andy Parker a...@puppetlabs.com wrote: On Wed, Jul 23, 2014 at 7:02 AM, Cristian Falcas cristi.fal...@gmail.com wrote: Hello, When are the exported resources exported and by whom? Are they send by the agent at

[Puppet Users] Problem with Hiera deep merge

2014-07-25 Thread Antoine Cotten
Hi Puppet users, I've been using Hiera's deep merge feature on class parameters for months, however when I try to pair it with the create_resources function things get ugly. Situation: I want to deploy a set of Unix users on all my machines. They have standard rights by default and get access

Re: [Puppet Users] Re: How to group systems using Puppet and hiera?

2014-07-25 Thread Grant Street
That would be great. My first attempt didn't seem to work. Even some example output defining the roles etc, would be great from the script. I must be doing something wrong. Cheers On 25 Jul 2014 14:33, Atom Powers atom.pow...@gmail.com wrote: The ENC can pass on any variable you wish to define

[Puppet Users] Re: Problem with Hiera deep merge

2014-07-25 Thread Antoine Cotten
*Btw, please ignore the typo (missing parenthesis) in the manifest, trust me it's not here in the real manifest.* Funny fact I just discovered: if I move the $user parameter INSIDE the code of the class, and get rid of the class parameter (of course) it works just fine. So why would the

[Puppet Users] Re: Problem with Hiera deep merge

2014-07-25 Thread Antoine Cotten
I actually found the answer in another topic https://groups.google.com/forum/#!searchin/puppet-users/Puppet$203.1.1$2C$20hiera$20and$20parameter$20autoload/puppet-users/FezqytcHBeA/BC5xKG5e78cJ . I changed my variable name to $unixusers instead of $users and it started working. I suspect a

[Puppet Users] Re: Exported resouces, ceph

2014-07-25 Thread M. Piscaer
I think i hit the following bug: http://projects.puppetlabs.com/issues/5267 The describe workaround did not solve my problem. Also what i forgot to tell was that i'm using puppet 2.7.19 Is there a workaround for me? Kinds regards, Michiel Piscaer On 24-07-14 21:29, M. Piscaer wrote: Hi,

Re: [Puppet Users] using a template, how do you create multiple files whose names come from an array?

2014-07-25 Thread Yanis Guenane
On 07/24/2014 08:08 PM, senorsmile wrote: For example, I have an array like this: clusters = [ 'cluster1', 'cluster2', 'cluster3', 'cluster4', ] I then have a cluster.init.erb that looks soemthing like this: start on runlevel [2345] stop on runlevel [!2345]

[Puppet Users] Re: scheduling refresh event BEFORE dependent object

2014-07-25 Thread jcbollinger
On Thursday, July 24, 2014 10:42:34 AM UTC-5, Dimitris Stafylarakis wrote: Hi all, I have a question for the experts in the group: say there's an exec resource dependent on some other resource and refreshonly= true. As we know already, a change in the dependent resource will send a

Re: [Puppet Users] using a template, how do you create multiple files whose names come from an array?

2014-07-25 Thread senorsmile
So, I have this partially working. in /etc/puppet/manifests/nodes.pp I have (all entries truncated and scrubbed): node node_example { class { 'ganglia::install::gmetad': clusters= [ 'cluster1', 'cluster2', 'cluster3', 'cluster4', ] } and under

Re: [Puppet Users] using a template, how do you create multiple files whose names come from an array?

2014-07-25 Thread senorsmile
I have solved this using create_resources http://docs.puppetlabs.com/references/latest/function.html#createresources which converts the hash into arrays that a define can digest. On Friday, July 25, 2014 10:27:21 AM UTC-7, senorsmile wrote: So, I have this partially working. in

[Puppet Users]

2014-07-25 Thread Tim Dunphy
Hey all, I'm getting an annoying warning whenever I run the puppet cert command: [root@puppet:/etc/puppet] #puppet cert list Warning: Sections other than main, master, agent, user are deprecated in puppet.conf. Please use the directory environments feature to specify environments. (See

Re: [Puppet Users]

2014-07-25 Thread Dan White
Warning: Sections other than main, master, agent, user are deprecated in puppet.conf. [production] [production] is not main, master, agent, or user On Jul 25, 2014, at 8:59 PM, Tim Dunphy bluethu...@gmail.com wrote: Hey all, I'm getting an annoying warning whenever I run the puppet

Re: [Puppet Users]

2014-07-25 Thread Tim Dunphy
Warning: Sections other than main, master, agent, user are deprecated in puppet.conf. [production] [production] is not main, master, agent, or user Got it! Thanks. Tho funny. :) On Fri, Jul 25, 2014 at 9:47 PM, Dan White y...@comcast.net wrote: Warning: Sections other than main, master,

Re: [Puppet Users] using a template, how do you create multiple files whose names come from an array?

2014-07-25 Thread Cristian Falcas
I think you can solve like this also: % @clusters.each do |key,value| % cluster name is %=key % and cluster port is %= value % % end -% On Fri, Jul 25, 2014 at 8:56 PM, senorsmile senorsm...@gmail.com wrote: I have solved this using create_resources

Re: [Puppet Users] using a template, how do you create multiple files whose names come from an array?

2014-07-25 Thread senorsmile
Ah, I didn't know you could do that. Reading through the documentation can lead to one's mind melting. This may be preferable as create_resources messes up my resource ordering. Thanks! On Friday, July 25, 2014 8:40:27 PM UTC-7, Cristian Falcas wrote: I think you can solve like this

Re: [Puppet Users] using a template, how do you create multiple files whose names come from an array?

2014-07-25 Thread Cristian Falcas
Just be careful how you call the variables: puppet var is %= @name%, local var will be %= name % On Sat, Jul 26, 2014 at 6:42 AM, senorsmile senorsm...@gmail.com wrote: Ah, I didn't know you could do that. Reading through the documentation can lead to one's mind melting. This may be