-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy path.gitlab-ci.yml
59 lines (56 loc) · 1.9 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
stages:
- check
- basebuild
- build
rpm-check:
stage: check
script:
- ~/bin/perfecto bridge.spec
- docker --version
build-dist:
stage: basebuild
script:
- ./configure --with-slurm --with-slurm-lib
- make
- make dist
artifacts:
paths:
- bridge-*.tar.gz
expire_in: 1 week
# Building bridge for different systems with different version of slurm.
# Slurm versions must be named as they are in schedMD's download web site.
# DISTRIBUTION refers to a directory under `build` directory.
# The docker process of building must put the results of the build into
# a /dist directory that will be extracted.
build-parametric:
parallel:
matrix:
- DISTRIBUTION: [almalinux8, almalinux9]
SLURM: [slurm-24.05.0, slurm-23.11.8, slurm-22.05.11]
stage: build
script:
# we use a directory named against $DISTRIBUTION in which we have
# our Dockerfile used to build bridge
- cd build/$DISTRIBUTION
# Getting slurm form the source
- https_proxy='http://webproxy:3128' curl -O https://download.schedmd.com/slurm/$SLURM.tar.bz2
# Extracting slurm.spec from source to be used in the Dockerfiles
- tar jOxvf $SLURM.tar.bz2 $SLURM/slurm.spec > slurm.spec
# Copying bridge source and bridge spec file built in build-dist job
- cp ../../bridge-*.tar.gz .
- cp ../../bridge.spec .
# Creating the directory where we will put our builds results
- mkdir $DISTRIBUTION-$SLURM
# Building with a tag in order to be able to run it
- docker build -t $DISTRIBUTION-$SLURM .
# Running the build to extract the /dist directory
- docker run --rm $DISTRIBUTION-$SLURM tar -cC /dist . | tar -xC $DISTRIBUTION-$SLURM/
# Moving it to get cleaner artifacts
- mv $DISTRIBUTION-$SLURM/ ../../
artifacts:
name: $DISTRIBUTION-$SLURM
paths:
- $DISTRIBUTION-$SLURM/bridge-*.rpm
expire_in: 1 week
dependencies:
- build-dist