-
Notifications
You must be signed in to change notification settings - Fork 0
/
.gitlab-ci.yml
94 lines (86 loc) · 2.36 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
# this helps speed our Docker containers a bit because by default it uses vfs which is slower
variables:
DOCKER_DRIVER: overlay2
LATEX_IMAGE: listx/texlive:2020
LATEX_MAIN: report.tex
stages:
# - build-image
- build
- test
- deploy
#build-image:
#tags:
#- alpine-docker # here we specify the runner to use
#image: docker
#stage: build-image
#services:
#- docker:dind
#script:
#- docker login -u gitlab-ci-token -p $CI_JOB_TOKEN gitlab-etu.ing.he-arc.ch:5050
#- docker build -t gitlab-etu.ing.he-arc.ch:5050/isc/2021-22/niveau-2/2282-1-projet-p2-il-sp/g1 .
#- docker push gitlab-etu.ing.he-arc.ch:5050/isc/2021-22/niveau-2/2282-1-projet-p2-il-sp/g1
build_job_latex:
stage: build
image: $LATEX_IMAGE
tags:
- alpine-docker
script:
- cp -R ./doc/latex_report-main/* ./
- latexmk -pdf $LATEX_MAIN
artifacts:
paths:
- "*.pdf"
release_job_latex:
stage: deploy
needs:
- job: build_job_latex
artifacts: true
tags:
- alpine-docker
image: registry.gitlab.com/gitlab-org/release-cli:latest
rules:
- if: $CI_COMMIT_TAG
when: never
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
# DEACTIVATED: current runner is outdated. Waiting for an update.
when: never
script:
- echo "Running the release job."
release:
tag_name: $CI_PIPELINE_IID
description: 'Release created using the release-cli.'
build-job:
image:
name: gitlab-etu.ing.he-arc.ch:5050/lucas.perrin1/docker-image-gelo:latest
entrypoint: [ '/bin/bash', '-c', 'ln -snf /bin/bash /bin/sh && /bin/bash -c $0' ]
tags:
- alpine-docker # here we specify the runner to use
stage: build
artifacts:
paths:
- BUILD/Documentation/
script:
- mkdir BUILD
- cd BUILD
- cmake -G "Ninja" ../ArcStreamLabs
- ninja
- ./tests
- cmake --build . --target BuildDoc
test-job:
image:
name: gitlab-etu.ing.he-arc.ch:5050/lucas.perrin1/docker-image-gelo:latest
entrypoint: [ '/bin/bash', '-c', 'ln -snf /bin/bash /bin/sh && /bin/bash -c $0' ]
tags:
- alpine-docker
stage: test
script:
- echo "Running tests..."
deploy-job:
image:
name: gitlab-etu.ing.he-arc.ch:5050/lucas.perrin1/docker-image-gelo:latest
entrypoint: [ '/bin/bash', '-c', 'ln -snf /bin/bash /bin/sh && /bin/bash -c $0' ]
tags:
- alpine-docker
stage: deploy
script:
- echo "Deploying..."