diff --git a/.github/workflows/schemas.yml b/.github/workflows/schemas.yml index 3741ec6..ebe6f89 100644 --- a/.github/workflows/schemas.yml +++ b/.github/workflows/schemas.yml @@ -16,7 +16,7 @@ on: types: [generate-pipeline-schemas] env: - HAYSTACK_REF: ${{ github.event.client_payload.ref || inputs.ref || 'main' }} + HAYSTACK_REF: ${{ github.event.client_payload.ref || inputs.ref || 'v1.x' }} SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} jobs: @@ -40,8 +40,14 @@ jobs: - if: steps.validate.outcome == 'success' name: Update schema run: | + if [ "${HAYSTACK_REF}" == "v1.x" ]; then + export HAYSTACK_REF="main" + fi docker run -t -v "${PWD}:/haystack-json-schema" "docker.io/deepset/haystack:base-cpu-${HAYSTACK_REF}" python /haystack-json-schema/.github/utils/generate_json_schema.py - + if [ "${HAYSTACK_REF}" == "main" ]; then + export HAYSTACK_REF="v1.x" + fi + - if: steps.validate.outcome == 'success' name: Commit files run: |