.gitlab-ci.yml 2.09 KB
Newer Older
1
image: dorie/dune-env:2.5.1
Dion Haefner's avatar
Dion Haefner committed
2

Dion Haefner's avatar
Dion Haefner committed
3 4 5 6 7
variables:
  DUNE_CONTROL_PATH: /opt/dune:$CI_PROJECT_DIR

before_script:
  - cd /opt/dune
Dion Haefner's avatar
Dion Haefner committed
8

Dion Haefner's avatar
Dion Haefner committed
9
stages:
10
  - build
11
  - test
12
  - deploy
Dion Haefner's avatar
Dion Haefner committed
13

14
build:main:
15
  stage: build
16
  tags:
17
    - demeter
Dion Haefner's avatar
Dion Haefner committed
18
  script:
19
    - CMAKE_FLAGS="-DDUNE_PYTHON_VIRTUALENV_SETUP=True -DDUNE_PYTHON_ALLOW_GET_PIP=True" MAKE_FLAGS="-j 2" ./dune-common/bin/dunecontrol --only=dorie all
20
  artifacts:
21
    name: "$CI_JOB_NAME"
22
    paths:
23 24
      - $CI_PROJECT_DIR/build-cmake
    expire_in: 3 days
25

26
build:update_dune:
27
  stage: build
28
  tags:
29
    - demeter
30
  script:
31
    - ./dune-common/bin/dunecontrol update
32
    - ./dune-common/bin/dunecontrol exec "rm -rf build-cmake"
33 34 35 36 37 38
    - CMAKE_FLAGS="-DDUNE_PYTHON_VIRTUALENV_SETUP=True -DDUNE_PYTHON_ALLOW_GET_PIP=True" MAKE_FLAGS="-j 2" ./dune-common/bin/dunecontrol --module=dorie all
  artifacts:
    name: "$CI_JOB_NAME"
    paths:
      - $CI_PROJECT_DIR/build-cmake
    expire_in: 3 days
39

40
build:debug:
41
  stage: build
42
  tags:
43
    - demeter
44
  script:
45
    - CMAKE_FLAGS="-DCMAKE_BUILD_TYPE=Debug -DDUNE_PYTHON_VIRTUALENV_SETUP=True -DDUNE_PYTHON_ALLOW_GET_PIP=True" MAKE_FLAGS="-j 2" ./dune-common/bin/dunecontrol --only=dorie all
46

47 48
test:main:
  stage: test
49
  tags:
50
    - demeter
51 52 53
  dependencies:
    - build:main
  allow_failure: true
54
  script:
55 56 57 58 59 60 61 62 63 64 65
    - ./dune-common/bin/dunecontrol --only=dorie configure
    - ARGS="--output-on-failure -j 2" ./dune-common/bin/dunecontrol --only=dorie make test
  artifacts:
    name: "$CI_JOB_NAME"
    paths:
      - $CI_PROJECT_DIR/build-cmake/Testing
    expire_in: 1 week

test:update_dune:
  stage: test
  tags:
66
    - demeter
67 68
  dependencies:
    - build:update_dune
69
  allow_failure: true
70 71 72 73 74 75 76 77 78 79 80 81
  script:
    - ./dune-common/bin/dunecontrol --only=dorie configure
    - ARGS="--output-on-failure -j 2" ./dune-common/bin/dunecontrol --only=dorie make test
  artifacts:
    name: "$CI_JOB_NAME"
    paths:
      - $CI_PROJECT_DIR/build-cmake/Testing
    expire_in: 1 week

deploy:build_docs:
  stage: deploy
  tags:
82
    - demeter
83 84 85 86 87
  dependencies:
    - build:main
  script:
    - ./dune-common/bin/dunecontrol --only=dorie configure
    - ./dune-common/bin/dunecontrol --only=dorie make doc