From 36a5d566e1d7b0ffaa0a0ab7f7b3588940581862 Mon Sep 17 00:00:00 2001 From: Hermes Date: Sat, 2 May 2026 18:05:19 -0700 Subject: [PATCH] Fix: use github.ref_name for tag extraction, remove silent login fallback, drop broken github.ref_type check --- .gitea/actions/docker-build/action.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.gitea/actions/docker-build/action.yml b/.gitea/actions/docker-build/action.yml index 9c8603e..5f2a897 100644 --- a/.gitea/actions/docker-build/action.yml +++ b/.gitea/actions/docker-build/action.yml @@ -102,8 +102,8 @@ runs: TAGS="$TAGS,$TAG" # Add git tag if this is a tag push - if [ "${{ github.ref_type }}" = "tag" ] || [[ "${{ github.ref }}" == refs/tags/* ]]; then - TAG_NAME="${1#refs/tags/}" + if [[ "${{ github.ref }}" == refs/tags/* ]]; then + TAG_NAME="${{ github.ref_name }}" TAGS="$TAGS,$TAG_NAME" fi @@ -115,7 +115,7 @@ runs: shell: bash run: | if [ -n "${{ inputs.registry }}" ] && [ -n "${{ inputs.registry-password }}" ]; then - echo "${{ inputs.registry-password }}" | docker login ${{ inputs.registry }} -u ${{ inputs.registry-username }} --password-stdin || echo "Login failed or not needed" + echo "${{ inputs.registry-password }}" | docker login ${{ inputs.registry }} -u ${{ inputs.registry-username }} --password-stdin fi - name: Build image