From aef01d385e11b8a41f1c412e4c286a1b2b337bb7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=B6ren=20Henning?= <soeren.henning@email.uni-kiel.de> Date: Fri, 21 Jan 2022 12:18:50 +0100 Subject: [PATCH] Trigger another pipeline --- .gitlab-ci.yml | 6 +++ second.gitlab-ci.yml | 106 +++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 112 insertions(+) create mode 100644 second.gitlab-ci.yml diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 48d3681da..500b8ba0a 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -187,6 +187,12 @@ spotbugs-benchmarks: when: on_failure expire_in: 1 day +trigger-benchmarks: + trigger: + include: second.gitlab-ci.yml + rules: + - if: '$CI_PIPELINE_SOURCE == "merge_request_event"' + .deploy-benchmarks: stage: deploy extends: diff --git a/second.gitlab-ci.yml b/second.gitlab-ci.yml new file mode 100644 index 000000000..7e79e5cb7 --- /dev/null +++ b/second.gitlab-ci.yml @@ -0,0 +1,106 @@ +workflow: + rules: + - if: '$CI_PIPELINE_SOURCE == "merge_request_event"' + - if: '$CI_COMMIT_BRANCH && $CI_OPEN_MERGE_REQUESTS && $CI_PIPELINE_SOURCE == "push"' + when: never + - when: always + +stages: + - build + - test + - check + - deploy + +default: + tags: + - exec-docker + +.dind: + tags: + - exec-dind + # see https://docs.gitlab.com/ee/ci/docker/using_docker_build.html#tls-enabled + # for image usage and settings for building with TLS and docker in docker + image: docker:19.03.1 + services: + - docker:19.03.1-dind + variables: + DOCKER_TLS_CERTDIR: "/certs" + +.kaniko-push: + image: + name: gcr.io/kaniko-project/executor:debug + entrypoint: [""] + script: + - mkdir -p /kaniko/.docker + - echo "{\"auths\":{\"${CR_HOST}\":{\"auth\":\"$(printf "%s:%s" "${CR_USER}" "${CR_PW}" | base64 | tr -d '\n')\"}}}" > /kaniko/.docker/config.json + - DOCKER_TAG_NAME=$(echo $CI_COMMIT_REF_SLUG- | sed 's/^master-$//') + - "[ ! $CI_COMMIT_TAG ] && KANIKO_D=\"$KANIKO_D -d $CR_HOST/$CR_ORG/$IMAGE_NAME:${DOCKER_TAG_NAME}latest\"" + - "[ ! $CI_COMMIT_TAG ] && KANIKO_D=\"$KANIKO_D -d $CR_HOST/$CR_ORG/$IMAGE_NAME:$DOCKER_TAG_NAME$CI_COMMIT_SHORT_SHA\"" + - "[ $CI_COMMIT_TAG ] && KANIKO_D=\"$KANIKO_D -d $CR_HOST/$CR_ORG/$IMAGE_NAME:$CI_COMMIT_TAG\"" + - "[ $DOCKERFILE ] && KANIKO_DOCKERFILE=\"--dockerfile $DOCKERFILE\"" + - /kaniko/executor --context `pwd`/$CONTEXT $KANIKO_DOCKERFILE $KANIKO_D + + +# Theodolite Docs + +.docs: + image: alpine/bundle:3.0.3 + cache: + paths: + - docs/vendor + before_script: + - cd docs + - bundle config set --local path 'vendor' + - bundle install + rules: + - changes: + - docs/**/* + - when: manual + allow_failure: true + +build-docs: + stage: build + extends: .docs + script: bundle exec jekyll build + artifacts: + paths: + - docs/_site + +test-docs-links: + stage: test + extends: .docs + needs: + - build-docs + script: bundle exec htmlproofer --assume-extension --allow_hash_href --url-ignore "/favicon.ico" ./_site + +test-docs-crds-regression: + stage: test + image: golang + before_script: + - cd docs + - go install fybrik.io/crdoc@latest + script: + - crdoc --resources ../theodolite/crd/ --template api-reference/crds.tmpl --output api-reference/crds.ref.md + - cmp api-reference/crds.md api-reference/crds.ref.md + artifacts: + when: on_failure + paths: + - docs/api-reference/crds.ref.md + expire_in: 1 week + rules: + - changes: + - docs/api-reference/crds.tmpl + - theodolite/crd/**/* + - when: manual + allow_failure: true + + +# Theodolite Helm Chart + +lint-helm: + stage: check + needs: [] + image: + name: alpine/helm:3.5.2 + entrypoint: [""] + script: helm lint helm/ -- GitLab