APPENG-2521: Implement the NIM service deployment page and connect it with the APIs #2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Delete quay image on PR closed | |
on: | |
pull_request: | |
types: | |
- closed | |
env: | |
QUAY_ODH_DASHBOARD_IMAGE_REPO: ${{ secrets.QUAY_ODH_DASHBOARD_IMAGE_REPO }} | |
jobs: | |
delete-pr-quay-image: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Git checkout | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: '0' | |
- name: Install skopeo | |
shell: bash | |
run: | | |
sudo apt-get -y update | |
sudo apt-get -y install skopeo | |
- name: Login to quay.io | |
shell: bash | |
env: | |
QUAY_TOKEN: ${{ secrets.QUAY_ROBOT_TOKEN }} | |
QUAY_ROBOT_USERNAME: ${{ secrets.QUAY_ROBOT_USERNAME }} | |
run: | | |
skopeo login quay.io -u ${QUAY_ROBOT_USERNAME} -p ${QUAY_TOKEN} | |
- name: Delete PR image | |
shell: bash | |
env: | |
PR: ${{ github.event.pull_request.number }} | |
run: | | |
skopeo delete docker://${QUAY_ODH_DASHBOARD_IMAGE_REPO}:pr-${{ env.PR }} |