I'm struggling to find examples that do what I need

Ruby for DevOps and Automation Book by Thai Wood

You need how-to's with examples that you can trust.

We've all been there one time or another; spending countless hours between Google, Github, and Stack Overflow trying to find a resolution to your problem.

Assorted blog posts, gists and code snippets are OK for small issues and can definitely help save the day, but in the end do you have the mental framework to build and understand what you are doing?

Examples alone aren't enough

You need to know why something is done to gain a better understanding, but don't have the time to slow down and dig deep into all of the information.

You don’t have the time or need to learn a language from the ground up

You know you’re good at what you do, you don’t need to start at ground zero with everything. A 500 page wordy textbook is not going to help. You need to get up and running today with solutions that match real world problems. You need solutions now.

If you've done enough research, you know most of the examples are just that: examples.

The only examples you will find in this book are ones based on real problems. These are real issues I've solved or help others solved and I'm confident they will help you too.

You don’t have the time or need to learn a language from the ground up

Wouldn’t it be great if you could learn the core concepts?

When you become comfortable with the building blocks of Chef, have learned the key steps to automating SSH, and know how to visualize data you have, you'll have a solid foundation that you can build on to help you learn almost any form of automation or devops skill.

You know all too well what it feels like to comb forever through message boards for a solution.
If you're lucky, sometimes you'll find it, and while 'node[system][memory]' may help you solve your problem, it doesn't tell you anything about why your problem exists. The education piece is missing.

You don't need to learn Rails

If you've been trying to learn Ruby for any length of time then you know the frustration of finding tutorial after tutorial that has very little to do with Ruby, but in fact is all about Rails. None of that here

You keep hearing so many different things about DevOps. "It's a feeling!" "It's a culture" "DevOps Engineers aren't a real thing!"

Opinions are great, but none of this helps you make a move from someone who knows some code to someone who can use configuration management and automate processes.

Table of Contents

  • Chapter 1: An Intro to Chef
  • What is Chef?
  • Chef Overview
  • Getting Chef
  • Knife
  • Berkshelf
  • Test Kitchen
  • Setting up your development environment
  • Getting your first cookbook
  • From workstation to server
  • Setting up your first node
  • Attributes
  • Why use attributes?
  • Using attributes to change configuration
  • Grouping nodes
  • What is a role?
  • What is an environment?
  • Let's talk roles
  • Overriding an attribute with a role or an environment
  • Why not fork?
  • Creating your first cookbook
  • Creating our first recipe
  • Getting the chef-client to run on its own
  • Making it go
  • Wrapping up
  • Chapter 2: Cookbooks Deconstructed
  • Chapter 3: Writing Your Own Cookbooks From Scratch Using TDD
  • Review your tools
  • Test Kitchen
  • Berkshelf
  • Vagrant
  • Setting up your cookbook
  • Writing failing tests
  • Testing if the service is running
  • Testing if nginx is listening on the correct port
  • Testing our index.html file
  • Seeing the tests fail
  • A note about verify
  • Making the tests pass
  • Finding out what went wrong
  • Testing our updated recipe
  • Starting the service
  • Creating the index
  • Uploading the finished cookbook
  • Wrapping up
  • Chapter 4: Testing Away From Home: Virtual Machines With Vagrant
  • Getting Vagrant
  • Install VirtualBox
  • Your first Vagrant Machine
  • So what did you just do?
  • Managing boxes
  • More about the Vagrantfile
  • Vagrant and git or other source control
  • Checking under the hood
  • SSH
  • Sharing data between the guest and host
  • Vagrant configuration
  • Changing or adding shared folders
  • Networking
  • Private Networks
  • Public Networks
  • Multiple machines with Vagrant
  • Mix and match
  • Provisioning
  • Creating your own boxes
  • What is a box file?
  • Review
  • Chapter 5: Manage Your Application Dependencies With Bundler
  • Configuring Bundler with Gemfiles
  • Specifying Gem Vision
  • Gem Vision Operators
  • Using Bundler to get Gems
  • How to get gems
  • Using version control with Bundler
  • Specifying your Ruby version with Bundler
  • Deploying an application with Bundler
  • An example Bundler work flow
  • Chapter 5: Manage Your Application Dependencies With Bundler
  • Configuring Bundler with Gemfiles
  • Specifying Gem Version
  • Using Bundler to get Gems
  • Grouping dependencies
  • How to get gems
  • Using version control with Bundler
  • Specifying your Ruby version with Bundler
  • Deploying an Application with Bundler
  • An example Bundler work flow
  • Chapter 6: A Note About Knife SSH
  • Chapter 7: Automating SSH with SSHKit
  • Free space
  • Putting it all together (Or: The Story So Far)
  • 11 Accounting for errors
  • Putting it all together again
  • Review
  • Where to go from here
  • Chapter 8: Data Visualization
  • What kind of graphs?
  • I thought we were using Ruby
  • Installation
  • Let's do it
  • Parsing the data
  • Making the graph
  • Graph attributes
  • Different types of graphs
  • Neato
  • Neato, no overlap
  • SFDP
  • SFDP no overlap
  • Twopi
  • Twopi no overlap
  • Circo
  • Keeping it up to date
  • Summary
  • Chapter 9: Final Thoughts

Get Ruby for DevOps and Automation

PDF, Mobi, and Epub

This book will help you navigate the world of automation, DevOps, and its tools. Using real world examples and specific step-by-step instructions, you'll learn a hands on approach to increasing your automation skill set and save time.

Author Thai Wood

Hi, I’m Thai Wood.

I've been a developer and systems administrator for over 10 years. I've worked as many combinations of both under many titles for different people over the years, but I'm currently focusing on helping others move their projects and companies forward

Frequently asked questions:

Do you use DRM?
No! I want you to be able to read anywhere you choose on any device, that's why you'll receive the pdf, mobi, and epum all DRM free.

What if I don't like it?
Just email me! If the book isn't helping you learn more and grow your skills, just let me know.