File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -54,6 +54,11 @@ generator:
5454
5555generated pipeline :
5656 stage : run
57+ variables :
58+ # Forward MR context to child pipeline since $CI_PIPELINE_SOURCE becomes
59+ # "parent_pipeline" in downstream pipelines and MR variables are not inherited.
60+ PARENT_PIPELINE_SOURCE : $CI_PIPELINE_SOURCE
61+ PARENT_OPEN_MRS : $CI_OPEN_MERGE_REQUESTS
5762 trigger :
5863 include :
5964 - artifact : .gitlab/pipeline.yaml
Original file line number Diff line number Diff line change @@ -244,7 +244,7 @@ publish layer e2e sandbox ({{ $f.name }}):
244244 when: on_success
245245 variables:
246246 LAYER_DESCRIPTION: $CI_COMMIT_TAG
247- - if : '$CI_PIPELINE_SOURCE == " merge_request_event" || $CI_MERGE_REQUEST_IID || $CI_OPEN_MERGE_REQUESTS '
247+ - if : '$PARENT_PIPELINE_SOURCE == " merge_request_event" || $PARENT_OPEN_MRS '
248248 when: on_success
249249 variables:
250250 LAYER_DESCRIPTION: $CI_COMMIT_SHORT_SHA
@@ -283,7 +283,7 @@ e2e-test ({{ $f.name }}):
283283 when: on_success
284284 variables:
285285 EXTENSION_VERSION: $CI_COMMIT_TAG
286- - if : '$CI_PIPELINE_SOURCE == " merge_request_event" || $CI_MERGE_REQUEST_IID || $CI_OPEN_MERGE_REQUESTS '
286+ - if : '$PARENT_PIPELINE_SOURCE == " merge_request_event" || $PARENT_OPEN_MRS '
287287 when: on_success
288288 variables:
289289 EXTENSION_VERSION: $CI_COMMIT_SHORT_SHA
@@ -301,7 +301,7 @@ e2e-test-status ({{ $f.name }}):
301301 rules:
302302 - if : '$CI_COMMIT_TAG = ~ /^v. */'
303303 when: on_success
304- - if : '$CI_PIPELINE_SOURCE == " merge_request_event" || $CI_MERGE_REQUEST_IID || $CI_OPEN_MERGE_REQUESTS '
304+ - if : '$PARENT_PIPELINE_SOURCE == " merge_request_event" || $PARENT_OPEN_MRS '
305305 when: on_success
306306 needs:
307307 - job: " e2e-test ({{ $f.name }})"
You can’t perform that action at this time.
0 commit comments