Add terraform fmt check
This commit is contained in:
@@ -1,5 +1,16 @@
|
|||||||
version: 2
|
version: 2
|
||||||
jobs:
|
jobs:
|
||||||
|
verify:
|
||||||
|
docker:
|
||||||
|
- image: circleci/golang:latest
|
||||||
|
steps:
|
||||||
|
- checkout
|
||||||
|
- run: wget -O terraform.zip https://releases.hashicorp.com/terraform/0.11.7/terraform_0.11.7_linux_amd64.zip
|
||||||
|
- run: unzip terraform.zip
|
||||||
|
- run: sudo mv terraform /usr/local/bin/terraform
|
||||||
|
- run: for dir in $(find . -name \*.tf -exec dirname {} \; | sort | uniq); do echo ${dir} && terraform validate -check-variables=false
|
||||||
|
${dir}; done
|
||||||
|
- run: terraform fmt -check
|
||||||
hold:
|
hold:
|
||||||
machine: true
|
machine: true
|
||||||
steps:
|
steps:
|
||||||
@@ -139,7 +150,10 @@ workflows:
|
|||||||
version: 2
|
version: 2
|
||||||
workflow:
|
workflow:
|
||||||
jobs:
|
jobs:
|
||||||
|
- verify
|
||||||
- hold:
|
- hold:
|
||||||
|
requires:
|
||||||
|
- verify
|
||||||
type: approval
|
type: approval
|
||||||
filters:
|
filters:
|
||||||
branches:
|
branches:
|
||||||
|
|||||||
Reference in New Issue
Block a user