mirror of
https://github.com/element-hq/matrix-authentication-service.git
synced 2026-10-23 13:03:35 +00:00
Only sign docker image on tags and main branch
This commit is contained in:
1 file changed
+5
-1
@@ -357,7 +357,11 @@ jobs:
|
||||
base.cache-to=type=registry,ref=${{ env.IMAGE }}:buildcache,mode=max
|
||||
|
||||
- name: Sign the images with GitHub Actions provided token
|
||||
if: github.event_name != 'pull_request'
|
||||
# Only sign on tags and on commits on main branch
|
||||
if: |
|
||||
github.event_name != 'pull_request'
|
||||
&& (startsWith(github.ref, 'refs/tags/v') || github.ref == 'refs/heads/main')
|
||||
|
||||
run: cosign sign ${TAGS}
|
||||
env:
|
||||
TAGS: "${{ steps.meta.outputs.tags }} ${{ steps.meta-debug.outputs.tags }}"
|
||||
|
||||
Reference in new issue
Block a user