Extending Puppet


Extending Puppet
eBook: $16.99
Formats: PDF, PacktLib, ePub and Mobi formats
$14.44
save 15%!
Print + free eBook + free PacktLib access to the book: $44.98    Print cover: $27.99
$27.99
save 38%!
Free Shipping!
UK, US, Europe and selected countries in Asia.
Also available on:
Overview
Table of Contents
Author
Support
Sample Chapters
  • Plan, test, and execute your Puppet deployments
  • Write reusable and maintainable Puppet code
  • Handle challenges that might arise in upcoming versions of Puppet
  • Explore the Puppet ecosystem in-depth, through a hands-on, example driven approach

Book Details

Language : English
Paperback : 328 pages [ 235mm x 191mm ]
Release Date : June 2014
ISBN : 178398144X
ISBN 13 : 9781783981441
Author(s) : Alessandro Franceschi
Topics and Technologies : All Books, Networking and Servers, Open Source


Table of Contents

Preface
Chapter 1: Puppet Essentials
Chapter 2: Hiera
Chapter 3: PuppetDB
Chapter 4: Designing Puppet Architectures
Chapter 5: Using and Writing Reusable Modules
Chapter 6: Higher Abstraction Modules
Chapter 7: Deploying and Migrating Puppet
Chapter 8: Code Workflow Management
Chapter 9: Scaling Puppet Infrastructures
Chapter 10: Writing Puppet Plugins
Chapter 11: Beyond the System
Chapter 12: Future Puppet
Index
  • Chapter 1: Puppet Essentials
    • The Puppet ecosystem
      • Why configuration management matters
    • Puppet components
    • Installation and configuration
    • Puppet in action
      • Resources
        • The resource abstraction layer
      • Nodes
      • Classes and defines
        • Class inheritance
      • Resource defaults
      • Resource references
      • Variables, facts, and scopes
        • System's facts
        • User variables in Puppet DSL
        • User variables in an ENC
        • User variables in Hiera
        • Puppet's built-in variables
        • A variable's scope
      • Meta parameters
      • Managing order and dependencies
        • Run stages
      • Reserved names and allowed characters
      • Conditionals
      • Comparison operators
        • The In operator
        • Expressions combinations
      • Exported resources
        • Virtual resources
      • Modules
        • The paths of a module and autoloading
        • ERB templates
    • Summary
  • Chapter 2: Hiera
    • Installing and configuring Hiera
      • Global settings
      • Backend-specific settings
      • The hiera.yaml examples
    • Working with the command line on a YAML backend
    • Using Hiera in Puppet
      • Dealing with hashes in the Puppet code
      • Puppet 3 automatic parameter lookup
      • Evolving usage patterns for class parameters
    • Additional Hiera backends
      • The hiera-file backend
      • The hiera-gpg backend
      • The hiera-eyaml backend
      • The hiera-http and hiera-mysql backends
    • Using Hiera as an ENC
    • Summary
  • Chapter 3: PuppetDB
    • Installation and configuration
      • PuppetDB configurations
        • The init script configuration
        • Configuration settings
        • Logging configuration
      • Configurations on the Puppet Master
    • Dashboards
      • PuppetDB performance dashboard
      • Puppetboard – query PuppetDB from the Web
    • The PuppetDB API
      • Querying PuppetDB (Read)
      • The PuppetDB commands (Write)
    • Querying PuppetDB for fun and profit
      • The /facts endpoint
      • The /resources endpoint
      • The /nodes endpoint
      • The /catalogs endpoint
      • The /facts-names endpoint
      • The /metrics endpoint
      • The /reports endpoint
      • The /events endpoint
      • The /event-counts endpoint
      • The /aggregated-event-counts endpoint
      • The /server-time endpoint
      • The /version endpoint
    • The puppetdbquery module
      • Query format
        • Query from the command line
        • Query from Puppet manifests
        • The PuppetDB Hiera backend
    • How Puppet code may change in the future
    • Summary
  • Chapter 4: Designing Puppet Architectures
    • The components of Puppet architecture
      • Defining the classes to include in each node
      • Defining the parameters to use for each node
      • Defining the configuration files provided to the nodes
      • Defining custom resources and classes
    • The Foreman
    • Roles and profiles
    • The data and the code
    • Sample architectures
      • The default approach
      • Basic ENC, logic in the site module, and Hiera backend
      • The Foreman and Hiera
      • The Hiera-based setup
      • The Hiera-only setup
      • Foreman smart variables
      • Fact-driven truths
      • Nodeless site.pp
      • Node inheritance done right
    • Summary
  • Chapter 5: Using and Writing Reusable Modules
    • The evolution of modules' layouts
      • Class parameters – from zero to data bindings
      • The params pattern
      • Data in modules
      • Files and class names
      • The anchor pattern
    • The parameters dilemma
      • Naming standards
    • Reusability patterns
      • Managing files
        • Managing configuration hash patterns
        • Managing multiple configuration files
        • Managing users and dependencies
        • Managing the installation options
        • Managing extra resources
    • Summary
  • Chapter 6: Higher Abstraction Modules
    • Understanding the need for higher abstractions
    • The OpenStack example
      • Component (application) modules
      • Raising abstraction – the official openstack module
      • Raising abstraction – the Puppet Labs OpenStack module
      • Raising abstraction – the scenario-based approach
      • Taking an alternate approach
    • An approach to reusable stack modules
    • Summary
  • Chapter 7: Deploying and Migrating Puppet
    • Examining the potential scenarios and approaches
      • New infrastructures
      • Existing manually managed infrastructures
        • Node migration
        • Node update
      • Existing automated infrastructures
        • Upgrading the Puppet Master
    • Patterns for extending Puppet coverage
      • Raising the bar, step by step
      • Knowing the territory
      • Defining priorities
        • Automate servers deployment
        • Automate common configurations
        • Automate the most important roles
        • Refine and automate application deployments
        • Integrate what already works well
        • Automate monitoring
      • Evaluating solutions
      • Coding
      • Applying changes
    • Things change
      • Infrastructure as code
        • Versioning
        • Reproducibility and predictability
        • Testing
        • Maintenance
      • Evolution of the system administrator
      • Designing a Puppet-friendly infrastructure
    • Summary
  • Chapter 8: Code Workflow Management
    • Writing the Puppet code
      • Geppetto
      • Vim
    • Git workflows
      • Git's basic principles and commands
      • Git hooks
      • Environments and branches
        • Branch-based automatic environments
        • Simplified developer workdir environments
    • Code review
      • Gerrit
      • Online resources for peer review
    • Testing the Puppet code
      • Using rspec-puppet
      • rspec-system-puppet and Beaker
      • Vagrant
    • Deploying the Puppet code
      • Using librarian-puppet for deployments
      • Deploying code with r10k
    • Propagating Puppet changes
    • Puppet Continuous Integration tools
      • Travis
      • Jenkins
    • Summary
  • Chapter 9: Scaling Puppet Infrastructures
    • Scaling Puppet
      • As simple as puppet apply
      • Default Puppet Master
      • Puppet Master with Passenger
        • Installing and configuring Passenger
      • Multi-Master scaling
        • Managing certificates
        • Managing SSL termination
        • Managing code and data
      • Load balancing alternatives
      • Masterless Puppet
      • Configurations and infrastructure optimizations
        • Traffic compression
        • Caching
        • Distributing Puppet execution times
        • Checking the interval for changes in files
    • Scaling stored configs
    • Measuring performance
      • Puppet metrics
      • Optimizing code
      • Testing different Puppet versions
    • Summary
  • Chapter 10: Writing Puppet Plugins
    • Anatomy of a Puppet run, under the hood
      • ENC and Hiera extendibility
      • Modules' pluginsync
      • Puppet indirector and its termini
    • Custom functions
    • Custom facts
      • Ruby facts distributed via pluginsync
      • External facts in the facts.d directory
    • Custom types and providers
    • Custom report handlers
    • Custom faces
    • Summary
  • Chapter 11: Beyond the System
    • Puppet on a network equipment
      • A Proxy mode with the puppet device application
      • Native Puppet on the network equipment
        • Cisco onePK
        • Juniper and netdev_stdlib
    • Puppet for cloud and virtualization
      • VMware
        • VM provisioning on vCenter and vSphere
        • The integration of vCloud Automation Center
        • The configuration of vCenter
      • Amazon Web Services
        • Cloud provisioning on AWS
      • AWS provisioning and configuration with resource types
        • Managing CloudFormation
      • Cloud provisioning on Google Compute Engine
    • Puppet on storage devices
    • Summary
  • Chapter 12: Future Puppet
    • Introducing the future parser
      • Lambdas and Iterations
        • Manipulating and validating hashes and arrays
        • Other features
      • Restrictions and backward incompatibilities
      • Directory environments
      • Heredoc support
      • The new type system
    • Other new features
      • EPP Templates
      • The contain function
      • Serialization with MessagePack
    • Improved error system
    • Data in modules
    • Facter 2
    • Trapperkeeper
    • Summary

Alessandro Franceschi

Alessandro Franceschi is a freelance Puppet and DevOps consultant. Surviving IT battlegrounds since 1995, he has worked as an entrepreneur, web developer, trainer, and system and network administrator.
He has been using Puppet since 2007, automating a remarkable amount of customers' infrastructures of different sizes, natures, and complexities.

He has attended several PuppetConf and Puppet Camps as a speaker and participant, always enjoying the vibrant and friendly community, learning something new each time.

During the following years, he started to publish his Puppet code, trying to make it reusable in different scenarios.

The result of this work is the Example42 Puppet modules set, a widely used collection of modules based on reusability principles and with some optional, opinionated twists to automate firewalling, monitoring, systems' inventory, and application deployments.

For more information on Example42 modules, visit www.example42.com. His Twitter handle is @alvagante.

Sorry, we don't have any reviews for this title yet.

Code Downloads

Download the code and support files for this book.


Submit Errata

Please let us know if you have found any errors not listed on this list by completing our errata submission form. Our editors will check them and add them to this list. Thank you.

Sample chapters

You can view our sample chapters and prefaces of this title on PacktLib or download sample chapters in PDF format.

Frequently bought together

Extending Puppet +    Python High Performance Programming =
50% Off
the second eBook
Price for both: €18.40

Buy both these recommended eBooks together and get 50% off the cheapest eBook.

What you will learn from this book

  • Use Puppet to manage network, cloud, and virtualization devices
  • Become a Hiera and PuppetDB power user
  • Study the different approaches to Puppet architecture design
  • Master the art of writing and maintaining reusable modules
  • Explore strategies and patterns on how to introduce Puppet automation
  • Manage and test a Puppet code workflow
  • Design scalable Puppet infrastructures

In Detail

Puppet has changed the way we manage our systems, but Puppet itself is changing and evolving, as are the ways in which we use it.

A clear, updated, practical, and focused view of the current state of the technology and the evolution of Puppet is what we need to tackle our IT infrastructure challenges and avoid common errors when designing our architectures.

This is a detailed, practical book that covers the different components of the Puppet ecosystem and explores how to use them to deploy and manage different kinds of IT infrastructures.

Updated with the most recent trends and best practices, this book gives you a clear view on how to "connect the dots" and expands your understanding to successfully use and extend Puppet.

Approach

This book is a clear, detailed and practical guide to learn about designing and deploying you puppet architecture, with informative examples to highlight and explain concepts in a focused manner.

Who this book is for

This book is designed for users who already have good experience with Puppet, and will surprise experienced users with innovative topics that explore how to design, implement, adapt, and deploy a Puppet architecture. The key to extending Puppet is the development of types and providers, for which you must be familiar with Ruby.

Code Download and Errata
Packt Anytime, Anywhere
Register Books
Print Upgrades
eBook Downloads
Video Support
Contact Us
Awards Voting Nominations Previous Winners
Judges Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software
Resources
Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software