Thursday, November 3, 2011

Installing Puppet on Centos 5 directly from Puppet Labs

photo: wikimedia commons : User:Liftarn
If you want the latest stable release of puppet on a Centos 5 machine, you can get it from Puppet Labs' own yum repo.  Other "usual" add-on repos (epel, fedora, e.g.) can lag by as much as one minor version.  Puppet Labs tries to keep the version in their repo as stable as possible, according to the Puppet professional services guy sitting across from me, today.  (Hi, Carl!)

First, download an rpm to add the puppet labs yum repos.  Then download an rpm to add the EPEL repo.  Puppet requires a couple sneaky ruby pieces, and EPEL has 'em.  (ruby-shadow and ruby-augeas, fyi)

  cd /tmp
  wget http://yum.puppetlabs.com/el/5/products/x86_64/puppetlabs-release-5-1.noarch.rpm
  sudo rpm -Uvh puppetlabs-release-5-1.noarch.rpm
  wget http://download.fedora.redhat.com/pub/epel/5/x86_64/epel-release-5-4.noarch.rpm
  sudo rpm -Uvh epel-release-5-4.noarch.rpm
  yum repolist  # just to see that they actually installed

Both repo definitions enable their main binary repos, for a normal `yum install` command, so there's no need to add flags to enable them.  Source repos and testing versions are disabled, but can be enabled if you have some nutty reason to do it.

You should now be able to `yum install` the puppet client and/or server -- with all the dependencies being available.

  yum install puppet # for a client
  yum install puppet puppet-server # to include the server pieces, as well.
  # actually, pupper-server just adds an init script
  # and some scripts that pretend to be things like puppetmasterd

Ta da!

No comments:

Post a Comment