Design: Introduce version information for Terraform state
Problem to solve
Support versioning of the Terraform backend state for rollback or auditing purposes to drive the adoption of the GitLab Terraform offering.
User goals
IaC project maintainers need to have access to previous versions of a Terraform state both for compliance and occasional debugging needs.
JTBD
As a Software Developer, I need a way to see previous versions of my infrastructure state, so that I can debug and fix infrastructure changes.
As a Compliance Manager, I need a way to see previous versions of Terraform state files, so that I have evidence about the state of infrastructure in retrospect.
Intended users
- Cameron (Compliance Manager)
- Sasha (Software Developer)
- Devon (DevOps Engineer)
- Allison (Application Ops)
- Priyanka (Platform Engineer)
User experience goal
Provide an intuitive way to project maintainers to view the list of state file versions of a Terraform project. The users should be able to see the related git commits to the state file versions, number of resources created by the version and the Terraform version that the version was created by.
Proposal
Further details
Support for versioning of GitLab Managed Terraform states is provided from GitLab 13.4. Versioning is turned on automatically for new Terraform state files. Existing GitLab Managed Terraform state files will be migrated automatically to versioned storage in a later release.
https://docs.gitlab.com/ee/user/infrastructure/#gitlab-managed-terraform-state



