micropost-formation
August 21, 2017 ยท View on GitHub
Core components
- AWS VPC
- AWS ECS with ALB and AutoScaling
- AWS RDS
- Cloudflare DNS and CDN
Dependencies
- Terraform
- AWS CLI
- direnv
Getting started
Configure settings.
$ cp .envrc.example .envrc
$ vi .envrc
$ direnv allow
Init
$ export ENV=stg
$ source ./scripts/switch-role.sh
$ terraform init
$ terraform get
$ terraform workspace select ${ENV}
Plan and Apply
$ ./terraform-env.sh stg plan
$ ./terraform-env.sh stg apply