Last active
September 20, 2017 20:49
-
-
Save undeadops/7b02f8550d3a0452f524632edfa019bd to your computer and use it in GitHub Desktop.
Terraform circleci.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
dependencies: | |
cache_directories: | |
- terraform_0.6.16 | |
pre: | |
- mkdir -p terraform_0.6.16 | |
- wget -O terraform_0.6.16/terraform_0.6.16_linux_amd64.zip https://releases.hashicorp.com/terraform/0.6.16/terraform_0.6.16_linux_amd64.zip | |
- unzip terraform_0.6.16/terraform_0.6.16_linux_amd64.zip | |
test: | |
override: | |
- ./terraform remote config --backend=S3 --backend-config="bucket=$BUCKET" --backend-config="key=terraform.tfstate" --backend-config="region=us-east-1" | |
- ./terraform plan --out=terraform.plan | |
deployment: | |
production: | |
branch: master | |
commands: | |
- ./terraform apply terraform.plan | |
- ./terraform remote push |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment