Skip to content

760 technical guidance migration #113

760 technical guidance migration

760 technical guidance migration #113

name: Delete review app
on:
pull_request:
branches:
- master
types:
- closed
jobs:
build-and-push:
runs-on: ubuntu-latest
concurrency: ci-${{ github.ref }}
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Set environment variables
run: |
SPACE=technical-architecture-dev
echo "SPACE=${SPACE}" >> $GITHUB_ENV
APP_NAME=dfe-technical-guidance-${{ github.event.number }}
echo "APP_NAME=${APP_NAME}" >> $GITHUB_ENV
- name: Configure Cloud Foundry CLI
uses: DFE-Digital/github-actions/setup-cf-cli@master
with:
CF_USERNAME: ${{ secrets.CF_USERNAME }}
CF_PASSWORD: ${{ secrets.CF_PASSWORD }}
CF_SPACE_NAME: ${{ env.SPACE }}
- name: Delete ${{ env.APP_NAME }}
run: cf delete -rf ${{ env.APP_NAME }}
- name: Post Pull Request Comment
if: ${{ github.event_name == 'pull_request' }}
uses: marocchino/sticky-pull-request-comment@v2
with:
message: Review app <https://${{ env.APP_NAME }}.london.cloudapps.digital> was deleted