60 lines
1.1 KiB
YAML
60 lines
1.1 KiB
YAML
variables:
|
|
MVN_OPTS: >-
|
|
--batch-mode
|
|
--errors
|
|
--fail-at-end
|
|
--show-version
|
|
--no-transfer-progress
|
|
-DinstallAtEnd=true
|
|
-DdeployAtEnd=true
|
|
-Dsonar.host.url=$SONAR_URL
|
|
-Dsonar.token=$SONAR_TOKEN
|
|
-Dsonar.projectKey=EasyDrop
|
|
-Dhttps.protocols=TLSv1.2
|
|
-Dorg.slf4j.simpleLogger.showDateTime=true
|
|
-Djava.awt.headless=true
|
|
|
|
image: maven:3.9.1-eclipse-temurin-17
|
|
|
|
cache:
|
|
key: "$CI_JOB_NAME"
|
|
paths:
|
|
- .m2/repository
|
|
|
|
stages:
|
|
- build
|
|
- test
|
|
- analyze
|
|
- document
|
|
|
|
build:
|
|
stage: build
|
|
script:
|
|
- echo "Starting Maven build..."
|
|
- mvn $MVN_OPTS clean compile
|
|
|
|
test:
|
|
stage: test
|
|
script:
|
|
- echo "Starting Maven Test..."
|
|
- mvn $MVN_OPTS test
|
|
|
|
analyze:
|
|
stage: analyze
|
|
script:
|
|
- echo "Starting Code Analysis..."
|
|
- mvn $MVN_OPTS verify sonar:sonar -Pcoverage
|
|
|
|
document:
|
|
stage: document
|
|
script:
|
|
- echo "Starting Doc Generation..."
|
|
- apt-get update && apt-get install -y graphviz
|
|
- mvn clean compile
|
|
- mvn $MVN_OPTS generate-resources -Pgenerate-docs
|
|
- cp target/generated-docs/easydrop.png uml.png
|
|
artifacts:
|
|
paths:
|
|
- uml.png
|
|
name: UML
|