-
Notifications
You must be signed in to change notification settings - Fork 1
/
.gitlab-ci.yml
66 lines (59 loc) · 1.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
include:
- template: SAST.gitlab-ci.yml
- template: Dependency-Scanning.gitlab-ci.yml
- template: License-Management.gitlab-ci.yml
image: maven:3-jdk-8
# These are the default stages.
# You don't need to explicitly define them.
# But you could define any stages you want.
stages:
- build
- release
- deploy
- test
cache:
paths:
- .m2/
variables:
MAVEN_OPTS: "-Dmaven.repo.local=.m2/repository"
CONTAINER_RELEASE_IMAGE: $CI_REGISTRY_IMAGE:latest
build:
stage: build
script:
- "mvn clean install -Dmaven.test.skip=true"
artifacts:
when: on_success
paths:
- target/
release-image:
image: docker:git
before_script:
- echo "$CI_REGISTRY_PASSWORD" | docker login -u "$CI_REGISTRY_USER" "$CI_REGISTRY" --password-stdin
services:
- docker:dind
stage: release
script:
# - docker pull $CONTAINER_TEST_IMAGE
# - docker tag $CONTAINER_TEST_IMAGE $CONTAINER_RELEASE_IMAGE
# - docker run --rm -v "$PWD":/app -w /app maven:3-jdk-8 mvn clean install
- docker build -t $CONTAINER_RELEASE_IMAGE .
- docker push $CONTAINER_RELEASE_IMAGE
# tags:
# - docker
only:
- master
pages:
stage: deploy
image: ubuntu:latest
before_script:
- apt-get update
- apt-get install doxygen graphviz -y
script:
- cd docs
- doxygen Doxyfile
- mv html ../public
artifacts:
paths:
- public
only:
- master