A bootstrap project to kickstart a Terraform AWS component.
This setup follows the Micro Stack pattern from Infrastructure as Code, 2nd Edition, p62. Every single infrastructure component of an application/service maps to a single stack.
Install Terraform.
Install tflint.
Install Trivy
AWS.
Assumes three environments:
development
test
production
Each environment has its own set of configurations ./environments/<env>.tfvar
.
Environments map to Terraform workspaces.
The Terraform state is stored in an S3 bucket.
Either a single S3 bucket for all workspaces (environments).
Or one S3 bucket per environment.
To apply a configuration:
make plan env=<env>
make apply
where <env>
is one of development
, test
or production
.