Configure Terraform Remote Backend with GCS
In the "Code Editor" tab, open the main.tf
file.
Your task: Configure a Google Cloud Storage (GCS) bucket named tf-state-bucket
for Terraform remote state storage in us-central1
. Use a Cloud KMS key named tf-state-key
in a keyring named tf-state-keyring
for encryption. Set up the Terraform backend to use this GCS bucket with the KMS key for state encryption. Ensure the bucket is created with versioning enabled and uniform bucket-level access.
GitOps Repository
- 📁 /root/learn-terraform-gcs-backend
- 📄 provider.tf
- 📄 main.tf