-
Notifications
You must be signed in to change notification settings - Fork 0
/
.gitlab-ci.yml
113 lines (98 loc) · 2.32 KB
/
.gitlab-ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
image: $CONTAINER_TEST_IMAGE
variables:
CONTAINER_TEST_IMAGE: gitlab-registry.mpcdf.mpg.de/$CI_PROJECT_PATH:$CI_BUILD_REF_NAME
OMP_NUM_THREADS: 1
stages:
- build_docker
- test
- release
- demo_runs
build_docker_from_scratch:
only:
- schedules
image: docker:stable
stage: build_docker
before_script:
- ls
script:
- docker login -u gitlab-ci-token -p $CI_BUILD_TOKEN gitlab-registry.mpcdf.mpg.de
- docker build -t $CONTAINER_TEST_IMAGE --no-cache .
- docker push $CONTAINER_TEST_IMAGE
build_docker_from_cache:
except:
- schedules
image: docker:stable
stage: build_docker
before_script:
- ls
script:
- docker login -u gitlab-ci-token -p $CI_BUILD_TOKEN gitlab-registry.mpcdf.mpg.de
- docker build -t $CONTAINER_TEST_IMAGE .
- docker push $CONTAINER_TEST_IMAGE
test_serial:
stage: test
script:
- pytest-3 -q --cov=nifty5 test
- >
python3 -m coverage report --omit "*plot*,*distributed_do*" | tee coverage.txt
- >
grep TOTAL coverage.txt | awk '{ print "TOTAL: "$4; }'
test_mpi:
stage: test
variables:
OMPI_MCA_btl_vader_single_copy_mechanism: none
script:
- mpiexec -n 2 --bind-to none pytest-3 -q test
pages:
stage: release
script:
- sh docs/generate.sh
- mv docs/build/ public/
artifacts:
paths:
- public
only:
- NIFTy_5
before_script:
- python3 setup.py install --user -f
run_ipynb:
stage: demo_runs
script:
- jupyter nbconvert --execute --ExecutePreprocessor.timeout=None demos/Wiener_Filter.ipynb
run_getting_started_1:
stage: demo_runs
script:
- python3 demos/getting_started_1.py
- mpiexec -n 2 --bind-to none python3 demos/getting_started_1.py 2> /dev/null
artifacts:
paths:
- '*.png'
run_getting_started_2:
stage: demo_runs
script:
- python3 demos/getting_started_2.py
- mpiexec -n 2 --bind-to none python3 demos/getting_started_2.py 2> /dev/null
artifacts:
paths:
- '*.png'
run_getting_started_3:
stage: demo_runs
script:
- python3 demos/getting_started_3.py
artifacts:
paths:
- '*.png'
run_bernoulli:
stage: demo_runs
script:
- python3 demos/bernoulli_demo.py
artifacts:
paths:
- '*.png'
run_curve_fitting:
stage: demo_runs
script:
- python3 demos/polynomial_fit.py
artifacts:
paths:
- '*.png'