Installing Puppet is easy. Designing an infrastructure that you're still be happy with in 2 years requires lots of experience.
The Manageable Puppet Infrastructure is a very flexible design that has been field-tested in many companies, varying from very small to very large. The author of this course did talks about the MPI and related subjects at PuppetConf 2014 and 2015, PuppetCamps, FOSDEM and other conferences.
This course is a very practical guide on howto setup your Puppet infrastructure, while teaching you how it works and why.
Please note that this course REQUIRES pre-existing Puppet knowledge. This is advanced-level stuff, the basics are not explained in this course due to time-constraints.
The end-result of following this course is a fully functional, production-ready Manageable Puppet Infrastructure!
In this lecture we will discuss what you need to get started with this course.
There are several options available to use as a puppetmaster:
What are the pro's and con's? Which option is best for you?
We set up a temporary development environment in order to do some initial setup and talk about where Puppet looks for modules on the filesystem.
Now that we have created a temporary environment, let's see if it actually works!
The Puppetforge has many modules available; how can we distinguish the great ones from the awful ones?
Install some modules from the PuppetForge to configure the Puppet Master.
Configuring the Puppetmaster using Forge modules.
We have configured the PuppetDB with a module, now let's see if it works!
It's nice that the puppetserver process listens to a port, but if the outside world cannot reach it....
Let's open up that firewall.
Later in the course we will update our profile to do this properly.
What type of machine will we setup for testing? There are multiple options, as long as we can break them whenever we feel like it.
In this course, we're going to use Vagrant boxes for testing machines.
You can easily generate a Vagrant file. To save you some time, I have already prepared one.
We don't want to create new certificates anytime we start afresh with our Vagrant boxes. Therefore, let's generate, sign and save some certificates!
Let's see where we are so far!
Roles and Profiles are a widely used design pattern that is extremely helpful in your Puppet environment. Here is an overview!
Allright, now that we know what they are, why do we want to use 'em?
Just a few questions on Roles and Profiles.
Version control is essential for any type of code, not only Puppet. Using code review is also very helpful, but not for the obvious reasons.
Let's use the clear instructions on the site to install GitLab CE.
The last step of installing gitlab is reconfiguring it.
What is R10K? We will take a close look at how R10K can help you manage your environments.
In this lecture we will create our control Repository. R10K needs this to manage our puppet environments.
R10K manages our environments, but it needs to know which modules you want. For this, we are going to create the Puppetfile.
Installing R10K is pretty simple. However, we want to make it reproducible, so we will use a module for this task.
Now that we have set up R10K, we can do a test run to deploy our first environment.
Working with different branches is a lot easier if we can see which branch we are on at all times. For this, we will install a Bash plugin.
We need to create several environments to make sure that we can properly test our code before we put it into production. R10K will help us to manage those environments
This lesson explains the different environments we will create and their users.
We will create two new branches, based on the master branch. We will call this integration and testing so that R10K will create environments with the same name.
Often we have many people that contribute code to Puppet and only a few who fully understand the entire infrastructure.
We want to make sure that only the people that are allowed to push pop of color all the way up to production can update the corresponding branches of the control Repository.
To achieve this, we can protect the new branches of our Git Repository.
Let's see what you have learned about R10k... :)
In this lecture we will install a script to easily create development environments.
What does the script do?
It is very difficult to make multiple Puppet developers use Git in the same way, unless you have very good guidelines. Git flow is such a set of guidelines, in this lecture we will get introduced to it.
Unfortunately, there is no package for the git-flow subcommand (git flow) in the Yum repositories. We will install git flow manually.
We will need to provide access to the Git repositories. For this, we will create a private and public key that we will authorize in the Gitlab web interface
After that has been taken care of, we can run the script and set up our personal playground environment.
There are a few steps required after setting up the dev-environment, like setting up git-flow for the control repo.
The Puppet Master needs access to the development environment we just created.
A complication is that the development environment is in the home directory of each developer.
Create a new symlinks after each ‘r10k deploy environment’ command is not very practical. Therefore, we will install a script that does this for us automatically.
We are dealing with several GIT repos.
It's very hard to keep track of what repos have uncommitted changes, so let's install a script that can help out.
Introduction to module release numbers and how to use them in the Puppetfile.
The Puppetforge is an extremely valuable resource. We will take a look at how to separate the good modules from the awful ones and why you do want to use these modules instead of writing everything yourself.
Ger is a Freelance Puppet consultant and teaches the official courses for Puppet in the Netherlands.
He just loves to explain stuff, both in the classroom and over the internet.
As a consultant, he has helped many companies to implement Puppet, both Open Source and Puppet Enterprise. Ger has done many talks about Puppet Infrastructure related topics at PuppetConf, PuppetCamps, FOSDEM and other conferences.