Member-only story
Terraform Cloud — Migrating From Local to Terraform Cloud
Note, full mind map is available at: “DevOps in Terraform MindMap”
In my previous Terraform article: “Terraform Cloud — Introduction”, I talked about what Terraform cloud is. it key features and why you should use it. In this article, let’s talk about how to migrate from Terraform local to Terraform cloud.
High Level Steps
High-level steps include:
- Create a Terraform Cloud Account: Visit the Terraform Cloud website and sign up for an account if you don’t already have one.
- Create a New Workspace: In the Terraform Cloud interface, create a new workspace that will represent your infrastructure environment.
- Connect Version Control System (VCS): Connect your Version Control System (like GitHub, GitLab, Bitbucket) with your Terraform Cloud workspace. This allows Terraform Cloud to access your infrastructure code.
- Update Backend Configuration: In your Terraform configuration, change the backend to “remote” and specify the organization and workspace name that you created in Terraform Cloud. This change tells Terraform to store its state in Terraform Cloud instead of locally.