-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.gitlab-ci.yml
More file actions
89 lines (83 loc) · 2.51 KB
/
.gitlab-ci.yml
File metadata and controls
89 lines (83 loc) · 2.51 KB
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
# ------------------------------------------------------------
# This file is the main CMakeLists of crypt of headcode.space
#
# The 'LICENSE.txt' file in the project root holds the software license.
# Copyright (C) 2020-2021 headcode.space e.U.
# Oliver Maurhart <info@headcode.space>, https://www.headcode.space
# ------------------------------------------------------------
stages:
- build
- package
build:
stage: build
image: registry.gitlab.com/headcode.space/crypt:ubuntu-focal
script:
- git submodule init
- git submodule update
- rm -rf build &> /dev/null
- mkdir -p build
- cd build
- cmake -DBUILD_TESTING=On -DCMAKE_BUILD_TYPE=Debug -DPROFILING_MODE_ENABLED:Bool=On ..
- make
- ctest -VV -F --timeout 10.0
- make run-gcovr
- make package_source
- cd ${CI_PROJECT_DIR}
- sonar-scanner -Dsonar.host.url=${SONAR_HOST} -Dsonar.login=${SONAR_LOGIN}
artifacts:
paths:
- build/*.tar.gz
- build/gcovr-report.xml
name: ${CI_PROJECT_NAME}-sources
coverage: '/^TOTAL.*\s+(\d+\%)$/'
package-debian-buster:
stage: package
image: registry.gitlab.com/headcode.space/crypt:debian-buster
script:
- git submodule init
- git submodule update
- rm -rf build &> /dev/null
- mkdir -p build
- cd build
- cmake -DCMAKE_BUILD_TYPE=Release -DCPACK_GENERATOR=DEB -DCPACK_SYSTEM_NAME=debian-buster -DCI_JOB_TOKEN=$CI_JOB_TOKEN ..
- make
- make package
- make gitlab_push_package
artifacts:
paths:
- build/*.deb
name: ${CI_PROJECT_NAME}-debian-buster
package-ubuntu-focal:
stage: package
image: registry.gitlab.com/headcode.space/crypt:ubuntu-focal
script:
- git submodule init
- git submodule update
- rm -rf build &> /dev/null
- mkdir -p build
- cd build
- cmake -DCMAKE_BUILD_TYPE=Release -DCPACK_GENERATOR=DEB -DCPACK_SYSTEM_NAME=ubuntu-focal -DCI_JOB_TOKEN=$CI_JOB_TOKEN ..
- make
- make package
- make gitlab_push_package
artifacts:
paths:
- build/*.deb
name: ${CI_PROJECT_NAME}-ubuntu-focal
package-fedora32:
stage: package
image: registry.gitlab.com/headcode.space/crypt:fedora32
script:
- git submodule init
- git submodule update
- rm -rf build &> /dev/null
- mkdir -p build
- cd build
- cmake -DCMAKE_BUILD_TYPE=Release -DCPACK_GENERATOR=RPM -DCPACK_SYSTEM_NAME=fedora32 -DCI_JOB_TOKEN=$CI_JOB_TOKEN ..
- make
- make package
- make gitlab_push_package
artifacts:
paths:
- build/*.rpm
name: ${CI_PROJECT_NAME}-fedora32