Jess Ross Jess Ross October 16, 2019

Introducing Runbooks for your Operations Team

Illustration showing books running (i.e., Runbooks) through a server room

Deployments are only one stage in the life of an application. There are many other common tasks that need to be performed to keep applications operating smoothly. A big part of DevOps is development and operations teams working together, and Octopus seems like the perfect tool to use, given it already knows about your infrastructure, accounts, and project configuration.

DevOps Lifecycle and where Octopus fit

If we take the Octopus Deploy website, Octopus.com, as an example, we use Octopus to deploy our website and manage our infrastructure, variables, certificate, and accounts. But we also have some routine and emergency tasks we do as part of operating the website. For instance, backing up the database, restoring it, testing the restore, removing PII from the database, and restoring the sanitized database to a test environment as well as failing over to a disaster recovery site.

Currently, these tasks are in one project’s deployment process, or they’re executed as separate scripts. Performing all these steps for a deployment doesn’t make sense, and doing a deployment just to backup a database doesn’t make sense either.

Operations Runbooks allows us to simplify the deployment process and enable the operational tasks to be run at different intervals to the deployment. Our list of Runbooks is:

  1. Failover to the disaster recovery site.
  2. Switch back to the primary production site.
  3. Back up the database (and test the restore worked).
  4. Refresh the test database with (sanitized) production data.

With Runbooks, the overview and task lists show us the exact operations and their runs performed separately, giving us a true picture of the state of our website.

Operations Runbooks in Octopus Deploy

Operations Runbooks can be accessed from within a project. This means you can keep everything related to running an application together. If you have operational tasks that apply to your infrastructure only and are not necessarily related to an application, like cleaning up files on machines, we suggest you create a separate project for these types of operations.

In the project menu, everything related to deployments is under a new Deployments menu-item. Runbooks are under the Operations menu, and you can expect to see this section grow as we add new Operations in the future. Resources that can be shared between Deployments and Operations are outside of these areas.

Screenshot showing the new menu structure within a project

Creating and running a Runbook

Adding a Runbook can be done from the Operations ➜ Runbooks section, and adding steps to a Runbook works the same as adding steps to a Deployment Process.

If you have operational steps within a Deployment Process, these can be cloned into a Runbook.

Screenshot of the Runbooks screen

When Runbooks run, a snapshot is created at the time of the run, making it quicker to perform operations. We didn’t design Runbooks to rely on lifecycles, so you can run a Runbook on any environment as long as you have the permission.

Animated gif of a Runbook being run

Cloning steps

If you have steps in your deployment process that are more suited to a Runbook, you can clone the step to your Runbook.

New permissions

You can enable or restrict users from running Runbooks with the new permissions RunbookView and RunbookEdit (for creating, editing, and deleting). Runbooks re-uses the existing ProcessEdit, Deployment, and Release permissions for runs and snapshots.

Operations Runbooks early access

We’ve shipped Runbooks as an early access feature in Octopus 2019.10, and we encourage you to try Runbooks for any processes that aren’t application specific.

Our goal with the early access program is to get feedback and validate its design. There are some limitations with Variables, Triggers, and other areas within the EAP, but the Runbooks documentation provides all the details you need to get started as well as the current limitations.

We’d love feedback, so join the discussion on our community slack in the #runbooks channel. You can also register for updates on our public roadmap page.

Conclusion

We’re excited to share this first release of Operations Runbooks and to see how teams use it in their projects.

Product

Welcome! We use cookies and data about how you use our website allow us to improve the website and your experience, and resolve technical errors. Our website uses cookies and shares some of your data with third party analytics companies for these purposes.

If you decline, we will respect your privacy. A single cookie will be used in your browser to remember your preference.