From d5d90bc959c45bbb7310a288ee20ad863efad59b Mon Sep 17 00:00:00 2001 From: VinneyJ Date: Tue, 18 Jun 2024 11:08:45 +0300 Subject: [PATCH 1/2] fix: destroy test review app --- .github/workflows/codeforafrica-deploy-review-app.yml | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/.github/workflows/codeforafrica-deploy-review-app.yml b/.github/workflows/codeforafrica-deploy-review-app.yml index 5e96193c2..41553a83e 100644 --- a/.github/workflows/codeforafrica-deploy-review-app.yml +++ b/.github/workflows/codeforafrica-deploy-review-app.yml @@ -86,17 +86,14 @@ jobs: |-------|--------| | ${{ env.APP_NAME }} | [Visit](https://${{ env.APP_NAME }}.dev.codeforafrica.org) | - destroy_review_app: + destroy_review_app4: runs-on: ubuntu-latest - # only run when a pull request is closed - if: github.event.action == 'closed' + if: github.event_name == 'pull_request' && github.event.action == 'closed' steps: - - name: Destroy the review app + - name: Destroy review app uses: dokku/github-action@master with: - # destroy a review app command: review-apps:destroy - git_remote_url: ${{ env.DOKKU_REMOTE_URL }}/${{ env.APP_NAME }} - # specify a name for the review app + git_remote_url: ${{ env.DOKKU_REMOTE_URL }}/codeforafrica-ui review_app_name: ${{ env.APP_NAME }} ssh_private_key: ${{ secrets.SSH_PRIVATE_KEY }} From d4b6b423ba5ee6064d8f0eb79a35595f689ef0d1 Mon Sep 17 00:00:00 2001 From: VinneyJ Date: Tue, 18 Jun 2024 13:19:13 +0300 Subject: [PATCH 2/2] fix: minor typo --- .github/workflows/codeforafrica-deploy-review-app.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/codeforafrica-deploy-review-app.yml b/.github/workflows/codeforafrica-deploy-review-app.yml index 41553a83e..8304d9f2c 100644 --- a/.github/workflows/codeforafrica-deploy-review-app.yml +++ b/.github/workflows/codeforafrica-deploy-review-app.yml @@ -86,7 +86,7 @@ jobs: |-------|--------| | ${{ env.APP_NAME }} | [Visit](https://${{ env.APP_NAME }}.dev.codeforafrica.org) | - destroy_review_app4: + destroy_review_app: runs-on: ubuntu-latest if: github.event_name == 'pull_request' && github.event.action == 'closed' steps: