[Puppet Users] Re: Installing applications using puppet
Once I did this class for mailscanner installation, can be an example. class mailscanner { $mailscannerver=MailScanner-4.69.9-2 $mailscannerfile=$mailscannerver.rpm.tar.gz exec { mailscanner_prerequisites: command = $operatingsystem ? { default = yum install -y wget tar gzip rpm- build binutils glibc-devel gcc make, }, onlyif = test ! -f /usr/src/ $mailscannerfile, } exec { mailscanner_download: command = cd /usr/src ; wget http://www.mailscanner.info/files/4/rpm/$mailscannerfile;, onlyif = test ! -f /usr/src/ $mailscannerfile, require = Exec[mailscanner_prerequisites], } exec { mailscanner_extract: command = cd /usr/src ; tar -zxvf $mailscannerfile, require = Exec[mailscanner_download], onlyif = test ! -d /usr/src/ $mailscannerver, } exec { mailscanner_install: command = cd /usr/src/$mailscannerver ; ./ install.sh, require = [ Exec[mailscanner_extract], Package[spamassassin], Package[clamav] ], unless = rpm -qi mailscanner, } service { mailscanner: name = MailScanner, ensure = running, enable = true, hasrestart = true, hasstatus = true, require = Exec[mailscanner_install], } } On Jun 25, 10:42 pm, Neil K sate...@gmail.com wrote: Hi all, I am pretty new to Puppet. My puppet master server is a RHEL 5 box and puppet client is a CentOS 5.3 vm. I have managed to configure puppet server to successfully install.and upgrade rpm based packages on the client machine. Is it possible to install noon-rpm based packages using puppet? Like packages comes as tar.gz such as web based applications? If it is possible, please provide any example manifests or any good documents that I can follow. Thanks, Neil --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Puppet Users group. To post to this group, send email to puppet-users@googlegroups.com To unsubscribe from this group, send email to puppet-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~--~~~~--~~--~--~---
[Puppet Users] Re: Installing applications using puppet
On Jun 26, 2009, at 4:06 AM, Bryan Kearney wrote: Bjørn Dyresen wrote: On Jun 25, 2009, at 10:42 PM, Neil K wrote: Hi all, I am pretty new to Puppet. My puppet master server is a RHEL 5 box and puppet client is a CentOS 5.3 vm. I have managed to configure puppet server to successfully install.and upgrade rpm based packages on the client machine. Is it possible to install noon-rpm based packages using puppet? Like packages comes as tar.gz such as web based applications? It is possible to do anything with puppet through the exec type. However if you are expecting a lot of these cases I recommend building the packages and use your distributions package manager instead. This is much cleaner and a more maintainable way of doing it. I had to hack a single_exec type.. it drops a touch file after it runs a script. It is nasty, but if the script is not idempotent.. it works. Yes, Im also doing this. I still think if you are expecting a lot of these scenarios, you will be way better off with building the packages and use the package manager. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Puppet Users group. To post to this group, send email to puppet-users@googlegroups.com To unsubscribe from this group, send email to puppet-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~--~~~~--~~--~--~---
[Puppet Users] Re: Installing applications using puppet
Wrong place to do this, you do not use puppet to create a package. you sue puppet to install the package. The distribution you are using will dictate how to create packages. The ./configure, make, make install plus anything else needed for your particular package format would be done by you to create the application package. The package would then be setup in a local repository and now puppet uses the appropraite package manager to install you custom package. what distribution are you using? Evan My puppet master server is RHEL 5 and puppet client is CentOS 5.3. I am not sure what you exactly mean by create the application package. If you could explain that, that would be helpful. Regards, Neil --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Puppet Users group. To post to this group, send email to puppet-users@googlegroups.com To unsubscribe from this group, send email to puppet-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~--~~~~--~~--~--~---
[Puppet Users] Re: Installing applications using puppet
done by you to create the application package. The package would then be setup in a local repository and now puppet uses the appropraite package manager to install you custom package. what distribution are you using? Evan My puppet master server is RHEL 5 and puppet client is CentOS 5.3. I am not sure what you exactly mean by create the application package. If you could explain that, that would be helpful. In this case, creating an application package means make an RPM. Redhat , Fedora and Centos website all have documentation on doing this. I suggest you start there for learning the basics of RPM package creation. Evan --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Puppet Users group. To post to this group, send email to puppet-users@googlegroups.com To unsubscribe from this group, send email to puppet-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~--~~~~--~~--~--~---
[Puppet Users] Re: Installing applications using puppet
Neil K wrote: Hi all, I am pretty new to Puppet. My puppet master server is a RHEL 5 box and puppet client is a CentOS 5.3 vm. I have managed to configure puppet server to successfully install.and upgrade rpm based packages on the client machine. Is it possible to install noon-rpm based packages using puppet? Like packages comes as tar.gz such as web based applications? If it is possible, please provide any example manifests or any good documents that I can follow. Thanks, Neil Hi Neil, you want to check out the 'define' keyword in the puppet language doc. This way you can have a definition like my_pkg pass it some options, and all the magic to set it up can be done inside the define. I don't currently have an example because I package most of my stuff in .debs and put it in a custom repo. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Puppet Users group. To post to this group, send email to puppet-users@googlegroups.com To unsubscribe from this group, send email to puppet-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~--~~~~--~~--~--~---
[Puppet Users] Re: Installing applications using puppet
On Jun 25, 2009, at 10:42 PM, Neil K wrote: Hi all, I am pretty new to Puppet. My puppet master server is a RHEL 5 box and puppet client is a CentOS 5.3 vm. I have managed to configure puppet server to successfully install.and upgrade rpm based packages on the client machine. Is it possible to install noon-rpm based packages using puppet? Like packages comes as tar.gz such as web based applications? It is possible to do anything with puppet through the exec type. However if you are expecting a lot of these cases I recommend building the packages and use your distributions package manager instead. This is much cleaner and a more maintainable way of doing it. Regards --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Puppet Users group. To post to this group, send email to puppet-users@googlegroups.com To unsubscribe from this group, send email to puppet-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~--~~~~--~~--~--~---
[Puppet Users] Re: Installing applications using puppet
Thank you for your replies. As I said I am pretty new to this puppet language. Could any one please point how to do a sample package install which includes a ./configure, make, make install inside a package directory? Thanks again for our helps. Regards, Neil --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Puppet Users group. To post to this group, send email to puppet-users@googlegroups.com To unsubscribe from this group, send email to puppet-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~--~~~~--~~--~--~---
[Puppet Users] Re: Installing applications using puppet
Hi, I am new to puppet as well, but I could tell you how to do a similar install. exec { getthesource: command = wget http://thesourceurl;, cwd = /the/directory/to/issue/this/command/from } exec { untarthesource: command = the_untar_command, cwd = the/directory/to/issue/this/command/from, require = Exec[getthesource] } exec { ./configure: command = the/directory/to/issue/this/command/from/configure, cwd = as above, require = Exec[untarthesource] } And the other steps follow in a similar manner.. You should probably check the exec resource type in the type reference. . But, I think this is not the most elegant way of doing it... There is the package resource type in puppet which can be used to install packages from binaries, but yes, I haven't found another way to install from source. 2009/6/25 Neil K sate...@gmail.com Thank you for your replies. As I said I am pretty new to this puppet language. Could any one please point how to do a sample package install which includes a ./configure, make, make install inside a package directory? Thanks again for our helps. Regards, Neil -- Regards, Swati --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Puppet Users group. To post to this group, send email to puppet-users@googlegroups.com To unsubscribe from this group, send email to puppet-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~--~~~~--~~--~--~---
[Puppet Users] Re: Installing applications using puppet
Neil K wrote: Hi all, I am pretty new to Puppet. My puppet master server is a RHEL 5 box and puppet client is a CentOS 5.3 vm. I have managed to configure puppet server to successfully install.and upgrade rpm based packages on the client machine. Is it possible to install noon-rpm based packages using puppet? Like packages comes as tar.gz such as web based applications? If it is possible, please provide any example manifests or any good documents that I can follow. Yes.. it is possible. Depending on the scripts that are required to install the package, there are some hacks you may need to do. There are some examples of scripts here: http://www.thincrust.org/help.html They are tailored for running puppet stand alone to build appliances.. so YMMV... but it proves it can be done :) -- bk --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Puppet Users group. To post to this group, send email to puppet-users@googlegroups.com To unsubscribe from this group, send email to puppet-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~--~~~~--~~--~--~---
[Puppet Users] Re: Installing applications using puppet
On Thu, Jun 25, 2009 at 4:36 PM, Neil Ksate...@gmail.com wrote: Thank you for your replies. As I said I am pretty new to this puppet language. Could any one please point how to do a sample package install which includes a ./configure, make, make install inside a package directory? Thanks again for our helps. Wrong place to do this, you do not use puppet to create a package. you sue puppet to install the package. The distribution you are using will dictate how to create packages. The ./configure, make, make install plus anything else needed for your particular package format would be done by you to create the application package. The package would then be setup in a local repository and now puppet uses the appropraite package manager to install you custom package. what distribution are you using? Evan --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Puppet Users group. To post to this group, send email to puppet-users@googlegroups.com To unsubscribe from this group, send email to puppet-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~--~~~~--~~--~--~---