mirror of
https://ops.gitlab.net/gitlab-org/gitlab-build-images.git
synced 2025-12-09 10:02:56 +01:00
17 lines
760 B
YAML
17 lines
760 B
YAML
.build_and_push:
|
|
stage: custom
|
|
needs: []
|
|
script:
|
|
- ./scripts/lib/custom-docker-build
|
|
rules:
|
|
- if: '$CI_PIPELINE_SOURCE == "merge_request_event" && $CI_SERVER_HOST == "gitlab.com"'
|
|
variables:
|
|
BASE_BUILD_REGISTRY_IMAGE: registry.gitlab.com/gitlab-org/gitlab-build-images
|
|
- if: '$CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && $CI_SERVER_HOST == "gitlab.com"'
|
|
variables:
|
|
PUSH_CUSTOM_IMAGE: "true"
|
|
BASE_BUILD_REGISTRY_IMAGE: registry.gitlab.com/gitlab-org/gitlab-build-images
|
|
- if: '$CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && ($CI_SERVER_HOST == "ops.gitlab.net" || $CI_SERVER_HOST == "dev.gitlab.org")'
|
|
variables:
|
|
PUSH_CUSTOM_IMAGE: "true"
|
|
BASE_BUILD_REGISTRY_IMAGE: $CI_REGISTRY_IMAGE
|