Skip to content

Spike for batches

Spike for batches #79

name: Teardown
on:
pull_request:
types: [closed]
jobs:
build:
name: Call Azure Pipeline
runs-on: ubuntu-latest
steps:
- name: Get Access Token
id: get-access-token
run: |
echo "ACCESS_TOKEN"=$(curl -X POST -H "Content-Type: application/x-www-form-urlencoded" -d 'client_id=${{ secrets.PR_TEARDWN_SP_CLIENT_ID }}&scope=https%3A%2F%2Fapp.vssps.visualstudio.com%2F.default&client_secret=${{ secrets.PR_TEARDWN_SP_CLIENT_SECRET }}&grant_type=client_credentials' 'https://login.microsoftonline.com/${{ secrets.PR_TENANT_ID }}/oauth2/v2.0/token' | jq -r '.access_token') >> $GITHUB_OUTPUT
- name: Azure Pipelines Action
uses: Azure/[email protected]
with:
azure-devops-project-url: 'https://dev.azure.com/NHSD-APIM/API%20Platform'
azure-pipeline-name: 'immunisation-batch-pr-teardown'
azure-pipeline-variables: '{ "action_pr_number": "${{ github.event.pull_request.number }}" }'
azure-devops-token: ${{ steps.get-access-token.outputs.ACCESS_TOKEN }}