Skip to content

Rollbacks

In the world of infrastructure as code, mistakes or unintended consequences can sometimes occur when applying changes to your infrastructure. When this happens, it’s essential to have a reliable and efficient way to roll back those changes and restore your infrastructure to a previous stable state. While Terrateam doesn’t have a dedicated rollback feature, you can easily perform rollbacks by leveraging GitHub’s pull request functionality and Terrateam’s plan and apply workflows.

Understanding rollbacks

A rollback is the process of reverting changes made to your infrastructure and returning it to a previous known-good state. In the context of Terrateam and Terraform, a rollback typically involves the following steps:

1. Identifying the pull request that introduced the undesired changes.

2. Reverting the changes made in that pull request.

3. Creating a new pull request with the reverted changes.

4. Running a Terrateam plan to review the impact of the rollback.

5. Applying the rollback changes using Terrateam.

By following these steps, you can effectively undo the changes made by a previous pull request and restore your infrastructure to its previous state.

Best practices

To ensure smooth and effective rollbacks with Terrateam, consider the following best practices:

  • Regularly review and test your Terraform code changes before merging them into your main branch. This helps catch potential issues early and reduces the likelihood of needing a rollback.
  • Use descriptive and meaningful titles and descriptions for your pull requests, making it easier to identify and track changes over time.
  • Use version control best practices, such as branching and tagging, to maintain a clear history of your infrastructure changes and facilitate rollbacks.
We use cookies and similar technologies to provide certain features, enhance the user experience and deliver content that is relevant to your interests. Depending on their purpose, analysis and marketing cookies may be used in addition to technically necessary cookies. By clicking on "Agree and continue", you declare your consent to the use of the aforementioned cookies. Here you can make detailed settings or revoke your consent (in part if necessary) with effect for the future. For further information, please refer to our Privacy Policy .