2020-04-21 14:09:31 -04:00
|
|
|
review-cleanup:
|
2019-09-18 14:06:14 -04:00
|
|
|
extends:
|
|
|
|
- .default-retry
|
2020-02-12 10:09:37 -05:00
|
|
|
- .review:rules:review-cleanup
|
2021-07-22 05:08:22 -04:00
|
|
|
image: registry.gitlab.com/gitlab-org/gitlab-build-images:gitlab-helm3-kubectl1.14
|
2019-09-18 14:06:14 -04:00
|
|
|
stage: prepare
|
|
|
|
environment:
|
|
|
|
name: review/auto-cleanup
|
|
|
|
action: stop
|
|
|
|
before_script:
|
|
|
|
- source scripts/utils.sh
|
2020-04-21 14:09:31 -04:00
|
|
|
- source scripts/review_apps/gcp_cleanup.sh
|
2019-09-18 14:06:14 -04:00
|
|
|
- install_gitlab_gem
|
2020-04-21 14:09:31 -04:00
|
|
|
- setup_gcp_dependencies
|
2019-09-18 14:06:14 -04:00
|
|
|
script:
|
|
|
|
- ruby -rrubygems scripts/review_apps/automated_cleanup.rb
|
2020-03-30 23:07:51 -04:00
|
|
|
- gcp_cleanup
|
|
|
|
|
2021-10-14 11:14:02 -04:00
|
|
|
start-review-app-pipeline:
|
2020-06-30 11:08:48 -04:00
|
|
|
extends:
|
2021-11-17 22:14:17 -05:00
|
|
|
- .review:rules:start-review-app-pipeline
|
2021-10-14 11:14:02 -04:00
|
|
|
stage: review
|
2020-06-30 11:08:48 -04:00
|
|
|
needs:
|
2021-10-14 11:14:02 -04:00
|
|
|
- job: build-assets-image
|
2020-06-30 11:08:48 -04:00
|
|
|
artifacts: false
|
2021-10-14 11:14:02 -04:00
|
|
|
- job: build-qa-image
|
|
|
|
artifacts: false
|
2021-10-18 05:12:29 -04:00
|
|
|
# These variables are set in the pipeline schedules.
|
|
|
|
# They need to be explicitly passed on to the child pipeline.
|
|
|
|
# https://docs.gitlab.com/ee/ci/pipelines/multi_project_pipelines.html#pass-cicd-variables-to-a-downstream-pipeline-by-using-the-variables-keyword
|
|
|
|
variables:
|
|
|
|
FREQUENCY: $FREQUENCY
|
|
|
|
DAST_RUN: $DAST_RUN
|
2021-10-14 11:14:02 -04:00
|
|
|
trigger:
|
|
|
|
include:
|
|
|
|
- local: .gitlab/ci/review-apps/main.gitlab-ci.yml
|
|
|
|
strategy: depend
|
2021-05-26 17:10:49 -04:00
|
|
|
|
2019-04-12 04:56:38 -04:00
|
|
|
danger-review:
|
2019-08-26 16:41:55 -04:00
|
|
|
extends:
|
|
|
|
- .default-retry
|
2021-03-12 07:09:33 -05:00
|
|
|
- .danger-review-cache
|
2020-02-12 10:09:37 -05:00
|
|
|
- .review:rules:danger
|
2019-04-12 04:56:38 -04:00
|
|
|
stage: test
|
2020-02-20 13:08:51 -05:00
|
|
|
needs: []
|
2021-03-12 07:09:33 -05:00
|
|
|
before_script:
|
2021-05-14 14:10:34 -04:00
|
|
|
- source scripts/utils.sh
|
|
|
|
- bundle_install_script "--with danger"
|
2020-10-08 14:08:32 -04:00
|
|
|
- run_timed_command "retry yarn install --frozen-lockfile"
|
2021-03-12 07:09:33 -05:00
|
|
|
script:
|
2021-03-31 14:09:19 -04:00
|
|
|
- >
|
|
|
|
if [ -z "$DANGER_GITLAB_API_TOKEN" ]; then
|
2021-07-15 08:09:01 -04:00
|
|
|
run_timed_command danger_as_local
|
2021-03-31 14:09:19 -04:00
|
|
|
else
|
|
|
|
run_timed_command "bundle exec danger --fail-on-errors=true --verbose"
|
|
|
|
fi
|
2021-07-15 08:09:01 -04:00
|
|
|
|
|
|
|
danger-review-local:
|
|
|
|
extends:
|
|
|
|
- danger-review
|
|
|
|
- .review:rules:danger-local
|
|
|
|
script:
|
|
|
|
- run_timed_command danger_as_local
|