ligo/.gitlab-ci.yml

191 lines
3.9 KiB
YAML
Raw Normal View History

2016-09-08 21:13:10 +04:00
variables:
image_name: ocp_tezos
image_id: ${CI_BUILD_REF_NAME}
build_image_name: ${image_name}_build_deps
2016-09-08 21:13:10 +04:00
build_image_id: ${CI_BUILD_REF}
image: ${build_image_name}:${build_image_id}
2016-09-08 21:13:10 +04:00
stages:
- build_deps
- build
- build_test
- test
- expurge
2016-09-08 21:13:10 +04:00
- publish
- cleanup
build_deps:
stage: build_deps
image: ocp:docker
tags:
- docker_builder
script:
- ./scripts/create_build_deps_docker_image.sh
${build_image_name} ${build_image_id}
2016-09-08 21:13:10 +04:00
build:
stage: build
tags:
- tezos_builder
script:
2017-01-02 17:02:55 +04:00
- echo "PRODUCTION=yes" > src/Makefile.local
2016-09-08 21:13:10 +04:00
- make -j4
artifacts:
expire_in: 1 week
untracked: true
build:test:
stage: build_test
tags:
- tezos_builder
script:
- make -C test build-test -j4
dependencies:
- build
artifacts:
expire_in: 1 week
untracked: true
test:store:
stage: test
tags:
- tezos_builder
script:
- make -C test run-test-store
dependencies:
- build
- build:test
test:context:
stage: test
tags:
- tezos_builder
script:
- make -C test run-test-context
dependencies:
- build
- build:test
test:state:
stage: test
tags:
- tezos_builder
script:
- make -C test run-test-state
dependencies:
- build
- build:test
test:basic:
stage: test
tags:
- tezos_builder
script:
- make -C test run-test-basic
dependencies:
- build
- build:test
test:basic.sh:
stage: test
tags:
- tezos_builder
script:
- make -C test run-test-basic.sh
dependencies:
- build
- build:test
2016-10-19 17:09:00 +04:00
test:data-encoding:
stage: test
tags:
- tezos_builder
script:
- make -C test run-test-data-encoding
dependencies:
- build
- build:test
2017-01-14 16:14:22 +04:00
test:p2p-io-scheduler:
stage: test
tags:
- tezos_builder
script:
- make -C test run-test-p2p-io-scheduler
dependencies:
- build
- build:test
test:p2p-connection:
stage: test
tags:
- tezos_builder
script:
- make -C test run-test-p2p-connection
dependencies:
- build
- build:test
test:p2p-connection-pool:
stage: test
tags:
- tezos_builder
script:
- make -C test run-test-p2p-connection-pool
dependencies:
- build
- build:test
publish:docker:
stage: publish
image: ocp:docker
tags:
- docker_builder
script:
- ./scripts/create_docker_image.sh ${image_name} ${build_image_id}
- docker tag ${image_name}:${build_image_id}
"$CI_REGISTRY_IMAGE:$CI_BUILD_REF_NAME"
- docker login -u gitlab-ci-token -p $CI_BUILD_TOKEN $CI_REGISTRY
- docker push "$CI_REGISTRY_IMAGE:$CI_BUILD_REF_NAME"
- docker rmi "$CI_REGISTRY_IMAGE:$CI_BUILD_REF_NAME"
publish:github:
image: ocaml/opam
stage: publish
2016-09-08 21:13:10 +04:00
tags:
- tezos_builder
only:
- master@tezos/tezos
script:
- echo "${CI_KH}" > ~/.ssh/known_hosts
- echo "${CI_PK_GITHUB}" > ~/.ssh/id_rsa
2016-09-08 21:13:10 +04:00
- chmod 400 ~/.ssh/id_rsa
- rm -fr .git/refs/original
- git filter-branch --prune-empty --index-filter
'git rm -r --cached --ignore-unmatch
.gitlab-ci.yml
"docs/proof of stake.md"
src/client/embedded/bootstrap/mining/'
--env-filter
2016-09-21 17:36:45 +04:00
'if [ $GIT_COMMIT != "f42e9d12ac75d2876a4cf600d44976b7090d4533" ] ; then
export GIT_COMMITTER_NAME="$GIT_AUTHOR_NAME" ;
export GIT_COMMITTER_EMAIL="$GIT_AUTHOR_EMAIL" ;
export GIT_COMMITTER_DATE="$GIT_AUTHOR_DATE" ;
export GIT_AUTHOR_NAME="Dynamic Ledger Solutions, Inc." ;
export GIT_AUTHOR_EMAIL="contact@tezos.com" ;
fi'
2016-09-08 21:13:10 +04:00
HEAD
2017-01-23 14:46:56 +04:00
- git push git@github.com:tezos/tezos.git -f HEAD:master
2016-09-08 21:13:10 +04:00
cleanup:
stage: cleanup
image: ocp:docker
tags:
- docker_builder
script:
- docker tag ${build_image_name}:${build_image_id}
${build_image_name}:${CI_PROJECT_NAMESPACE}_${CI_BUILD_REF_NAME}
- docker rmi ${build_image_name}:${build_image_id}
2016-09-08 21:13:10 +04:00
when: always