SPA Conference session: Master of puppet(s) - Configuration management for developers, hands-on.
|One-line description:||Experience automating systems administration for fun and profit|
|Session format:||Tutorial (150 mins) [read about the different session types]|
|Abstract:||Inspired by the devops movement and a new breed of configuration management tools, we decided to be devops for a while. Learn from our success and failures, and get your hands clean with puppet, the configuration scripting tool that we used.|
Many of us already love continuous integration. Configuration management takes this a step further by allowing you to continuosly build complete servers, including but not limited to deploying your software. For instance we've automated installation of webserver and mailserver software, as well as compilation and configuration of a not very common object oriented database system, so that we can easily recreate a server in case of failure or growth...
This is aimed at agile/BDD/TDD teams, but could be used for the more "traditional" approaches too. We started with puppet, without BDD, and found that at some point the complexity is enough to warrant tests. As bonus, if your client is available, you can prioritize and check sysadmin work by business value.
Bring your laptop, and work with a pair through some exercises we've prepared. Take home a (virtual) machine and git repository with scripts that got you started, so you can continue what you learnt.
|Audience background:||Developers, anybody who is not afraid of a command line, a text editor and distributed version control.|
|Benefits of participating:||Recover quicker from disaster, scale up with grace when success strikes.|
Configuration management, like TDD & BDD takes some time to learn, but saves you a lot of time and frustration. Understand why your servers (or desktops) work the way they do, and document that understanding in executable form.
Don't make the same mistakes we did, and benefit from what we did well.
Learn how to create virtual machines on the fly reliably and repeatably, how to apply Behavior Driven Development to systems administration, and how to debug your configurations when something does not work as expected.
Learn new tools: puppet to automate configurations, vagrant to instantiate virtual machines on the fly and cucumber to let business needs drive server behaviour.
|Materials provided:||- virtual machine or usb stick to get running quickly|
- slide presentation documenting benefits, our experience and intro to exercises
- step-by-step instructions for exercises
|Process:||presentation, exercises, some group working in the wrap-up|
|Detailed timetable:||00:00 introduction, agenda & benefits|
00:10 presentation: what is devops, what is cm, what is puppet, how can you go about getting the benefits.
00:25 live coding (prepared kata), demonstrate quick and repeatable installation of jenkins (formerly known as hudson) continuous integration server driven by behaviour (BDD with prepared cucumber features, the kata will mostly 'fill in the blanks' in the implementation).
00:60 hands-on exercise: installing apache as a front-end for jenkins. (introducing how to manage & install packages, custom files and how to turn arcane knowledge into executable documentation. ). We prepare cucumber Features & specs, participants make them pass one by one by creating a puppet recipe (some building blocks like configuration files provided).
1:30 live demo (prepared kata with explanation of concepts): BDD for systems administration with cucumber and puppet. Here we write a new feature and define behaviour for a partially existant configuration.
2:00 hands-on exercise: BDD - write a feature and its steps in cucumber, see it fail, turn on a recipe and see it pass (probably a small configuration item with big impact like a solid SSH or IPTables firewall configuration. Will provide building blocks for steps such as nmap port scanner or ruby ssh package, and we provide most of the recipe so participants can focus on BDD).
2:25 wrap-up : what will you try out at work after the conference? (with post-its to be stuck on poster when leaving).
|Outputs:||- blog post|
|History:||We ran the presentation part of this at Fosdem 2011 in Brussels, was fairly well received, inspired a few people to give puppet or chef a try in their place of work.|
|1. Willem van den Ende
Living Software B.V.
|2. Stephan Eggermont