
Enjoy fast, free delivery, exclusive deals, and award-winning movies & TV shows with Prime
Try Prime
and start saving today with fast, free delivery
Amazon Prime includes:
Fast, FREE Delivery is available to Prime members. To join, select "Try Amazon Prime and start saving today with Fast, FREE Delivery" below the Add to Cart button.
Amazon Prime members enjoy:- Cardmembers earn 5% Back at Amazon.com with a Prime Credit Card.
- Unlimited Free Two-Day Delivery
- Streaming of thousands of movies and TV shows with limited ads on Prime Video.
- A Kindle book to borrow for free each month - with no due dates
- Listen to over 2 million songs and hundreds of playlists
- Unlimited photo storage with anywhere access
Important: Your credit card will NOT be charged when you start your free trial or if you cancel during the trial period. If you're happy with Amazon Prime, do nothing. At the end of the free trial, your membership will automatically upgrade to a monthly membership.
Buy new:
$30.00$30.00
Ships from: Amazon.com Sold by: Amazon.com
Save with Used - Good
$5.99$5.99
Ships from: St Vinnie's Charitable Books Sold by: St Vinnie's Charitable Books

Download the free Kindle app and start reading Kindle books instantly on your smartphone, tablet, or computer - no Kindle device required.
Read instantly on your browser with Kindle for Web.
Using your mobile phone camera - scan the code below and download the Kindle app.
Follow the author
OK
Deploying Rails: Automate, Deploy, Scale, Maintain, and Sleep at Night (The Facets of Ruby) 1st Edition
Purchase options and add-ons
Today's modern Rails applications have lots of moving parts. Make sure your next production deployment goes smoothly with this hands-on book, which guides you through the entire production process. You'll set up scripts to install and configure all the software your servers need, including your application code. Once you're in production, you'll learn how to set up systems to monitor your application's health, gather metrics so you can stop problems before they start, and fix things when they go wrong.
Deploying Rails takes you on a expertly guided tour of the current best practices in Rails deployment and management. You'll find in-depth explanations on effectively running a Rails app by leveraging popular open source tools such as Puppet, Capistrano, and Vagrant. Then you'll go beyond deployment and learn how to use Ganglia and Nagios to monitor your application's health and gather metrics so you can head off problems before they happen.
You'll start out by building your own virtual environment by writing scripts to provision a production server with Vagrant and Puppet. Then you'll leverage the popular Rails deployment tool Capistrano to deploy an application into this infrastructure. Once the app is live, you'll monitor your application's health with Nagios, and configure Ganglia to collect system metrics. Finally, you'll see how to keep your data backed up, recover data when things go wrong, tame your log files, and use Puppet to automate everything along the way.
Whether you're a Rails developer who wants a better understanding of the needs of a production Rails system, if you're a system administrator who wants to manage a Rails application, or if you're bridging the gap between development and operations, this book will be your roadmap to successful production deployment and maintenance, whether your application has ten users or ten million users.
What You Need:
The exercises and examples are most suited to a computer running some Unix variant, such as Mac OS X or Linux. But a Windows machine running Linux in a VirtualBox virtual machine is also sufficient.
We'll show you how to set up a local virtual machine for your deployments; you won't need a dedicated server to hone your deployment skills. We expect you to have a basic familiarity with the Ruby programming language, the Ruby on Rails framework, and the Unix command line.
- ISBN-101934356956
- ISBN-13978-1934356951
- Edition1st
- PublisherPragmatic Bookshelf
- Publication dateJanuary 1, 2012
- LanguageEnglish
- Dimensions7.5 x 0.75 x 9.25 inches
- Print length217 pages
Editorial Reviews
About the Author
Tom Copeland is also a Rails developer at LivingSocial. He has programmed in Ruby since 2004, consulted at InfoEther on Ruby on Rails applications since 2007, and received a "Ruby Hero" award in 2008. Before focusing on Ruby, he wrote two books on Java programming ("PMD Applied" and "Generating Parsers with JavaCC") and was named Oracle's "Open Source Developer of the Year" in 2003.
Anthony Burns is a professional Ruby and Rails developer at LivingSocial. Prior to LivingSocial, he worked at InfoEther, a Rails consultancy, where he handled deployment and infrastructure for various clients.
Product details
- Publisher : Pragmatic Bookshelf; 1st edition (January 1, 2012)
- Language : English
- Paperback : 217 pages
- ISBN-10 : 1934356956
- ISBN-13 : 978-1934356951
- Item Weight : 1.06 pounds
- Dimensions : 7.5 x 0.75 x 9.25 inches
- Best Sellers Rank: #5,158,964 in Books (See Top 100 in Books)
- #185 in Ruby Programming
- #1,782 in Object-Oriented Design
- #2,001 in Software Design & Engineering
- Customer Reviews:
About the author

Discover more of the author’s books, see similar authors, read book recommendations and more.
Customer reviews
Customer Reviews, including Product Star Ratings help customers to learn more about the product and decide whether it is the right product for them.
To calculate the overall star rating and percentage breakdown by star, we don’t use a simple average. Instead, our system considers things like how recent a review is and if the reviewer bought the item on Amazon. It also analyzed reviews to verify trustworthiness.
Learn more how customers reviews work on AmazonTop reviews from the United States
There was a problem filtering reviews. Please reload the page.
- Reviewed in the United States on August 6, 2014This book takes you all the way except actually deploying. It gives you the code to do one specific type of deploy in a VM container. Some of the details of what you actually need to do when deploying to a real host are left out so you basically end up using this as a reference if you really want to use Puppet, Nagios, Ganglia, Monit, and a few other specific choices.
- Reviewed in the United States on November 22, 2015I enjoyed the various Chapters on Ganglia, Capistrano, Vagrant, Capistrano.
- Reviewed in the United States on August 25, 2012"Deploying Rails" is more than just about deploying a Rails application, it's about that and everything that goes into managing servers, from provisioning to monitoring. This book explains how to do these tasks with the help of some popular Open Source tools and a focus on automation.
The flow of the book is fairly logical. Start by building virtual machines with Vagrant. Learn how to automate configuration with Puppet. Nail down deployment and remote tasks with Capistrano. Monitor the server and application with Nagios and Ganglia. Delve into some side topics like systems administration. Even though there is ample free documentation on all of these topics, this book sets itself apart in two ways.
First is that the tools from previous chapters are used to augment later chapters. You'll learn how to use Vagrant to set up a virtual machine in the first chapter, and from them on when you need a server you'll configure a Vagrant box. You'll learn how to automate configuration management with Puppet in the second chapter, and all successive chapters build on that. You don't simply install Nagios, you write Puppet scripts that install Nagios for you. By the end of the book you have a collection of tools that you can start using in your own real world environment.
Secondly, you're doing everything on an environment you can build yourself without needing to know how to install Linux, owning spare servers, or knowing how to manage servers. You just install Vagrant and follow the book. The book is heavy on code samples and screen captures -- it is the exception to open up to a random page and not see some code or example. You can have a replicated MySQL setup and work on your database recovery practices, destroy it, and know you can rebuild it with a few keystrokes.
Puppet is a large part of this book. Almost every task is done in a Puppet manifest, from installing the web server to setting up monitoring. The authors walk you through creating couple of simple manifests and then refactoring the code to be more reusable. The basics of Puppet are covered such as installing packages, starting services, and copying files. Later on Puppet is used to interact with the existing system by managing cron jobs and using templates to edit existing configuration files.
The popular deployment suite, Capistrano, is the topic of two chapters. The first looks at a simple deployment, then goes on to examine roles and adding hooks that automate tasks at points during the deployment. The advanced chapter delves into remote command invocation and parsing, multistage deployments (such as a separate staging and production deployment) and further automation of the deployment. People who have used Capistrano before will not be surprised by much in the basic chapter, but are almost certain to find something helpful in the advanced chapter. It opened my eyes to what Capistrano can do outside of the deployment -- it can automate maintenance and support tasks, too.
The last three chapters discuss various topics, from managing multiple Ruby interpreters with RVM to backing up your database and how to manage a master-slave setup. Some of these topics can be books in themselves, though Deploying Rails does a good job at getting you started. Even though the examples throughout the book use Apache and Phusion Passenger, the appendixes have a chapter on using Nginx and Unicorn.
Despite all the remarkable content, I did feel there were some areas that could have been covered. Given the extensive use of Vagrant throughout the book I found it surprising there was no discussion about using it for its intended purpose of managing developer's environments. There's a brief mention that Vagrant can run the Puppet scripts and you can save the step of running it manually, but other than that I found little that would tell the reader that they could reuse the work they had been doing so that all the developers would have a production like environment in which to work. Similarily, since the environment is well defined the authors were able to make several assumptions in their coniguration that would not necessarily work in a typical production environment. Some of these are simple, such as IP addresses and SSH keys being hard coded, but some are more involved, such as how to distribute the Puppet manifests when that's not taken care of by Vagrant. Books, like software, have to draw the line somewhere though.
As a systems administrator turned developer I was encouraged to see this book being released. It shows the ideal marriage of the systems administration mindset, with its relentless focus on automation and monitoring, with the tools available to the modern programmer. In some circles this practice is called DevOps, but even in shops that keep these two separate, this book will benefit both teams.