From cc5e384b7d169ddee78d627aecc9d1a3806155bb Mon Sep 17 00:00:00 2001 From: Connor O'Kane Date: Wed, 3 Jul 2024 16:46:08 +0100 Subject: [PATCH] adding config + pipeline --- .github/workflows/pipeline.yaml | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/.github/workflows/pipeline.yaml b/.github/workflows/pipeline.yaml index ab83f0928..3a723ccdd 100644 --- a/.github/workflows/pipeline.yaml +++ b/.github/workflows/pipeline.yaml @@ -47,16 +47,24 @@ jobs: -backend-config="container_name=tfstate" \ -backend-config="key=terraform.tfstate" - - name: Plan and Apply Terraform + - name: Plan Terraform working-directory: components env: ARM_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }} ARM_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }} ARM_SUBSCRIPTION_ID: ${{ secrets.DCD_CFT_SANDBOX_SUBSCRIPTION }} ARM_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }} - GITHUB_TOKEN: ${{ secrets.PAT_TOKEN }} run: | terraform plan -out=tfplan \ -var="location=UK South" \ -var="override_action=plan" + + - name: Apply Terraform + working-directory: components + env: + ARM_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }} + ARM_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }} + ARM_SUBSCRIPTION_ID: ${{ secrets.DCD_CFT_SANDBOX_SUBSCRIPTION }} + ARM_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }} + run: | terraform apply -auto-approve tfplan