Skip to content

Commit e2a13fd

Browse files
committed
enable deploying from non-main branch via manual trigger
1 parent 1e6a785 commit e2a13fd

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

.github/workflows/test-build-push.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
name: Test, Build and Push Images
22

3-
# Runs tests and builds images on every branch. Only pushes to the registry on main.
3+
# Runs tests and builds images on every branch.
4+
# Pushes to the registry only on main, or on a manual workflow_dispatch run.
45
on:
56
push:
67
branches:
@@ -93,7 +94,7 @@ jobs:
9394
with:
9495
context: ${{ matrix.context }}
9596
file: ${{ matrix.context }}/Dockerfile
96-
push: ${{ github.ref == 'refs/heads/main' }}
97+
push: ${{ github.ref == 'refs/heads/main' || github.event_name == 'workflow_dispatch' }}
9798
tags: ${{ steps.meta.outputs.tags }}
9899
labels: ${{ steps.meta.outputs.labels }}
99100
cache-from: type=gha

0 commit comments

Comments
 (0)