A connected vehicle telemetry enterprise provisions its multi-region Google Cloud resources across multiple projects using Terraform managed by an automated CI/CD pipeline. The security and governance teams require that infrastructure state files are securely locked against concurrent writes and protected against state corruption, while CI/CD execution avoids using long-lived service account security keys. Additionally, the team must ensure that out-of-band manual changes are automatically identified before breaking deployment pipelines. Which TWO practices should the lead cloud architect implement to meet these requirements?
- Configure a remote Google Cloud Storage (GCS) backend with Object Versioning enabled and utilize Workload Identity Federation for CI/CD pipeline authentication.Cevap
- BStore Terraform state files within the local filesystem of the CI/CD runner host and encrypt the state directory using Customer-Managed Encryption Keys (CMEK).
- CGrant the primitive Project Owner role to the pipeline service account to prevent permission errors across projects without rotating keys.
- Implement automated, scheduled terraform plan executions in the CI/CD pipeline to continuously evaluate real-world infrastructure against the target state configuration.Cevap
- EApply critical infrastructure fixes directly through the Google Cloud Console during emergency incidents without updating state files to save time.
Cevap
The correct architecture requires configuring a remote Cloud Storage backend with Object Versioning combined with Workload Identity Federation for keyless authentication, alongside implementing automated scheduled terraform plan executions to detect infrastructure drift.
Configuring a Cloud Storage backend with versioning ensures robust remote state management with state locking and disaster recovery, while Workload Identity Federation allows external CI/CD runners to securely authenticate to GCP without managing persistent service account keys. Coupling this with automated scheduled terraform plan pipelines ensures that configuration drift caused by manual changes is promptly identified.
Adım Adım Çözüm
Anahtar Kavram
Terraform Remote Backend Security, Keyless CI/CD Authentication, and Automated Drift Detection
Tahmini Süre:2m 0s