From e6ae14f003ce1620dcca64a8f8aa850cd522f2e5 Mon Sep 17 00:00:00 2001 From: Shaun Maher Date: Fri, 23 Feb 2024 10:56:28 +1100 Subject: [PATCH] Don't fail if there is no existing helm chart to get the version from --- .github/workflows/ghcr_deploy.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ghcr_deploy.yml b/.github/workflows/ghcr_deploy.yml index 3ecc825790..3b21d23801 100644 --- a/.github/workflows/ghcr_deploy.yml +++ b/.github/workflows/ghcr_deploy.yml @@ -15,6 +15,7 @@ env: # There is a single job in this workflow. It's configured to run on the latest available version of Ubuntu. jobs: docker-hub-deploy: + if: github.repository == 'BerriAI/litellm' runs-on: ubuntu-latest steps: - @@ -137,7 +138,7 @@ jobs: - name: Get last published chart version id: current_version shell: bash - run: helm show chart oci://${{ env.REGISTRY }}/${{ env.REPO_OWNER }}/${{ env.CHART_NAME }} | grep '^version:' | awk 'BEGIN{FS=":"}{print "current-version="$2}' | tr -d " " | tee -a $GITHUB_OUTPUT + run: helm show chart oci://${{ env.REGISTRY }}/${{ env.REPO_OWNER }}/${{ env.CHART_NAME }} || true | grep '^version:' | awk 'BEGIN{FS=":"}{print "current-version="$2}' | tr -d " " | tee -a $GITHUB_OUTPUT env: HELM_EXPERIMENTAL_OCI: '1'