Pytorch MNIST image: Allow root group to access test folder #3
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
# This workflow will build the MNIST job demo image and push it to the project-codeflare image registry | |
name: MNIST Job Demo Image | |
on: | |
workflow_dispatch: | |
inputs: | |
version: | |
description: 'Tag to be used for MNIST job demo image. For example pytorch-mnist-v0.0.0' | |
required: false | |
push: | |
branches: | |
- main | |
paths: | |
- 'pytorch_mnist_image/**' | |
env: | |
TAG: quay.io/project-codeflare/demo-images | |
VERSION: ${{ github.event.inputs.version || 'pytorch-mnist-dev' }} | |
jobs: | |
build-mnist: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Login to Quay.io | |
id: podman-login-quay | |
run: | | |
podman login --username ${{ secrets.QUAY_ID }} --password ${{ secrets.QUAY_TOKEN }} quay.io | |
- name: Image Build and Push | |
run: | | |
podman build -t ${TAG}:${VERSION} ./pytorch_mnist_image | |
podman push ${TAG}:${VERSION} | |
- name: Logout from Quay.io | |
if: always() && steps.podman-login-quay.outcome == 'success' | |
run: | | |
podman logout quay.io |