Cancel superseded pull request validation without cancelling releases

This commit is contained in:
2026-09-11 08:47:07 +00:00
parent 20c1efb8a3
commit 8502885a9d
+12 -5
View File
@@ -3,19 +3,26 @@ name: Build and Push Container
on:
push:
branches:
- master
- main
tags:
- v*
workflow_dispatch:
workflow_dispatch: null
pull_request:
branches:
- main
env:
REGISTRY: gitea.wayfinderak.com
IMAGE_NAME: wayfinderak/prepbot
concurrency:
group: ${{ github.workflow }}-${{ github.event_name }}-${{ github.event.pull_request.number
|| github.run_id }}
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
jobs:
docker:
runs-on: ubuntu-latest
runs-on: butler-ci
steps:
- name: Checkout
uses: actions/checkout@v4
@@ -39,7 +46,7 @@ jobs:
uses: docker/setup-buildx-action@v3
- name: Log in to Gitea registry
if: ${{ steps.delivery.outputs.run == 'true' }}
if: ${{ (steps.delivery.outputs.run == 'true') && github.event_name != 'pull_request' }}
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
@@ -74,6 +81,6 @@ jobs:
uses: docker/build-push-action@v6
with:
context: .
push: true
push: ${{ github.event_name != 'pull_request' }}
platforms: linux/amd64,linux/arm64
tags: ${{ steps.prep.outputs.tags }}