Book Image

Mastering Puppet - Second Edition

By : Thomas Uphill
Book Image

Mastering Puppet - Second Edition

By: Thomas Uphill

Overview of this book

Puppet is a configuration management system and a language. It was written for and by system administrators to manage large numbers of systems efficiently and prevent configuration drifts. Mastering Puppet deals with the issues faced when scaling out Puppet to handle large numbers of nodes. It will show you how to fit Puppet into your enterprise and allow many developers to work on your Puppet code simultaneously. In addition, you will learn to write custom facts and roll your own modules to solve problems. Next, popular options for performing reporting and orchestration tasks will be introduced in this book. Moving over to troubleshooting techniques, which will be very useful. The concepts presented are useful to any size organization. By the end of the book, you will know how to deal with problems of scale and exceptions in your code, automate workflows, and support multiple developers working simultaneously.
Table of Contents (17 chapters)

Modules from the Forge


Modules on Puppet Forge can be installed using Puppet's built-in module command. The modules on the Forge have files named Modulefile, which define their dependencies; so, if you download modules from the Forge using puppet module install, then their dependencies will be resolved in a way similar to how yum resolves dependencies for rpm packages.

To install the puppetlabs-puppetdb module, we will simply issue a puppet module install command in the appropriate directory. We'll create a new directory in tmp; for our example, this will be /tmp/public_modules, as shown here:

[git@stand ~]$ cd /tmp
[git@stand tmp]$ mkdir public_modules
[git@stand tmp]$ cd public_modules/
[git@stand public_modules]$ 

Then, we'll inform Puppet that our modulepath is /tmp/public_modules and install the puppetdb module using the following command:

[git@stand public_modules]$ puppet module install --modulepath=/tmp/public_modules puppetlabs-puppetdb
Notice: Preparing to install into /tmp/public_modules...