-
Notifications
You must be signed in to change notification settings - Fork 8
/
.gitlab-ci.yml
67 lines (57 loc) · 1.78 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
default:
tags:
- gitlab-org-docker
image: docker:24.0.5
services:
- docker:24.0.5-dind
stages:
- docker-images
- build
variables:
IMAGES_PREFIX: $CI_REGISTRY_IMAGE/env_
DOCKERFILE: ".github/docker/Dockerfile"
build-docker-images-gcc:
stage: docker-images
variables:
COMPILER: "gcc"
script:
- VERSION=$(echo ${COMPILER_VERSION%-*})
- IMAGE_NAME="${IMAGES_PREFIX}${COMPILER}:${VERSION}"
- BASE_IMAGE="gcc:${COMPILER_VERSION}"
- echo $CI_JOB_TOKEN | docker login $CI_REGISTRY -u gitlab-ci-token --password-stdin
- docker pull ${IMAGE_NAME} || echo "Image not found"
- docker build -t ${IMAGE_NAME} --build-arg BASE_IMAGE=${BASE_IMAGE} -f ${DOCKERFILE} .
- docker push ${IMAGE_NAME}
parallel:
matrix:
- COMPILER_VERSION: ["10-bullseye", "11-bullseye", "12-bullseye", "13-bookworm"]
build-docker-images-clang:
stage: docker-images
variables:
COMPILER: "clang"
script:
- VERSION=$(echo ${COMPILER_VERSION%-*})
- IMAGE_NAME="${IMAGES_PREFIX}${COMPILER}:${VERSION}"
- BASE_IMAGE="silkeh/clang:${COMPILER_VERSION}"
- echo $CI_JOB_TOKEN | docker login $CI_REGISTRY -u gitlab-ci-token --password-stdin
- docker pull ${IMAGE_NAME} || echo "Image not found"
- docker build -t ${IMAGE_NAME} --build-arg BASE_IMAGE=${BASE_IMAGE} -f ${DOCKERFILE} .
- docker push ${IMAGE_NAME}
parallel:
matrix:
- COMPILER_VERSION: ["13-bullseye", "14-bullseye", "15-bullseye", "16-bullseye"]
build-gafro:
stage: build
image:
name: ${IMAGES_PREFIX}${COMPILER}:${COMPILER_VERSION}
script:
- mkdir build
- cd build
- cmake ..
- make install
parallel:
matrix:
- COMPILER: gcc
COMPILER_VERSION: [10, 11, 12, 13]
- COMPILER: clang
COMPILER_VERSION: [13, 14, 15, 16]