[Puppet Users] How to store bash command: output in a variable as array

2013-11-25 Thread sasikiran v
exec {'ls': command = ls, path = /usr/bin:/bin, provider = shell, } So the output of ls contains files/directories, these should be stored in a array for suppose $my_array and it should be used globally in the module. Can any one help me in this -- You received this

Re: [Puppet Users] How to store bash command: output in a variable as array

2013-11-25 Thread Johan De Wit
Hi, You should have a look at 'facts'. An exec is executed in the last phase of a puppet run. If you need information form a node, that you need in eg. templates, modules etc, you will have to use facts. Have a look at the last image on http://puppetlabs.com/puppet/what-is-puppet Writing

[Puppet Users] Re: Help with configuring Puppet Proxies using Apache

2013-11-25 Thread pdpinfo
Hi, I'm glad to hear good news, and congrats because the setup is a bit tricky. I noticed you enabled SSLProxyMachineCertificateFile. I think that now the next step would be to enable mandatory certificate checking on puppetmaster_host of remote_proxy_host certificate. I will try this

[Puppet Users] Re: how to exports facts from puppetdb

2013-11-25 Thread kaustubh chaudhari
Thanks Deepak, I will try that!!! On Thursday, November 21, 2013 10:53:20 PM UTC-5, kaustubh chaudhari wrote: Hi, How can i export all the facts for all the nodes from puppetdb in cvs/xls format. My objective is to us Business Object or some other tool for creating my infrastructure

[Puppet Users] mcp ping return no responses

2013-11-25 Thread Luca Gioppo
I'm trying to install mcollective on an environment for the first time and I'm having troubles: MC client (also the puppet master) activemq.xml !-- Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with

Re: [Puppet Users] mcp ping return no responses

2013-11-25 Thread R.I.Pienaar
- Original Message - From: Luca Gioppo lucagio...@gmail.com To: puppet-users@googlegroups.com Sent: Monday, November 25, 2013 12:06:22 PM Subject: [Puppet Users] mcp ping return no responses I'm trying to install mcollective on an environment for the first time and I'm having

[Puppet Users] Console UI - Add Class - params

2013-11-25 Thread Raj kumar V
Hi 1. I have a params class which holds some dynamic values at run time. But my parameters are populated in the UI when I add the class to a specific node. What are the steps or guidelines to have params autoloaded in the console with the specified variable name? 2. I have built the module

[Puppet Users] Re: Help with configuring Puppet Proxies using Apache

2013-11-25 Thread kschafer2598
Thanks - I turned it on for each vhost and it doesn't appear to cause any issue. From what you included about SSLVerify, does it mean that option is required for SSLVerifyClient to work properly? Karl On Monday, November 25, 2013 4:46:33 AM UTC-5, pdpinfo wrote: Hi, I'm glad to hear good

[Puppet Users] Re: Help with configuring Puppet Proxies using Apache

2013-11-25 Thread Ruth
Hi Karl, I tried to copy your setup but I still get SSL errors in my puppet clients. I am not sure about the certificates, did you use the same certificates on Puppet Master and RP ? I would be grateful if you could share the results of your work, Regards, Marcella Am Samstag, 23. November

Re: [Puppet Users] How to store bash command: output in a variable as array

2013-11-25 Thread Štěpán Cenek
Hi y'all, creating custom fact is great. If you need it just for testing, use generate. $arr = generate('/bin/ls') Btw: the difference between exec and generate is that generate is executed right on the beginning of Puppet run (so it will fail if it's using tool installed later by Puppet). You

Re: [Puppet Users] mcp ping return no responses

2013-11-25 Thread Luca Gioppo
Thanks that solved the problem. Il giorno lunedì 25 novembre 2013 13:12:54 UTC+1, R.I. Pienaar ha scritto: - Original Message - From: Luca Gioppo lucag...@gmail.com javascript: To: puppet...@googlegroups.com javascript: Sent: Monday, November 25, 2013 12:06:22 PM Subject:

[Puppet Users] Re: Help with configuring Puppet Proxies using Apache

2013-11-25 Thread kschafer2598
Hi There, Yes I did use the same certificates on both. I also used an alternate DNS name for the RP so I created the cert with an alt_dns_name: puppet cert generate remote_puppet_host --dns_alt_names remote_puppet_host_alt That cert and private_key gets copied from puppetmaster cert directory

[Puppet Users] Re: disabling puppet agent auto-runs on a host

2013-11-25 Thread jcbollinger
On Friday, November 22, 2013 1:43:01 PM UTC-6, Stuart Cracraft wrote: Hi, We do not want to have puppet changing things out from under us, then looking at a log file after-the-fact. We are okay with running puppet agent manually for the particular application we have chosen it for under

Re: [Puppet Users] How to store bash command: output in a variable as array

2013-11-25 Thread Paul Tötterman
Btw: the difference between exec and generate is that generate is executed right on the beginning of Puppet run No. The difference is that generate() is run on the master and exec on the agent: http://docs.puppetlabs.com/references/latest/function.html#generate Cheers, Paul -- You

Re: [Puppet Users] How to store bash command: output in a variable as array

2013-11-25 Thread Stepan Cenek
Sorry for confusion, I'm used to masterless Puppet... On Mon, Nov 25, 2013 at 4:03 PM, Paul Tötterman paul.totter...@gmail.com wrote: Btw: the difference between exec and generate is that generate is executed right on the beginning of Puppet run No. The difference is that generate() is run

[Puppet Users] Re: Unknown function

2013-11-25 Thread jcbollinger
On Friday, November 22, 2013 1:18:25 PM UTC-6, Stuart Cracraft wrote: So now my puppet agent is getting this error in messages: Date/Timestamp hostname[pid]: Must pass user to Class[abc::def] at /etc/puppet/manifests/templates.pp:2 on node hostname The templates looks like this:

[Puppet Users] Re: Permission denied - /usr/share/puppet-dashboard/public/javascripts/all.js

2013-11-25 Thread jcbollinger
On Friday, November 22, 2013 1:07:21 PM UTC-6, Mark Haney wrote: Yes, I know that error has been posted before. I also know why it occurs. Yet, getting the Dashboard working has become a nightmare. And for someone who wants to eval the entire Puppet package, this is really turning me

[Puppet Users] Re: init script status checks and puppet

2013-11-25 Thread jcbollinger
On Friday, November 22, 2013 4:23:30 PM UTC-6, David Ashby wrote: I've been experiencing some odd behavior with puppet and checking the status of running processes. Let me see if I can explain it: I have a very simple node.js socket server I'm attempting to puppetize. It is managed

Re: [Puppet Users] Puppet Dashboard with Passenger - 500 Internal Server Error (Mysql::Error: Can't create/write to file Errcode: 13)

2013-11-25 Thread Felix Frank
Hi, my guess would be that this error is handed through from MySQL itself. Are there perhaps problems with the permissions on your /tmp? It is indeed strange that Webrick behaves different from passenger for this use case, though. Can you somehow make absolutely certain that ruby is contacting

Re: [Puppet Users] saving copy of template on puppetmaster

2013-11-25 Thread Felix Frank
Hi, you might use that to cobble something together (using generate?) but that will most certainly end up very, very ugly. Instead, you may want to look for the documentation on how to recompile the catalog for a specific agent. You will need to configure the master to keep the requests

Re: [Puppet Users] create_resources and file

2013-11-25 Thread jcbollinger
On Friday, November 22, 2013 6:50:27 PM UTC-6, erkules wrote: Ahoi, On Thu, Nov 21, 2013 at 12:01:14PM +0100, Felix Frank wrote: Hi, tough call. You may have to replicate the file type in a defined type like so: define my_file($owner=root,$mode=644,...,$template=) {

Re: [Puppet Users] get list of all nodes in site.pp and use it in another module

2013-11-25 Thread Felix Frank
Hi, On 11/22/2013 02:04 PM, sasikiran v wrote: site.pp - node1 { 'first_node': a = 'hello' } this doesn't look like valid node syntax? new_module.pp -- // Here i want to get all the list of node_names, is there any possibility to retrieve Uhm, you

Re: [Puppet Users] get list of all nodes in site.pp and use it in another module

2013-11-25 Thread ●๋•کáکíkíŕáńツ
Hi Felix, I think the question which i asked didn't make sense. I am new to puppet, basically i don't have basics on how the things like node, class, define works, Is there any video tutorials avaiable to get through the puppet easily. Thanks, Sasikiran On Mon, Nov 25, 2013 at 9:33 PM, Felix

Re: [Puppet Users] get list of all nodes in site.pp and use it in another module

2013-11-25 Thread Felix Frank
Hi, I know of no video, but it's hard to convey the basics in such a form anyway, I believe. I recommend taking a look at the official tutorial: http://docs.puppetlabs.com/learning/ Regards, Felix On 11/25/2013 05:46 PM, ●๋•کáکíkíŕáńツ wrote: Hi Felix, I think the question which i asked

[Puppet Users] set password to never expire for a user

2013-11-25 Thread Stuart Cracraft
Hi, What is the Puppet directive to ensure a password never expires? Stuart -- 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] Re: Permission denied - /usr/share/puppet-dashboard/public/javascripts/all.js

2013-11-25 Thread Mark Haney
Well, if that's the case (i.e. you don't use one), where are some good documents on how to manage puppet via CLI? I'm not married to having a GUI, but so far the docs on the puppetlabs seem to be organized by chaos theory. I can't seem to find any decent 'Fisher-Price' version (IOW, someone

[Puppet Users] question about file {} type

2013-11-25 Thread Stuart Cracraft
My class reads like: class name1::name2 ($gidvariable) { file { somepath-to-file: ensure = file, mode = '0640', gid = $gidvariable, } } The problem is that the file isn't getting set to the $gidvariable's value which is a string abc. The other things work (presence as file,

Re: [Puppet Users] question about file {} type

2013-11-25 Thread Neil - Puppet List
Gid should be a number? On 25 Nov 2013 18:14, Stuart Cracraft smcracr...@gmail.com wrote: My class reads like: class name1::name2 ($gidvariable) { file { somepath-to-file: ensure = file, mode = '0640', gid = $gidvariable, } } The problem is that the file isn't getting

RE: [Puppet Users] question about file {} type

2013-11-25 Thread Kinzel, David
On 25 Nov 2013 18:14, Stuart Cracraft smcracr...@gmail.com wrote: My class reads like: class name1::name2 ($gidvariable) {   file { somepath-to-file: ensure = file, mode = '0640', gid = $gidvariable,  } } Try group instead of gid. This email communication and any files

[Puppet Users] Re: question about file {} type

2013-11-25 Thread Stuart Cracraft
I had wrongly assumed gid, from user type would apply to file type {}. group = $variable fixed the issue. Thanks. On Monday, November 25, 2013 10:14:09 AM UTC-8, Stuart Cracraft wrote: My class reads like: class name1::name2 ($gidvariable) { file { somepath-to-file: ensure = file,

[Puppet Users] ensuring a directory is empty

2013-11-25 Thread Stuart Cracraft
I have a requirement to ensure that /home/someuser/.ssh is empty at the start of an initialization. It can be removed completely What is the Puppet way to ensure a directory is empty prior to it being created? I'm looking for something like: file { /home/someuser/.ssh: ensure =

[Puppet Users] style of puppet run

2013-11-25 Thread Stuart Cracraft
Hi, The style in which I want to run Puppet is: 1) The agent daemon does not take any actions but is running so that it detects any changes to managed files, directories, services, packages, etc. as defined in the manifests 2) Only a manual action: e.g. puppet apply init.pp is

[Puppet Users] puppet.conf

2013-11-25 Thread Stuart Cracraft
Is there a way to prevent puppet from taking actions other than logging using the puppet.conf file variables instead of via --noop? -- 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,

[Puppet Users] Would have triggered 'refresh' from 2 events in /var/log/messages

2013-11-25 Thread Stuart Cracraft
Hi, I put a --noop into the rc file for puppet client and restarted it and watched it log the above message. My problem with the above message is it doesn't give enough detail as to what was discovered and what the 2 events were (mode difference, file existence, etc.) Is there a way to up the

[Puppet Users] Applying a manifest on a remote node

2013-11-25 Thread Stuart Cracraft
Hi, I have a manifest which, on the puppet master, lives in /etc/puppet/modules/somename/manifests/init.pp On nodes which the puppet master has, I don't see a similar directory. What is the way to apply the above manifest on the agent? Stuart -- You received this message because you are

Re: [Puppet Users] Applying a manifest on a remote node

2013-11-25 Thread Dan White
somename would be the name of the class defined by the module. To apply it to a node, you would include the class in the node's manifest. Reference: http://docs.puppetlabs.com/puppet/3/reference/lang_node_definitions.html “Sometimes I think the surest sign that intelligent life exists

Re: [Puppet Users] style of puppet run

2013-11-25 Thread Christopher Wood
On Mon, Nov 25, 2013 at 11:04:40AM -0800, Stuart Cracraft wrote: Hi, The style in which I want to run Puppet is:  1) The agent daemon does not take any actions but is running so that it detects any changes to managed files, directories, services, packages, etc. as

Re: [Puppet Users] Would have triggered 'refresh' from 2 events in /var/log/messages

2013-11-25 Thread Eugene Vilensky
On Mon, Nov 25, 2013 at 1:19 PM, Stuart Cracraft smcracr...@gmail.com wrote: We would like to know what would Puppet be changing if it were not running in --noop mode. Not sure about the .rc file, but I usually smoke test with --test. If that's not enough, add --verbose:

Re: [Puppet Users] puppet.conf

2013-11-25 Thread Eugene Vilensky
On Mon, Nov 25, 2013 at 1:10 PM, Stuart Cracraft smcracr...@gmail.com wrote: Is there a way to prevent puppet from taking actions other than logging using the puppet.conf file variables instead of via --noop? Yes:

Re: [Puppet Users] ensuring a directory is empty

2013-11-25 Thread Eugene Vilensky
On Mon, Nov 25, 2013 at 12:31 PM, Stuart Cracraft smcracr...@gmail.com wrote: I'm looking for something like: file { /home/someuser/.ssh: ensure = present-but-recreate-if-existing } Well, you still want ensure = directory. But take a look at the purge param:

Re: [Puppet Users] set password to never expire for a user

2013-11-25 Thread Eugene Vilensky
On Mon, Nov 25, 2013 at 11:25 AM, Stuart Cracraft smcracr...@gmail.com wrote: What is the Puppet directive to ensure a password never expires? Hi Stuart, A password property like that is usually operating system specific, and as such, you're looking for documentation about whether your

Re: [Puppet Users] avoiding duplicate package definitions with stdlib's ensure_packages

2013-11-25 Thread Chris Barbour
ensure_packages is not low risk, IMO. In testing, the following will result in a Duplicate declaration error: $packages = ['wget'] package { $packages: ensure = 'installed', } ensure_packages($packages) Ensure_packages will not create a resource conflict with another instance of

[Puppet Users] Re: ensuring a directory is empty

2013-11-25 Thread Stuart Cracraft
The purge feature looks a little extreme. It continues to delete files in the managed area not controlled by Puppet. I am looking for just a first-time wipe-the-slate-clean before it creates it as an empty directory, possibly populates it with a few files, and for now, doesn't try to manage

[Puppet Users] puppet agent reporting

2013-11-25 Thread Stuart Cracraft
Hi, I want to report my agent's puppet status not to its own /var/log/messages but to the puppet master's /var/log/messages. What's best practice? Stuart -- You received this message because you are subscribed to the Google Groups Puppet Users group. To unsubscribe from this group and

[Puppet Users] Re: set password to never expire for a user

2013-11-25 Thread Stuart Cracraft
I used: user { someuser: : password_max_age = '20', : } puppet describe user shows password_max_age can be set to a big number which represents days to expiration for the given user. Unfortunately, it doesn't also say something like infinite for forever... Stuart

[Puppet Users] Re: puppet.conf

2013-11-25 Thread Stuart Cracraft
Odd, I don't see it there. I'd expect something like: runinterval = never or something like that. On Monday, November 25, 2013 11:10:49 AM UTC-8, Stuart Cracraft wrote: Is there a way to prevent puppet from taking actions other than logging using the puppet.conf file variables instead of

Re: [Puppet Users] style of puppet run

2013-11-25 Thread Stuart Cracraft
Notes with ++ On Monday, November 25, 2013 11:53:42 AM UTC-8, Christopher Wood wrote: On Mon, Nov 25, 2013 at 11:04:40AM -0800, Stuart Cracraft wrote: Hi, The style in which I want to run Puppet is: 1) The agent daemon does not take any actions but is running so

Re: [Puppet Users] question about file {} type

2013-11-25 Thread Stuart Cracraft
I chose group = $groupname instead. On Monday, November 25, 2013 10:21:10 AM UTC-8, Neil - Puppet List wrote: Gid should be a number? On 25 Nov 2013 18:14, Stuart Cracraft smcra...@gmail.com javascript: wrote: My class reads like: class name1::name2 ($gidvariable) { file {

Re: [Puppet Users] disabling puppet agent auto-runs on a host

2013-11-25 Thread Calvin Walton
On Fri, 2013-11-22 at 11:43 -0800, Stuart Cracraft wrote: Hi, We do not want to have puppet changing things out from under us, then looking at a log file after-the-fact. We are okay with running puppet agent manually for the particular application we have chosen it for under our control.

[Puppet Users] nodes.pp on puppetmaster vs. puppet agent on puppet client

2013-11-25 Thread Stuart Cracraft
If I change nodes.pp on the PM, do I have to do an /etc/init.d/puppet restart on the puppet client to get it to receive the changes? I.e. does it have the old manifests/modules until the restart is done? -- You received this message because you are subscribed to the Google Groups Puppet

Re: [Puppet Users] disabling puppet agent auto-runs on a host

2013-11-25 Thread Stuart Cracraft
Hi Calvin, We want continuous 7x24x365 test with no changes unless physically applied by one or more authorized people only. As far as I can tell, the way to do this is: puppet agent --test --verbose --noop on the node and puppet apply whatever.pp on the node itself, with full logging

Re: [Puppet Users] Re: set password to never expire for a user

2013-11-25 Thread Matthew Burgess
On 25 November 2013 21:58, Stuart Cracraft smcracr...@gmail.com wrote: puppet describe user shows password_max_age can be set to a big number which represents days to expiration for the given user. Unfortunately, it doesn't also say something like infinite for forever... chage(1) says:

Re: [Puppet Users] Re: set password to never expire for a user

2013-11-25 Thread Stuart Cracraft
Notes with ++ inlined. On Monday, November 25, 2013 2:58:41 PM UTC-8, Matthew Burgess wrote: On 25 November 2013 21:58, Stuart Cracraft smcra...@gmail.comjavascript: wrote: puppet describe user shows password_max_age can be set to a big number which represents days to expiration for

Re: [Puppet Users] Re: set password to never expire for a user

2013-11-25 Thread Matthew Burgess
On 25 November 2013 23:00, Stuart Cracraft smcracr...@gmail.com wrote: Notes with ++ inlined. On Monday, November 25, 2013 2:58:41 PM UTC-8, Matthew Burgess wrote: On 25 November 2013 21:58, Stuart Cracraft smcra...@gmail.com wrote: puppet describe user shows password_max_age can be set

Re: [Puppet Users] Re: set password to never expire for a user

2013-11-25 Thread Stuart Cracraft
I have direction to use puppet rather than the OS and exec... On Nov 25, 2013, at 3:03 PM, Matthew Burgess matthew.2.burg...@gmail.com wrote: On 25 November 2013 23:00, Stuart Cracraft smcracr...@gmail.com wrote: Notes with ++ inlined. On Monday, November 25, 2013 2:58:41 PM UTC-8,

Re: [Puppet Users] Re: set password to never expire for a user

2013-11-25 Thread Matthew Burgess
On 25 November 2013 23:11, Stuart Cracraft smcracr...@me.com wrote: I have direction to use puppet rather than the OS and exec... Not quite sure I understand. Are you saying that you can write puppet manifests to make all kinds of changes but you're not allowed to run 'chage -l user' to

Re: [Puppet Users] Re: set password to never expire for a user

2013-11-25 Thread Stuart Cracraft
Notes with ++ inlined. On Monday, November 25, 2013 3:17:40 PM UTC-8, Matthew Burgess wrote: On 25 November 2013 23:11, Stuart Cracraft smcra...@me.com javascript:wrote: I have direction to use puppet rather than the OS and exec... Not quite sure I understand. Are you saying that you

[Puppet Users] Re: nodes.pp on puppetmaster vs. puppet agent on puppet client

2013-11-25 Thread Rahul Khengare
Hi Stuart, You don't have to do /etc/init.d/puppet restart on client machine, whenever puppet agent run/ fetches the catalog from PM using latest manifests. Thanks, Rahul Khengare NTT DATA OSS Center, Pune, India. On Tuesday, November 26, 2013 4:17:16 AM UTC+5:30, Stuart Cracraft

Re: [Puppet Users] Re: nodes.pp on puppetmaster vs. puppet agent on puppet client

2013-11-25 Thread Stuart Cracraft
But it has to be activated in nodes to fetch, no? On Nov 25, 2013, at 9:05 PM, Rahul Khengare rahulk1...@gmail.com wrote: Hi Stuart, You don't have to do /etc/init.d/puppet restart on client machine, whenever puppet agent run/ fetches the catalog from PM using latest manifests.

Re: [Puppet Users] Re: nodes.pp on puppetmaster vs. puppet agent on puppet client

2013-11-25 Thread Peter Bukowinski
No. An agent need not be aware of what classes are assigned to it before it contacts the puppetmaster. As long as your agent is configured to run on a regular interval, it will automatically get the latest configuration on the very next run. If you want to manually run the agent to apply those

[Puppet Users] Re: puppet agent reporting

2013-11-25 Thread Rahul Khengare
Hi Stuart, Take a look on reporting facility present in puppet, http://docs.puppetlabs.com/guides/reporting.html It might help you. Thanks, Rahul Khengare On Tuesday, November 26, 2013 2:41:01 AM UTC+5:30, Stuart Cracraft wrote: Hi, I want to report my agent's puppet status not

[Puppet Users] Re: Applying a manifest on a remote node

2013-11-25 Thread Rahul Khengare
Hi Stuart, I have a manifest which, on the puppet master, lives in /etc/puppet/modules/somename/manifests/init.pp On nodes which the puppet master has, I don't see a similar directory. Puppet manifests are present only on puppet master What is the way to apply the above manifest on

Re: [Puppet Users] Re: puppet agent reporting

2013-11-25 Thread Stuart Cracraft
This is great Rahul. Stuart On Nov 25, 2013, at 9:18 PM, Rahul Khengare rahulk1...@gmail.com wrote: Hi Stuart, Take a look on reporting facility present in puppet, http://docs.puppetlabs.com/guides/reporting.html It might help you. Thanks, Rahul Khengare On Tuesday,