From f39dffd57cb0a9b30837f0c4820211871b4e7fb5 Mon Sep 17 00:00:00 2001 From: Connor O'Kane Date: Wed, 3 Jul 2024 21:56:11 +0100 Subject: [PATCH] adding config + pipeline --- .github/workflows/pipeline.yaml | 28 ++++++++++++---------------- 1 file changed, 12 insertions(+), 16 deletions(-) diff --git a/.github/workflows/pipeline.yaml b/.github/workflows/pipeline.yaml index 67c92f017..6d3406f56 100644 --- a/.github/workflows/pipeline.yaml +++ b/.github/workflows/pipeline.yaml @@ -1,6 +1,5 @@ - name: Rule Sets Pipeline - + on: pull_request: branches: @@ -8,28 +7,25 @@ on: push: branches: - rule-sets-DTSPO-17918 - + permissions: id-token: write contents: read - + jobs: - build-and-deploy: - runs-on: ubuntu-latest - steps: + build-and-deploy: + runs-on: ubuntu-latest + steps: - name: 'Az CLI login' uses: azure/login@v1 with: - client-id: ${{ secrets.AZURE_CLIENT_ID }} - tenant-id: ${{ secrets.AZURE_TENANT_ID }} - subscription-id: ${{ secrets.DCD_CFT_SANDBOX_SUBSCRIPTION }} - + client-id: ${{ secrets.AZURE_CLIENT_ID }} + tenant-id: ${{ secrets.AZURE_TENANT_ID }} + subscription-id: ${{ secrets.DCD_CFT_SANDBOX_SUBSCRIPTION }} + - name: Setup Terraform uses: hashicorp/setup-terraform@v1 - - - name: Change directory to Terraform config - run: cd components - + - name: Initialize Terraform working-directory: components env: @@ -43,7 +39,7 @@ jobs: -backend-config="storage_account_name=rulesetsa" \ -backend-config="container_name=tfstate" \ -backend-config="key=terraform.tfstate" - + - name: Plan and Apply Terraform working-directory: components env: