From c19195131cfc8c3321d750b103a47897fac177f5 Mon Sep 17 00:00:00 2001 From: ishaan-jaff Date: Thu, 4 Jan 2024 15:40:44 +0530 Subject: [PATCH] (ci/cd) tag the correct version --- .circleci/config.yml | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 44444bca1..ee5235467 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -134,11 +134,15 @@ jobs: - run: name: Trigger Github Action for new Docker Container command: | - curl -X POST \ - -H "Accept: application/vnd.github.v3+json" \ - -H "Authorization: Bearer $GITHUB_TOKEN" \ - "https://api.github.com/repos/BerriAI/litellm/actions/workflows/ghcr_deploy.yml/dispatches" \ - -d '{"ref":"main"}' + echo "Install TOML package." + python3 -m pip install toml + VERSION=$(python3 -c "import toml; print(toml.load('pyproject.toml')['tool']['poetry']['version'])") + echo "LiteLLM Version ${VERSION}" + curl -X POST \ + -H "Accept: application/vnd.github.v3+json" \ + -H "Authorization: Bearer $GITHUB_TOKEN" \ + "https://api.github.com/repos/BerriAI/litellm/actions/workflows/ghcr_deploy.yml/dispatches" \ + -d "{\"ref\":\"main\", \"inputs\":{\"tag\":\"${VERSION}\"}}" workflows: version: 2