diff --git a/.github/workflows/build-deploy-ocr.yml b/.github/workflows/build-deploy-ocr.yml index 266b0acd..d8b54840 100644 --- a/.github/workflows/build-deploy-ocr.yml +++ b/.github/workflows/build-deploy-ocr.yml @@ -28,20 +28,19 @@ jobs: runs-on: ubuntu-latest outputs: docker_inspect: ${{ steps.image_check.outputs.docker_inspect }} + set_tag: ${{ steps.set_tag.outputs.docker_tag }} steps: - uses: actions/checkout@v4 - name: Lowercase the repo name run: echo "REPO=${GITHUB_REPOSITORY,,}" >>${GITHUB_ENV} - name: Set OCR Docker tag shell: bash - id: set-environment - env: - DEPLOY_ENV: ${{ inputs.deploy-env }} + id: set_tag run: |- - USER_INPUT="634fa0a0a12141b198e3f1544a9ccd320917efd3" + USER_INPUT="" echo "docker_tag=$( echo ${USER_INPUT:-"${{ github.sha }}"} - )" >> $GITHUB_ENV + )" >> $GITHUB_OUTPUT - name: Check if image exists id: image_check run: | @@ -76,6 +75,6 @@ jobs: uses: ./.github/actions/deploy-api with: deploy-env: dev - docker-tag: ${{ env.docker_tag }} + docker-tag: ${{ needs.build-publish-ocr.outputs.docker_tag }} docker-registry: ghcr.io api-name: ocr-api diff --git a/.github/workflows/deploy-dev.yml b/.github/workflows/deploy-dev.yml index 2b56fd43..bce159bb 100644 --- a/.github/workflows/deploy-dev.yml +++ b/.github/workflows/deploy-dev.yml @@ -32,9 +32,6 @@ jobs: run: echo "REPO=${GITHUB_REPOSITORY,,}" >>${GITHUB_ENV} - name: Set OCR Docker tag shell: bash - id: set-environment - env: - DEPLOY_ENV: ${{ inputs.deploy-env }} run: |- USER_INPUT="" echo "docker_tag=$(