mirror of
https://github.com/block/buzz.git
synced 2026-10-28 13:01:10 +00:00
ci: add fork guards to docker, release, and auto-tag workflows (#1007)
This commit is contained in:
@@ -13,7 +13,8 @@ jobs:
|
|||||||
auto-tag:
|
auto-tag:
|
||||||
if: >
|
if: >
|
||||||
github.event.pull_request.merged == true &&
|
github.event.pull_request.merged == true &&
|
||||||
startsWith(github.event.pull_request.head.ref, 'version-bump/')
|
startsWith(github.event.pull_request.head.ref, 'version-bump/') &&
|
||||||
|
github.event.pull_request.head.repo.full_name == github.repository
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6
|
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6
|
||||||
|
|||||||
2
.github/workflows/docker.yml
vendored
2
.github/workflows/docker.yml
vendored
@@ -132,7 +132,7 @@ jobs:
|
|||||||
cache-from: |
|
cache-from: |
|
||||||
type=registry,ref=${{ env.IMAGE_NAME }}-buildcache:${{ matrix.arch }}
|
type=registry,ref=${{ env.IMAGE_NAME }}-buildcache:${{ matrix.arch }}
|
||||||
cache-to: |
|
cache-to: |
|
||||||
type=registry,ref=${{ env.IMAGE_NAME }}-buildcache:${{ matrix.arch }},mode=max,compression=zstd
|
${{ (github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository) && format('type=registry,ref={0}-buildcache:{1},mode=max,compression=zstd', env.IMAGE_NAME, matrix.arch) || '' }}
|
||||||
|
|
||||||
- name: Export digest
|
- name: Export digest
|
||||||
if: github.event_name != 'pull_request'
|
if: github.event_name != 'pull_request'
|
||||||
|
|||||||
3
.github/workflows/release.yml
vendored
3
.github/workflows/release.yml
vendored
@@ -17,6 +17,7 @@ on:
|
|||||||
jobs:
|
jobs:
|
||||||
release:
|
release:
|
||||||
name: Release
|
name: Release
|
||||||
|
if: github.repository == 'block/sprout'
|
||||||
runs-on: macos-latest
|
runs-on: macos-latest
|
||||||
timeout-minutes: 60
|
timeout-minutes: 60
|
||||||
permissions:
|
permissions:
|
||||||
@@ -261,6 +262,7 @@ jobs:
|
|||||||
|
|
||||||
release-macos-x64:
|
release-macos-x64:
|
||||||
name: Release macOS (Intel)
|
name: Release macOS (Intel)
|
||||||
|
if: github.repository == 'block/sprout'
|
||||||
runs-on: macos-latest
|
runs-on: macos-latest
|
||||||
needs: release
|
needs: release
|
||||||
timeout-minutes: 60
|
timeout-minutes: 60
|
||||||
@@ -366,6 +368,7 @@ jobs:
|
|||||||
|
|
||||||
release-linux:
|
release-linux:
|
||||||
name: Release Linux
|
name: Release Linux
|
||||||
|
if: github.repository == 'block/sprout'
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: release
|
needs: release
|
||||||
timeout-minutes: 60
|
timeout-minutes: 60
|
||||||
|
|||||||
Reference in New Issue
Block a user