- Home
- DevOps & Infrastructure
- Terraform
Terraform
Infrastructure as Code (IaC) guidelines and conventions.
At Zoos Global, all infrastructure resources are defined and managed as code using Terraform.
Repository Layout
Section titled “Repository Layout”Our infrastructure repositories follow a multi-environment layout:
infra-provisioning/├── modules/│ ├── ecs-service/│ ├── database/│ └── networking/├── environments/│ ├── dev/│ │ ├── main.tf│ │ ├── variables.tf│ │ └── outputs.tf│ ├── staging/│ └── prod/State Management
Section titled “State Management”- Terraform state is stored remotely in Amazon S3 buckets with versioning enabled.
- State locking is enforced using DynamoDB tables.
- Never commit
.tfstatefiles to git. Our.gitignorestrictly blocks them.
Best Practices
Section titled “Best Practices”- Variables and Outputs: Always document variables and outputs using
descriptionfields. - Resource Tagging: All resource blocks must include standard resource tags:
tags = {Environment = var.environmentProject = "zoosglobal"ManagedBy = "terraform"}
- Format and Lint: Format all Terraform code using
terraform fmt -recursivebefore committing.

