An automated trading platform engineering team is establishing an Infrastructure as Code (IaC) deployment pipeline for Google Cloud workloads across development, staging, and production environments using Terraform and Cloud Build. The security policy mandates least privilege execution, environment isolation, protection against concurrent state modifications, and strict state version auditability. Which deployment architecture should the cloud architect recommend?
- Provision dedicated Cloud Storage buckets per environment with Object Versioning enabled for remote backends, enforce state locking via Cloud Storage native locking mechanisms, and configure Cloud Build pipelines to impersonate environment-specific service accounts granted minimal predefined IAM roles.Cevap
- BStore state files locally within ephemeral Cloud Build execution containers during pipeline execution, and grant developers project Owner roles so they can manually fix resource provisioning errors via the Cloud Console if an apply step fails.
- CUse a single shared Cloud Storage bucket across all environments without Object Versioning or locking to simplify pipeline configuration, and execute Cloud Build pipelines using the default Project Editor role to avoid IAM permissions errors.
- DConfigure Terraform to maintain state in an unversioned single Cloud Storage bucket while allowing parallel pipeline steps to run without state locks to minimize CI/CD build execution time.
Cevap
Provision dedicated Cloud Storage buckets per environment with Object Versioning enabled for remote backends, enforce state locking via Cloud Storage native locking mechanisms, and configure Cloud Build pipelines to impersonate environment-specific service accounts granted minimal predefined IAM roles.
The correct approach enforces enterprise-grade Infrastructure as Code governance by isolating Terraform remote state backends into separate Cloud Storage buckets per environment, enabling state locking and object versioning to protect against state corruption, and scoping CI/CD pipeline access using dedicated service accounts with fine-grained predefined roles.
Adım Adım Çözüm
Anahtar Kavram
Enterprise IaC Governance with Terraform, Remote State Security, and Least Privilege CI/CD Execution
Tahmini Süre:2m 0s