Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitaly.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Cai <jcai@gitlab.com>2024-01-17 00:18:57 +0300
committerJohn Cai <jcai@gitlab.com>2024-01-18 16:33:47 +0300
commitbfacf1e7c96058cd738ac84fed9f3f8b6bdb9db6 (patch)
tree3f2f2e1d01b8b8e4bc11af105e1c951a61116b8c
parent92f15bbbd89062e4cb82c07769b97f453f20e18f (diff)
.gitlab-ci.yml: start rails spec and cleanup automatically
-rw-r--r--.gitlab-ci.yml10
1 files changed, 6 insertions, 4 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index ef608ef89..b01e79583 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -504,7 +504,8 @@ start-rails-specs:
name: merge-requests/$RAILS_BRANCH_FOR_JOB
on_stop: rails-specs-cleanup
rules:
- - when: manual
+ - if: $CI_PIPELINE_SOURCE == "merge_request_event" && $CI_MERGE_REQUEST_EVENT_TYPE != "merge_train"
+ when: manual
allow_failure: true
rails-specs:
@@ -523,7 +524,7 @@ rails-specs:
ENABLE_RSPEC_INTEGRATION: "true"
ENABLE_RSPEC_SYSTEM: "true"
rules:
- - when: manual
+ - if: $CI_PIPELINE_SOURCE == "merge_request_event" && $CI_MERGE_REQUEST_EVENT_TYPE != "merge_train"
allow_failure: true
rails-specs-cleanup:
@@ -537,7 +538,8 @@ rails-specs-cleanup:
name: merge-requests/$RAILS_BRANCH_FOR_JOB
action: stop
rules:
- - when: manual
+ - if: $CI_PIPELINE_SOURCE == "merge_request_event" && $CI_MERGE_REQUEST_EVENT_TYPE != "merge_train"
+ when: manual
allow_failure: true
cleanup-rails-spec-test-env:
@@ -551,7 +553,7 @@ cleanup-rails-spec-test-env:
ENV_ID=$(curl -s --request GET --header "PRIVATE-TOKEN: $GITALY_PROJECT_TOKEN" "https://gitlab.com/api/v4/projects/2009901/environments" --data-urlencode "name=merge-requests/$RAILS_BRANCH_FOR_JOB" | jq '.[0].id')
curl --fail -s --request DELETE --header "PRIVATE-TOKEN: $GITALY_PROJECT_TOKEN" "https://gitlab.com/api/v4/projects/2009901/environments/$ENV_ID"
rules:
- - when: manual
+ - if: $CI_PIPELINE_SOURCE == "merge_request_event" && $CI_MERGE_REQUEST_EVENT_TYPE != "merge_train"
allow_failure: true
build-package-and-qa: