Skip to content

Commit 9b0a1cb

Browse files
Create terraformDeploy.yml
1 parent fa881ba commit 9b0a1cb

File tree

1 file changed

+33
-0
lines changed

1 file changed

+33
-0
lines changed

.github/workflows/terraformDeploy.yml

+33
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
on:
2+
push:
3+
branches: [ "main" ]
4+
pull_request:
5+
branches: [ "main" ]
6+
7+
jobs:
8+
terraform:
9+
env:
10+
ARM_CLIENT_ID: ${{secrets.CLIENT_ID}}
11+
ARM_CLIENT_SECRET: ${{secrets.CLIENT_SECRET}}
12+
ARM_SUBSCRIPTION_ID: ${{secrets.SUBSCRIPTION_ID}}
13+
ARM_TENANT_ID: ${{secrets.TENANT_ID}}
14+
name: 'Terraform'
15+
runs-on: ubuntu-latest
16+
defaults:
17+
run:
18+
working-directory: ${{ github.workspace }}/cicd
19+
steps:
20+
- uses: actions/checkout@v2
21+
- uses: hashicorp/setup-terraform@v1
22+
23+
- name: Terraform init
24+
id: init
25+
run: terraform init
26+
27+
- name: Terraform validate
28+
id: validate
29+
run: terraform validate -no-color
30+
31+
- name: Terraform plan
32+
id: plan
33+
run: terraform plan -out plan.out

0 commit comments

Comments
 (0)