From 76fe41fe1a3a3c73bedfbfb78c9af2a475a32c36 Mon Sep 17 00:00:00 2001 From: Martin Kozlovsky Date: Fri, 11 Oct 2024 11:54:49 +0200 Subject: [PATCH 1/2] fix env variable --- .github/workflows/publish.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/publish.yaml b/.github/workflows/publish.yaml index e273e09..cd6cd91 100644 --- a/.github/workflows/publish.yaml +++ b/.github/workflows/publish.yaml @@ -29,10 +29,10 @@ env: GAR_STEM: us-central1-docker.pkg.dev/easyml-394818 jobs: - ghcr-publish: + publish: runs-on: ubuntu-latest env: - LOCAL_NAME: ${NAME}:${VERSION}-latest + LOCAL_NAME: luxonis/modelconverter-${{ inputs.package }}:${{ inputs.version }}-latest steps: - name: Checkout code From 670e1ee3000bebe5d4897bdfa2daa61ff7dd2b66 Mon Sep 17 00:00:00 2001 From: Martin Kozlovsky Date: Fri, 11 Oct 2024 11:57:46 +0200 Subject: [PATCH 2/2] added --build-arg --- .github/workflows/publish.yaml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/publish.yaml b/.github/workflows/publish.yaml index cd6cd91..8e576ac 100644 --- a/.github/workflows/publish.yaml +++ b/.github/workflows/publish.yaml @@ -25,7 +25,6 @@ env: NAME: luxonis/modelconverter-${{ inputs.package }} STEM: modelconverter-${{ inputs.package }} VERSION: ${{ inputs.version }} - GS_BUILD_ARTIFACTS: gs://luxonis-test-bucket/modelconverter/build-artifacts GAR_STEM: us-central1-docker.pkg.dev/easyml-394818 jobs: @@ -64,10 +63,12 @@ jobs: - name: Download build files from GCS if: ${{ inputs.package }} != hailo + env: + GS_BUILD_ARTIFACTS: gs://luxonis-test-bucket/modelconverter/build-artifacts run: | mkdir -p docker/extra_packages cd docker/extra_packages - if [ "$PACKAGE" = "rvc4" ]; then + if [ "${PACKAGE}" = "rvc4" ]; then gcloud storage cp \ "${GS_BUILD_ARTIFACTS}/snpe-${VERSION}.zip" \ "snpe-${VERSION}.zip" @@ -79,7 +80,7 @@ jobs: - name: Build image run: | - docker build -f "${DOCKERFILE}" -t "${LOCAL_NAME}" . + docker build -f "${DOCKERFILE}" -t "${LOCAL_NAME}" . --build-arg VERSION="${VERSION}" - name: GHCR publish latest run: |