mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2024-12-22 16:36:30 +00:00
Only publish PR images when label is set (#2608)
This commit is contained in:
parent
ec3a3cc9e1
commit
bb7e0f9221
1 changed files with 58 additions and 4 deletions
|
@ -80,7 +80,7 @@ steps:
|
||||||
platforms: *platforms_preview
|
platforms: *platforms_preview
|
||||||
tag: pull_${CI_COMMIT_PULL_REQUEST}
|
tag: pull_${CI_COMMIT_PULL_REQUEST}
|
||||||
when:
|
when:
|
||||||
event: pull_request
|
evaluate: 'CI_COMMIT_PULL_REQUEST_LABELS contains "build_pr_images"'
|
||||||
|
|
||||||
publish-server-alpine-preview:
|
publish-server-alpine-preview:
|
||||||
image: woodpeckerci/plugin-docker-buildx:2.1.0
|
image: woodpeckerci/plugin-docker-buildx:2.1.0
|
||||||
|
@ -92,7 +92,33 @@ steps:
|
||||||
platforms: *platforms_preview
|
platforms: *platforms_preview
|
||||||
tag: pull_${CI_COMMIT_PULL_REQUEST}-alpine
|
tag: pull_${CI_COMMIT_PULL_REQUEST}-alpine
|
||||||
when:
|
when:
|
||||||
event: pull_request
|
evaluate: 'CI_COMMIT_PULL_REQUEST_LABELS contains "build_pr_images"'
|
||||||
|
|
||||||
|
publish-server-preview-dry:
|
||||||
|
image: woodpeckerci/plugin-docker-buildx:2.1.0
|
||||||
|
secrets: [ docker_username, docker_password ]
|
||||||
|
group: docker
|
||||||
|
settings:
|
||||||
|
dry_run: true
|
||||||
|
repo: woodpeckerci/woodpecker-server
|
||||||
|
dockerfile: docker/Dockerfile.server.multiarch
|
||||||
|
platforms: *platforms_preview
|
||||||
|
tag: pull_${CI_COMMIT_PULL_REQUEST}
|
||||||
|
when:
|
||||||
|
evaluate: 'not (CI_COMMIT_PULL_REQUEST_LABELS contains "build_pr_images")'
|
||||||
|
|
||||||
|
publish-server-alpine-preview-dry:
|
||||||
|
image: woodpeckerci/plugin-docker-buildx:2.1.0
|
||||||
|
secrets: [ docker_username, docker_password ]
|
||||||
|
group: docker
|
||||||
|
settings:
|
||||||
|
dry_run: true
|
||||||
|
repo: woodpeckerci/woodpecker-server
|
||||||
|
dockerfile: docker/Dockerfile.server.alpine.multiarch
|
||||||
|
platforms: *platforms_preview
|
||||||
|
tag: pull_${CI_COMMIT_PULL_REQUEST}-alpine
|
||||||
|
when:
|
||||||
|
evaluate: 'not (CI_COMMIT_PULL_REQUEST_LABELS contains "build_pr_images")'
|
||||||
|
|
||||||
cross-compile-server:
|
cross-compile-server:
|
||||||
image: *xgo_image
|
image: *xgo_image
|
||||||
|
@ -204,7 +230,21 @@ steps:
|
||||||
tag: pull_${CI_COMMIT_PULL_REQUEST}
|
tag: pull_${CI_COMMIT_PULL_REQUEST}
|
||||||
build_args: *build_args
|
build_args: *build_args
|
||||||
when:
|
when:
|
||||||
event: pull_request
|
evaluate: 'CI_COMMIT_PULL_REQUEST_LABELS contains "build_pr_images"'
|
||||||
|
|
||||||
|
publish-agent-preview-dry:
|
||||||
|
group: docker
|
||||||
|
image: woodpeckerci/plugin-docker-buildx:2.1.0
|
||||||
|
secrets: [ docker_username, docker_password ]
|
||||||
|
settings:
|
||||||
|
dry_run: true
|
||||||
|
repo: woodpeckerci/woodpecker-agent
|
||||||
|
dockerfile: docker/Dockerfile.agent.multiarch
|
||||||
|
platforms: *platforms_preview
|
||||||
|
tag: pull_${CI_COMMIT_PULL_REQUEST}
|
||||||
|
build_args: *build_args
|
||||||
|
when:
|
||||||
|
evaluate: 'not (CI_COMMIT_PULL_REQUEST_LABELS contains "build_pr_images")'
|
||||||
|
|
||||||
publish-next-agent:
|
publish-next-agent:
|
||||||
group: docker
|
group: docker
|
||||||
|
@ -305,7 +345,21 @@ steps:
|
||||||
tag: pull_${CI_COMMIT_PULL_REQUEST}
|
tag: pull_${CI_COMMIT_PULL_REQUEST}
|
||||||
build_args: *build_args
|
build_args: *build_args
|
||||||
when:
|
when:
|
||||||
event: pull_request
|
evaluate: 'CI_COMMIT_PULL_REQUEST_LABELS contains "build_pr_images"'
|
||||||
|
|
||||||
|
publish-cli-preview-dry:
|
||||||
|
group: docker
|
||||||
|
image: woodpeckerci/plugin-docker-buildx:2.1.0
|
||||||
|
secrets: [ docker_username, docker_password ]
|
||||||
|
settings:
|
||||||
|
dry_run: true
|
||||||
|
repo: woodpeckerci/woodpecker-cli
|
||||||
|
dockerfile: docker/Dockerfile.cli.multiarch
|
||||||
|
platforms: *platforms_preview
|
||||||
|
tag: pull_${CI_COMMIT_PULL_REQUEST}
|
||||||
|
build_args: *build_args
|
||||||
|
when:
|
||||||
|
evaluate: 'not (CI_COMMIT_PULL_REQUEST_LABELS contains "build_pr_images")'
|
||||||
|
|
||||||
publish-next-cli:
|
publish-next-cli:
|
||||||
group: docker
|
group: docker
|
||||||
|
|
Loading…
Reference in a new issue