Commit 045f13de authored by Rémy Coutable's avatar Rémy Coutable Committed by Albert Salim

ci: Allow to force Review App to be deployed with a label

parent 2d65f45b
......@@ -58,6 +58,9 @@
.if-merge-request-labels-run-decomposed: &if-merge-request-labels-run-decomposed
if: '$CI_MERGE_REQUEST_LABELS =~ /pipeline:run-decomposed/'
.if-merge-request-labels-run-review-app: &if-merge-request-labels-run-review-app
if: '$CI_MERGE_REQUEST_LABELS =~ /pipeline:run-review-app/'
.if-security-merge-request: &if-security-merge-request
if: '$CI_PROJECT_NAMESPACE == "gitlab-org/security" && $CI_MERGE_REQUEST_IID'
......@@ -447,6 +450,7 @@
rules:
- <<: *if-not-ee
when: never
- <<: *if-merge-request-labels-run-review-app
- <<: *if-dot-com-gitlab-org-and-security-merge-request
changes: *ci-build-images-patterns
- <<: *if-dot-com-gitlab-org-and-security-merge-request
......@@ -459,6 +463,7 @@
rules:
- <<: *if-not-canonical-namespace
when: never
- <<: *if-merge-request-labels-run-review-app
- <<: *if-auto-deploy-branches
- changes: *ci-build-images-patterns
- changes: *code-qa-patterns
......@@ -540,6 +545,7 @@
rules:
- <<: *if-not-canonical-namespace
when: never
- <<: *if-merge-request-labels-run-review-app
- <<: *if-auto-deploy-branches
- changes: *code-qa-patterns
......@@ -1501,6 +1507,7 @@
rules:
- <<: *if-not-ee
when: never
- <<: *if-merge-request-labels-run-review-app
- <<: *if-dot-com-gitlab-org-merge-request
changes: *ci-review-patterns
- <<: *if-dot-com-gitlab-org-merge-request
......@@ -1517,6 +1524,7 @@
rules:
- <<: *if-not-ee
when: never
- <<: *if-merge-request-labels-run-review-app
- <<: *if-dot-com-gitlab-org-merge-request
changes: *ci-review-patterns
- <<: *if-dot-com-gitlab-org-merge-request
......@@ -1532,6 +1540,7 @@
rules:
- <<: *if-not-ee
when: never
- <<: *if-merge-request-labels-run-review-app
- <<: *if-dot-com-gitlab-org-merge-request
changes: *ci-review-patterns
- <<: *if-dot-com-gitlab-org-merge-request
......@@ -1550,6 +1559,7 @@
when: never
- <<: *if-not-ee
when: never
- <<: *if-merge-request-labels-run-review-app
- <<: *if-dot-com-gitlab-org-merge-request
changes: *ci-review-patterns
- <<: *if-dot-com-gitlab-org-merge-request
......@@ -1565,6 +1575,7 @@
rules:
- <<: *if-not-ee
when: never
- <<: *if-merge-request-labels-run-review-app
- <<: *if-dot-com-gitlab-org-merge-request
changes: *code-qa-patterns
......@@ -1572,6 +1583,7 @@
rules:
- <<: *if-not-ee
when: never
- <<: *if-merge-request-labels-run-review-app
- <<: *if-dot-com-gitlab-org-merge-request
changes: *ci-review-patterns
- <<: *if-dot-com-gitlab-org-merge-request
......@@ -1586,11 +1598,17 @@
# The rule needs to be duplicated between `on_success` and `on_failure`
# because the jobs `needs` the previous job to complete.
# With `when: always`, and the `review-qa-*` jobs are manual, the `allure-report-qa-*` jobs
# would start running before the qa jobs have started.
# See https://gitlab.com/gitlab-org/gitlab/-/merge_requests/63844#note_599012559
.review:rules:review-qa-smoke-report:
rules:
- <<: *if-not-ee
when: never
- <<: *if-merge-request-labels-run-review-app
when: on_success
- <<: *if-merge-request-labels-run-review-app
when: on_failure
- <<: *if-dot-com-gitlab-org-merge-request
changes: *ci-review-patterns
when: on_success
......@@ -1618,6 +1636,7 @@
rules:
- <<: *if-not-ee
when: never
- <<: *if-merge-request-labels-run-review-app
- <<: *if-dot-com-gitlab-org-merge-request
changes: *code-patterns
when: manual
......@@ -1630,11 +1649,17 @@
# The rule needs to be duplicated between `on_success` and `on_failure`
# because the jobs `needs` the previous job to complete.
# With `when: always`, and the `review-qa-*` jobs are manual, the `allure-report-qa-*` jobs
# would start running before the qa jobs have started.
# See https://gitlab.com/gitlab-org/gitlab/-/merge_requests/63844#note_599012559
.review:rules:review-qa-all-report:
rules:
- <<: *if-not-ee
when: never
- <<: *if-merge-request-labels-run-review-app
when: on_success
- <<: *if-merge-request-labels-run-review-app
when: on_failure
- <<: *if-dot-com-gitlab-org-merge-request
changes: *code-patterns
when: manual
......@@ -1669,6 +1694,9 @@
rules:
- <<: *if-not-ee
when: never
- <<: *if-merge-request-labels-run-review-app
when: manual
allow_failure: true
- <<: *if-dot-com-gitlab-org-merge-request
changes: *code-qa-patterns
when: manual
......
......@@ -181,6 +181,8 @@ that includes `rspec-profile` in their name.
Consult the [Review Apps](testing_guide/review_apps.md) dedicated page for more information.
If you want to force a Review App to be deployed regardless of your changes, you can add the `pipeline:run-review-app` label to the merge request.
## As-if-FOSS jobs
The `* as-if-foss` jobs run the GitLab test suite "as if FOSS", meaning as if the jobs would run in the context
......
......@@ -16,6 +16,7 @@ For any of the following scenarios, the `start-review-app-pipeline` job would be
- for merge requests with frontend changes
- for merge requests with QA changes
- for scheduled pipelines
- the MR has the `pipeline:run-review-app` label set
## QA runs on Review Apps
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment