Re: [Puppet Users] How to ensure a host has no aliases

2010-01-14 Thread Ohad Levy
ensure => absent On Thu, Jan 14, 2010 at 3:11 PM, Peter wrote: > Hi, > > I'm trying to create a host entry and want puppet to remove the alias > if is exists for that host in the host file. > > If alias is not set aliases are left as they are for that host. > > If alias is set to undef aliases a

[Puppet Users] custom init script and status exit codes

2010-01-14 Thread florian.engelmann
Hello, we are running a custom ssh server on another port than the original sshd on all of our hosts. We use puppet to roll out this configuration. It is just creating a symbolic link to the original sshd and does copy its custom config file and its own init script. This works on all our different

[Puppet Users] Re: How to ensure a host has no aliases

2010-01-14 Thread Peter
I have host { "hosts buildserver" : ip => "192.168.1.1" name => "buildserver", ensure => present, } so how do I ensure aliases are absent host { "hosts buildserver" : ip => "192.168.1.1", name => "

Re: [Puppet Users] Re: How to ensure a host has no aliases

2010-01-14 Thread Silviu Paragina
So for your example you would want to remove all host entries that point to 192.168.1.1 except the buildserver host entry? Or you want the buildserver host entry to be removed? Or you want to replace whatever host entry buildserver has, with 192.168.1.1? Peter wrote: I have host { "host

Re: [Puppet Users] Managing authorized_keys

2010-01-14 Thread Andre Timmermann
Am Mittwoch, den 13.01.2010, 22:56 +0200 schrieb Silviu Paragina: > May I suggest using this recipe > http://reductivelabs.com/trac/puppet/wiki/Recipes/ModuleSSHAuth ? > It's more recent and uses the ssh_authorized_key resource in puppet. Thank you for the hint. This is going far beyound what we

Re: [Puppet Users] Managing authorized_keys

2010-01-14 Thread Andre Timmermann
Am Mittwoch, den 13.01.2010, 16:01 -0500 schrieb Andrew Schulman: > > > > debug: Executing '/usr/bin/perl -ni -e 'print unless /^\Qssh-rsa > > B3NzaC1yc2EAA/5GytXDjAR3XoxTR6uM= test...@test > > \E$/' '/root/.ssh/authorized_keys'' > > Change /.../ to m{...} . This has no effect - it does not

Re: [Puppet Users] custom init script and status exit codes

2010-01-14 Thread Silviu Paragina
I'm guessing you did /etc/init.d/btsh start; echo $? and it works fine. (also for stop and restart) What you should do is add some debugging code. I think echo debug stuff >2 would be just enough, if not write in a separate file (for execs is enough). The most likely cause for the script to wor

Re: [Puppet Users] How to ensure a host has no aliases

2010-01-14 Thread Trevor Vaughan
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Instead of using '', try adding a space in there, ' '. I haven't tried this, but it should work. Trevor On 01/14/2010 02:11 AM, Peter wrote: > Hi, > > I'm trying to create a host entry and want puppet to remove the alias > if is exists for that hos

[Puppet Users] Re: Global vs local puppet management

2010-01-14 Thread SyRenity
Hi. Thanks for all the advices. So the recommended strategy seems to be: * One super-master puppet in cloud * Local puppet master in every deployment * Super-puppet master configures all the local puppet-masters, which in turn configure their clients Something like this? The questions I have a

Re: [Puppet Users] How to ensure a host has no aliases

2010-01-14 Thread Ohad Levy
I guess I was wrong, looking at the code I dont think that you can remove an alias, just replace it to something else. funny, if you put the word absent as an alias, puppet think there is no alias. sounds like a bug to me as the absent key word is translated into absent alias value. On Thu, Jan

Re: [Puppet Users] Managing authorized_keys

2010-01-14 Thread Silviu Paragina
Andre Timmermann wrote: Am Mittwoch, den 13.01.2010, 22:56 +0200 schrieb Silviu Paragina: May I suggest using this recipe http://reductivelabs.com/trac/puppet/wiki/Recipes/ModuleSSHAuth ? It's more recent and usesI will check the routine which is used to install and revoke keys, the ssh_aut

[Puppet Users] Re: How to ensure a host has no aliases

2010-01-14 Thread Peter
Its all a bit weird. an empty string does what I want but it then changes the host file and spits out its changing absent to absent. a space gives Jan 14 03:48:04 buildsun4u puppetd[12213]: [ID 702911 daemon.error] Could not run Puppet configuration client: Parameter alias failed: Aliases cannot

Re: [Puppet Users] Re: How to ensure a host has no aliases

2010-01-14 Thread Ohad Levy
I guess your options are a template or augeas. Please fill in an issue in redmine. cheers, Ohad On Thu, Jan 14, 2010 at 8:11 PM, Peter wrote: > Its all a bit weird. > > an empty string does what I want but it then changes the host file and > spits out its changing absent to absent. > > a space

RE: [Puppet Users] custom init script and status exit codes

2010-01-14 Thread florian.engelmann
Hello Silviu, thank you for your fast answer. The problem is fixed now. The script was starting with some comment and not "#!/bin/sh". On Red Hat this was no problem but on Debian it did not work. Regards, Florian > -Original Message- > From: puppet-users@googlegroups.com [mailto:puppet-

[Puppet Users] Git vs SVN?

2010-01-14 Thread SyRenity
Hi. Is there any advantage of using Git vs SVN when using puppet? What folks here mostly use? Thanks. -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-us...@googlegroups.com. To unsubscribe from this

Re: [Puppet Users] Git vs SVN?

2010-01-14 Thread James Turnbull
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 15/01/10 12:19 AM, SyRenity wrote: > Hi. > > Is there any advantage of using Git vs SVN when using puppet? > > What folks here mostly use? I use Git because: a) It's distributed and I push lots of manifests around in convoluted ways, and b) It's

[Puppet Users] Re: Git vs SVN?

2010-01-14 Thread SyRenity
Hi. > > I use Git because: > > a) It's distributed and I push lots of manifests around in > convoluted ways, and > b) It's simply more powerful around branching, cherry-picking, > rebasing, etc, etc. > Thanks for sharing. How do you achieve centralization of all multiple git repos, in case you ha

Re: [Puppet Users] Re: Git vs SVN?

2010-01-14 Thread James Turnbull
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 15/01/10 12:30 AM, SyRenity wrote: > > Thanks for sharing. How do you achieve centralization of all multiple > git repos, in case you have several puppetmasters? I don't - I have one central Git repo with multiple branches matching my environments

[Puppet Users] Can someone explain this structure?

2010-01-14 Thread SyRenity
Hi. I found the following code example in Ohad's great monit module: http://github.com/ohadlevy/puppet-monit/ class mymodule::myclass { include monit::common } Am I correct in my understanding, that it allows creating my own puppet module, which will include the monit module as well? (Just

Re: [Puppet Users] Re: Git vs SVN?

2010-01-14 Thread James Turnbull
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 15/01/10 12:36 AM, James Turnbull wrote: > > On 15/01/10 12:30 AM, SyRenity wrote: > > >> >> Thanks for sharing. How do you achieve centralization of all multiple >> >> git repos, in case you have several puppetmasters? > > > > I don't - I have one

Re: [Puppet Users] Can someone explain this structure?

2010-01-14 Thread Dan Bode
On Thu, Jan 14, 2010 at 5:38 AM, SyRenity wrote: > Hi. > > I found the following code example in Ohad's great monit module: > http://github.com/ohadlevy/puppet-monit/ > > class mymodule::myclass { >include monit::common > } > > > Am I correct in my understanding, that it allows creating my ow

[Puppet Users] Re: Run a script when it has been changed.

2010-01-14 Thread JoE
Yeah, that is what is actually in my file. I had to change the names to protect the innocent, and I made some mistakes while doing that. Here is a more accurate look at what I am working on: class data { } define get-data() { file { "/usr/bin/data": ensure => directory,

[Puppet Users] Re: Run a script when it has been changed.

2010-01-14 Thread JoE
What is interesting is that this will not work even if "get-data.sh" is already in "/usr/bin/data". Is this a bug? On Jan 14, 9:57 am, JoE wrote: > Yeah, that is what is actually in my file. I had to change the names > to protect the innocent, and I made some mistakes while doing that. > Here is

[Puppet Users] Package install and upgrade?

2010-01-14 Thread Jewels
I searched through the archives and can't seem to find this. I have a package that has rpms for install, and i am able to do that, not a problem. I am looking for a way to ensure it is upgraded? I have version 1.0 installed and want 2.5.3 installed on all systems. so *IF* you can't upgrade to 2.

Re: [Puppet Users] Re: Run a script when it has been changed.

2010-01-14 Thread Trevor Hemsley
You're missing things from there. You have a file{} resource for the directory /usr/bin/data but no definition for the get-data.sh within it. The file itself needs to be managed by puppet before you can subscribe to it. Add a file {"/usr/bin/data/get-data.sh"} definition. JoE wrote: > What is inte

[Puppet Users] Re: Run a script when it has been changed.

2010-01-14 Thread JoE
Nevermind, I solved the problem. The file needs to be explicitly mentioned even though it is already in /usr/bin/data, see the code below: define get-data() { file { "/usr/bin/data": owner => "root", group => "wheel", mode => "755", purge => t

[Puppet Users] Re: Run a script when it has been changed.

2010-01-14 Thread JoE
>You're missing things from there. You have a file{} resource for the >directory /usr/bin/data but no definition for the get-data.sh within it. >The file itself needs to be managed by puppet before you can subscribe >to it. Add a file {"/usr/bin/data/get-data.sh"} definition. I should have refresh

[Puppet Users] Re: Git vs SVN?

2010-01-14 Thread JoE
You can even use git for an svn style workflow. For example, at my work, we have a local git repo for managing puppet configs, and then we periodically push those out to a backup server. git push ssh://backup.server/path/to/puppet/repo.git You can even use git with an already existing svn server.

Re: [Puppet Users] Managing authorized_keys

2010-01-14 Thread Andre Timmermann
Hi Silviu, Am Donnerstag, den 14.01.2010, 12:59 +0200 schrieb Silviu Paragina: > If that is all take a look at: > http://reductivelabs.com/static_files/TypeReference.html#ssh-authorized-key > it does just what you need. :) Ok, thanks, that looks great. One single problem left ;) How do I read t

[Puppet Users] New Puppet Documentation Site

2010-01-14 Thread Teyo Tyree
Hello, For sometime now, we have being considering how to improve on the current Puppet documentation available in the existing wiki. We knew that we needed to provide some curated documentation and that some of the curated documentation would be directly sourced from the wiki. We also wanted to

Re: [Puppet Users] Managing authorized_keys

2010-01-14 Thread Robin Bowes
On 14/01/10 10:34, Andre Timmermann wrote: > Am Mittwoch, den 13.01.2010, 16:01 -0500 schrieb Andrew Schulman: > >>> >>> debug: Executing '/usr/bin/perl -ni -e 'print unless /^\Qssh-rsa >>> B3NzaC1yc2EAA/5GytXDjAR3XoxTR6uM= test...@test >>> \E$/' '/root/.ssh/authorized_keys'' >> >> Change /...

Re: [Puppet Users] Managing authorized_keys

2010-01-14 Thread Andre Timmermann
Hi Robin, Am Donnerstag, den 14.01.2010, 17:40 + schrieb Robin Bowes: > Hmm, that should work. > > I created a file named "test" containing: > > ssh-rsa B3NzaC1yc2EAA/5GytXDjAR3XoxTR6uM= test...@test > asdasdasd > asdasdasd > > I then ran this (all on one line): > > perl -ni -e 'print

Re: [Puppet Users] New Puppet Documentation Site

2010-01-14 Thread Andrew Schulman
> http://docs.reductivelabs.com/guides/introduction.html There seems to be a glitch in http://docs.reductivelabs.com/guides/introduction.html#functions . -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppe

Re: [Puppet Users] Git vs SVN?

2010-01-14 Thread Russ Allbery
SyRenity writes: > Is there any advantage of using Git vs SVN when using puppet? We just finished switching from Subversion to Git because we wanted Git's merging and cherry-pick support for maintaining separate production and development branches of our manifests. -- Russ Allbery (r...@stanfo

Re: [Puppet Users] Package install and upgrade?

2010-01-14 Thread Scott Smith
On 1/14/10 7:05 AM, Jewels wrote: I searched through the archives and can't seem to find this. I have a package that has rpms for install, and i am able to do that, not a problem. I am looking for a way to ensure it is upgraded? I have version 1.0 installed and want 2.5.3 installed on all syst

[Puppet Users] Re: Puppet for app deployment

2010-01-14 Thread Alex-SF
Just as a point of clarification, ControlTier does not use Capistrano though there is a bit of conceptual similarity around the notion of "command dispatching". On Jan 11, 10:27 am, Scott Smith wrote: > SyRenity wrote: > > Thanks. These 2 seems to be mostly Ruby/ROR oriented - any of them > > wor

Re: [Puppet Users] Re: Puppet for app deployment

2010-01-14 Thread Scott Smith
On 1/14/10 11:36 AM, Alex-SF wrote: Just as a point of clarification, ControlTier does not use Capistrano though there is a bit of conceptual similarity around the notion of "command dispatching". You're right, as much as I read somehow I misunderstood that. Speaking of, how many people on th

Re: [Puppet Users] New Puppet Documentation Site

2010-01-14 Thread Nigel Kersten
On Thu, Jan 14, 2010 at 10:50 AM, Andrew Schulman < google-groups-and...@sneakemail.com> wrote: > > http://docs.reductivelabs.com/guides/introduction.html > > There seems to be a glitch in > http://docs.reductivelabs.com/guides/introduction.html#functions . > > I really like it, but the font size

Re: [Puppet Users] New Puppet Documentation Site

2010-01-14 Thread Carl Caum
Agreed. The font is too big. Other than that it's great though. Good work On Jan 14, 2010, at 4:16 PM, Nigel Kersten wrote: > > > On Thu, Jan 14, 2010 at 10:50 AM, Andrew Schulman > wrote: > > http://docs.reductivelabs.com/guides/introduction.html > > There seems to be a glitch in > http:/

Re: [Puppet Users] New Puppet Documentation Site

2010-01-14 Thread Nigel Kersten
On Thu, Jan 14, 2010 at 2:19 PM, Carl Caum wrote: > Agreed. The font is too big. Other than that it's great though. Good work > I also have to say that I really appreciate the speed at which this loads compared to the old site too :) > On Jan 14, 2010, at 4:16 PM, Nigel Kersten wrote: > > >

Re: [Puppet Users] New Puppet Documentation Site

2010-01-14 Thread Andrew Schulman
> I also have to say that I really appreciate the speed at which this loads > compared to the old site too :) You've got that right. -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-us...@googlegroups.

Re: [Puppet Users] New Puppet Documentation Site

2010-01-14 Thread Bruce Williams
On Thu, Jan 14, 2010 at 3:36 PM, Andrew Schulman < google-groups-and...@sneakemail.com> wrote: > > I also have to say that I really appreciate the speed at which this loads > > compared to the old site too :) > > You've got that right. > > Thanks! We're pretty happy with this new system -- and as

Re: [Puppet Users] New Puppet Documentation Site

2010-01-14 Thread Russ Allbery
Nigel Kersten writes: > Andrew Schulman wrote: >> There seems to be a glitch in >> http://docs.reductivelabs.com/guides/introduction.html#functions . > I really like it, but the font size is too big for documentation > imho. I'm finding myself zooming out, which I rarely do. > Chrome and Safar

[Puppet Users] Vague Dependency Error message.

2010-01-14 Thread Douglas Garstang
I'm getting this: Jan 14 16:42:15 app01 puppetd[3671]: Could not apply complete catalog: Found dependency cycles in the following relationships: File[] => Package[puppet], File[] => File[] Pardon my French, but WTF does that mean? What do I do with this? Doug. -- You received this message beca

Re: [Puppet Users] Vague Dependency Error message.

2010-01-14 Thread Trevor Vaughan
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 It means you have something seriously special going on ;-). Most likely, you have something like the following: file { "$foo": ... } file { "$bar": require => File["$foo"] } Where $foo and $bar just happen to be blank. So, Puppet is creating File[]