From c50b00c3f237bff5b536c24d6c8debecd145978c Mon Sep 17 00:00:00 2001 From: Ivan Blinkov Date: Tue, 28 Apr 2020 12:57:14 +0300 Subject: [PATCH] Revert "Delete .gitlab-ci.yml" This reverts commit 22227a44ac8a097ee82652478a59d4635bcbcdc9. --- .gitlab-ci.yml | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 .gitlab-ci.yml diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 00000000000..12afadc55a6 --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,41 @@ +stages: + - builder + - build +variables: + GIT_SUBMODULE_STRATEGY: recursive +builder: + stage: builder + when: manual + services: + - docker:dind + script: + - docker info + - apk add --no-cache git curl binutils ca-certificates + - docker login -u gitlab -p nopasswd $CI_REGISTRY + - docker build -t yandex/clickhouse-builder ./docker/builder + - docker tag yandex/clickhouse-builder $CI_REGISTRY/yandex/clickhouse-builder + - docker push $CI_REGISTRY/yandex/clickhouse-builder + tags: + - docker +build: + stage: build + when: manual + services: + - docker:dind + script: + - apk add --no-cache git curl binutils ca-certificates + - git submodule sync --recursive + - git submodule update --init --recursive + - docker info + - docker login -u gitlab -p nopasswd $CI_REGISTRY + - docker pull $CI_REGISTRY/yandex/clickhouse-builder + - docker run --rm --volumes-from "${HOSTNAME}-build" --workdir "${CI_PROJECT_DIR}" --env CI_PROJECT_DIR=${CI_PROJECT_DIR} $CI_REGISTRY/yandex/clickhouse-builder /build_gitlab_ci.sh + # You can upload your binary to nexus + - curl -v --keepalive-time 60 --keepalive --user "$NEXUS_USER:$NEXUS_PASSWORD" -XPUT "http://$NEXUS_HOST/repository/binaries/$CI_PROJECT_NAME" --upload-file ./src/Server/clickhouse + # Or download artifacts from gitlab + artifacts: + paths: + - ./src/Server/clickhouse + expire_in: 1 day + tags: + - docker