Commit 0d140339 authored by Lukas Riedel's avatar Lukas Riedel

Rework CI pipeline and set triggers for jobs

* setup:dune-env only executes for 'Run pipeline' trigger
* prep:update-dune only runs for master and tags
* deploy jobs only run for master and tags
* split deploy jobs into two cases for master and tags, respectively
parent 4bc526d1
......@@ -24,6 +24,8 @@ stages:
setup:dune-env:
stage: setup
only:
- web # activate through 'Run pipeline' only.
tags:
- dind
image: docker:stable
......@@ -39,6 +41,9 @@ setup:dune-env:
prep:update-dune:
stage: prep
only:
- master
- tags
tags:
- dind
image: docker:stable
......@@ -68,26 +73,6 @@ build:main:
- $CI_PROJECT_DIR/build-cmake
expire_in: 1 day
build:update_dune:
stage: build
tags:
- multicore
only:
- master
script:
- $DUNECONTROL update
- $DUNECONTROL exec "rm -rf build-cmake"
- CMAKE_FLAGS="$CMAKE_FLAGS"
MAKE_FLAGS="$MAKE_FLAGS"
$DUNECONTROL --module=dorie all
- MAKE_FLAGS="$MAKE_FLAGS"
$DUNECONTROL --only=dorie make build_tests
artifacts:
name: "$CI_JOB_NAME"
paths:
- $CI_PROJECT_DIR/build-cmake
expire_in: 1 day
build:debug:
stage: build
allow_failure: true
......@@ -129,21 +114,6 @@ test:ode:
- $CI_PROJECT_DIR/build-cmake/Testing
expire_in: 1 day
test:ode-update_dune:
stage: test
dependencies:
- build:update_dune
only:
- master
script:
- $DUNECONTROL --only=dorie configure
- $DUNECONTROL --only=dorie make test_run_ode
artifacts:
name: "$CI_JOB_NAME"
paths:
- $CI_PROJECT_DIR/build-cmake/Testing
expire_in: 1 day
test:parallel:
stage: test
dependencies:
......@@ -185,8 +155,10 @@ test:mass_conserve:
- $CI_PROJECT_DIR/build-cmake/Testing
expire_in: 1 day
deploy:docker:
deploy:dockerhub-devel:
stage: deploy
only:
- master
tags:
- dind
image: docker:stable
......@@ -199,3 +171,20 @@ deploy:docker:
script:
- docker build --build-arg PROCNUM=$DIND_PROCNUM -f dockerfiles/dorie -t dorie/dorie:devel .
- docker push dorie/dorie:devel
deploy:dockerhub-stable:
stage: deploy
only:
- tags
tags:
- dind
image: docker:stable
services:
- docker:dind
variables:
DOCKER_DRIVER: overlay2
before_script:
- $DOCKER_LOGIN
script:
- docker build --build-arg PROCNUM=$DIND_PROCNUM -f dockerfiles/dorie -t dorie/dorie:$CI_COMMIT_TAG .
- docker push dorie/dorie:$CI_COMMIT_TAG
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