A complete overview of GitLab managed terraform state
<h1>What is GitLab CI/CD?</h1>
<p><strong>GitLab CI/CD</strong> is <strong>the part of GitLab </strong>that you use for all of the <strong>continuous methods (Continuous Integration, Delivery, and Deployment)</strong>. With <strong>GitLab CI/CD</strong>, you can <strong>test</strong>, <strong>build</strong>, and <strong>publish</strong> your code with no third-party application or integration needed.</p>
<p>Read more about <strong>GitLab CI/CD</strong> <a href="https://docs.gitlab.com/ee/ci/" rel="noopener ugc nofollow" target="_blank"><strong>here</strong></a>.</p>
<p><img alt="" src="https://miro.medium.com/v2/resize:fit:700/0*l-CaLcjI90WmzjyV.png" style="height:326px; width:700px" /></p>
<p>GitLab CI/CD</p>
<h1>What is GitLab managed terraform state?</h1>
<p>GitLab provides a built in <a href="https://docs.gitlab.cn/14.0/ee/user/infrastructure/terraform_state.html" rel="noopener ugc nofollow" target="_blank">Terraform state</a> feature, so instead of keeping the terraform state file in the local system or repository, you can store the state file in GitLab and can be referenced while performing various terraform operation using GitLab pipeline.</p>
<p>The terraform file<strong> <em>terraform.tfstate </em></strong>stores the state of your infrastructure provisioned on the cloud platform by terraform, and if you lose it means that Terraform would not know the status of your current infrastructure on the cloud platform. This file can be stored to a remote Git repo for sharing, but it is not a good practice because the state file could easily get out of sync if it is not handled carefully.</p>
<p><a href="https://medium.com/@dksoni4530/a-complete-overview-of-gitlab-managed-terraform-state-b30114f84c27"><strong>Click Here</strong></a></p>