Pulling Strings With Puppet - James Turnbull [9]
For RPM-based distributions, there are three sources of RPM files available: at Reductive's site (https://reductivelabs.com/downloads/rpm/), at Dag Wieers RPM repository (http: //dag.wieers. com/rpm/packages/facter/), and via Red Hat employee David Lutterkort's repository (http://people.redhat.com/dlutter/yum/).
There is also a Facter package available for OS X. The package combines both Facter and Puppet and can be downloaded from http: //reductivelabs. com/downloads/packages/OSX/. Reductive reports that the build appears to be stable, but the OS X version has not been extensively tested.
You can confirm Facter is installed by running it with the --version option to return the release.
Installing RDoc
You may want to optionally install the RDoc package. RDoc is the Ruby Standard Documentation System. It allows Ruby applications to return help text and documentation when prompted. RDoc may come with Ruby versions later than 1.8.2, and many platforms still have a separate package for RDoc. If you don't have RDoc installed, your Facter or Puppet binaries will not return any help text when prompted, for example:
You can confirm whether you have RDoc installed or not by checking for the presence of the RDoc usage library like so:
If the command returns installed, you already have RDoc. But if it returns
you will need to install RDoc if you wish documentation to be returned by the Puppet binaries.
In Table 2-3, I have listed those platforms that provide separate RDoc packages.
Your package management system may also prompt you to install some dependencies when you install RDoc; for example, the irb package is also commonly required.
Installing Puppet
As I discussed in Chapter 1, the software elements of Puppet consist of a server and a client. Now that you've installed the required prerequisites, I am going to demonstrate how to install Puppet. You can install Puppet via source, from a package on some platforms, and using a Ruby Gem. I'll demonstrate how to use all methods.
Tip -► If you build your servers with tools like Jumpstart or Kickstart, you can also include the Puppet client (and its prerequisites) as part of your default build. That'll help you to quickly add nodes to your Puppet environment.
Installing from Source
The latest source package for Puppet is available from the Reductive Labs site at http://reductivelabs.com/trac/puppet/wiki/DownloadingPuppet. It is available in two packages-stable and latest. The stable source package is the current production version, and the latest version represents the latest development release of Puppet. For your production environments, I recommend that you install the stable package and reserve the latest version for your test or development environment.
Tip - Puppet is actively developed, and version upgrades are frequent. I recommend regularly checking back for updates and changes. Puppet's latest source code is also available via Reductive Lab's Git site at http: //reductivelabs. com/git/puppet/. This is the latest code and may have issues with stability, but it represents the cutting edge of development and features.
The source package contains both the Puppet server and client- so we only need to download one file.
Note - You might need to add the --no-check-certificate option to wget if your host can't validate Reductive Lab's certificate.
At the time of writing, the latest stable Puppet version is 0.22.4, and the current development release is 0.23.2. Unpack the downloaded file and change into the resulting directory.
Puppet is installed by executing the install. rb script contained in the package by running it with Ruby like so:
You can then confirm Puppet is installed by running
The Puppet server and client are now both installed, and you can refer to the sections "Configuring puppetmasterd" or "Configuring puppetd" for configuration instructions.
Installing Puppet by Package
Puppet is available as a package for a number of platforms, but not all.