DEV Community

drewmullen
drewmullen

Posted on

Implement Rollback with Terraform

There's no magic here, friends.

$ terraform apply # fails
$ git checkout HEAD~ # checkout the prior commit
$ terraform apply 
Enter fullscreen mode Exit fullscreen mode

You can checkout a specific commit sha with:
git checkout <commit sha>

I don't recommend using this with any stateful resource types... RDS, EKS, etc.

Top comments (0)