From a4a382b482538ccae222d39592c4b390f7df55da Mon Sep 17 00:00:00 2001 From: tabversion Date: Wed, 30 Oct 2024 15:55:37 +0800 Subject: [PATCH 1/3] workflow --- ci/workflows/pull-request.yml | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/ci/workflows/pull-request.yml b/ci/workflows/pull-request.yml index 4b6079b72414d..305d2b07e8a8c 100644 --- a/ci/workflows/pull-request.yml +++ b/ci/workflows/pull-request.yml @@ -333,6 +333,25 @@ steps: timeout_in_minutes: 10 retry: *auto-retry + - label: "build-image-on-pr" + key: "build-image-on-pr" + if: build.pull_request.labels includes "build-image-on-pr" || build.env("CI_STEPS") =~ /(^|,)build-image-on-pr?(,|$$)/ + command: | + # Sanitize branch name for Docker tag + export IMAGE_TAG=$(echo "$BUILDKITE_BRANCH" | sed 's/[^a-zA-Z0-9._-]/-/g') + echo "publishing new image $IMAGE_TAG from branch $BUILDKITE_BRANCH ($BUILDKITE_COMMIT)" + # Trigger docker.yml pipeline + buildkite-agent pipeline upload ci/workflows/docker.yml + plugins: + - docker-compose#v5.1.0: + run: rw-build-env + config: ci/docker-compose.yml + mount-buildkite-agent: true + propagate-environment: true + - ./ci/plugins/upload-failure-logs + retry: *auto-retry + + - label: "end-to-end time travel test" key: "e2e-time-travel-tests" command: "ci/scripts/e2e-time-travel-test.sh -p ci-dev" From 2caeef50fa9f257584e517138f2429600fd12f8e Mon Sep 17 00:00:00 2001 From: Bohan Zhang Date: Wed, 30 Oct 2024 16:23:22 +0800 Subject: [PATCH 2/3] Update ci/workflows/pull-request.yml Co-authored-by: ClSlaid --- ci/workflows/pull-request.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci/workflows/pull-request.yml b/ci/workflows/pull-request.yml index 305d2b07e8a8c..812f6619fdea4 100644 --- a/ci/workflows/pull-request.yml +++ b/ci/workflows/pull-request.yml @@ -335,7 +335,7 @@ steps: - label: "build-image-on-pr" key: "build-image-on-pr" - if: build.pull_request.labels includes "build-image-on-pr" || build.env("CI_STEPS") =~ /(^|,)build-image-on-pr?(,|$$)/ + if: build.pull_request.labels includes "build-image-on-pr" || build.env("CI_STEPS") =~ /(^|,)build-image-on-pr(,|$$)/ command: | # Sanitize branch name for Docker tag export IMAGE_TAG=$(echo "$BUILDKITE_BRANCH" | sed 's/[^a-zA-Z0-9._-]/-/g') From 710ea1104e0cdcfbcdb9d3cd5bb8ab56d179996d Mon Sep 17 00:00:00 2001 From: tabversion Date: Thu, 31 Oct 2024 16:36:38 +0800 Subject: [PATCH 3/3] change label --- ci/workflows/pull-request.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci/workflows/pull-request.yml b/ci/workflows/pull-request.yml index 812f6619fdea4..e5cacfa1ebec7 100644 --- a/ci/workflows/pull-request.yml +++ b/ci/workflows/pull-request.yml @@ -335,7 +335,7 @@ steps: - label: "build-image-on-pr" key: "build-image-on-pr" - if: build.pull_request.labels includes "build-image-on-pr" || build.env("CI_STEPS") =~ /(^|,)build-image-on-pr(,|$$)/ + if: build.pull_request.labels includes "ci/pr/build-image-on-pr" || build.env("CI_STEPS") =~ /(^|,)ci\/pr\/build-image-on-pr(,|$$)/ command: | # Sanitize branch name for Docker tag export IMAGE_TAG=$(echo "$BUILDKITE_BRANCH" | sed 's/[^a-zA-Z0-9._-]/-/g')