Skip to content

Commit

Permalink
CARRY: ODH build and publish image
Browse files Browse the repository at this point in the history
  • Loading branch information
Shilpa Chugh authored and openshift-merge-bot[bot] committed Jun 26, 2024
1 parent 4b3b644 commit a0365f8
Showing 1 changed file with 59 additions and 0 deletions.
59 changes: 59 additions & 0 deletions .github/workflows/odh-build-and-publish-kueue-image.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
# This workflow builds ODH Kueue container image and publish to Quay

name: Build and Publish image

on:
workflow_dispatch:
inputs:
version:
description: 'Tag to be used for kueue image i.e.: v0.0.1'
required: true
push:
tags:
- '*'

jobs:
build-and-publish:
runs-on: ubuntu-latest
env:
GOPATH: ${{ github.workspace }}/go
steps:
- name: Environment dump
shell: bash
run: |
echo "GOPATH = ${GOPATH}"
echo "TAG = ${{ github.event.inputs.version }}"
- name: Checkout
uses: actions/checkout@v4

- name: Set Go
uses: actions/setup-go@v5
with:
go-version-file: go.mod

- name: Run go mod
shell: bash
run: |
go mod download
- name: Login to Quay.io
id: docker-login-quay
shell: bash
run: |
docker login --username ${{ secrets.QUAY_USERNAME }} --password ${{ secrets.QUAY_PASSWORD }} quay.io
- name: Image Build and Push
env:
CGO_ENABLED: 1
PLATFORMS: linux/amd64
TARGETARCH: amd64
IMAGE_REGISTRY: quay.io/opendatahub
GIT_TAG: ${{ github.event.inputs.version }}
run: |
make image-push
- name: Logout from Quay.io
if: always() && steps.docker-login-quay.outcome == 'success'
run: |
docker logout quay.io

0 comments on commit a0365f8

Please sign in to comment.