new gh wf

This commit is contained in:
typescreep
2025-09-27 16:03:31 +03:00
parent 5139a0219f
commit adae7e6767

View File

@@ -30,6 +30,10 @@ jobs:
username: ${{ secrets.CUSTOM_DOCKERHUB_USERNAME }}
password: ${{ secrets.CUSTOM_DOCKERHUB_TOKEN }}
- name: Sanitize branch name
id: sanitize
run: echo "branch=$(echo '${{ github.head_ref || github.ref_name }}' | tr '/' '-')" >> $GITHUB_OUTPUT
- name: Build and push Docker image
uses: docker/build-push-action@v4
with:
@@ -37,6 +41,6 @@ jobs:
file: ./Dockerfile.build
builder: default
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ secrets.CUSTOM_DOCKERHUB_USERNAME }}/openapi-ui:${{ (github.head_ref || github.ref_name) | gsub('/','-') }}-${{ steps.short-sha.outputs.sha }}
tags: ${{ secrets.CUSTOM_DOCKERHUB_USERNAME }}/openapi-ui:${{ steps.sanitize.outputs.branch }}-${{ steps.short-sha.outputs.sha }}
build-args: |
NODE_VERSION=${{ env.NODE_VERSION }}