Commit dcde2597 authored by David Diederich's avatar David Diederich
Browse files

New base rule for GitLab Ultimate scanners, moving the maven cache out of the way

The maven cache might be getting in the way of some of the scanners, so before
they execute, let's move it to its normal place. Later, we have to move it back,
otherwise the cache won't get updated (and might get cleared).
parent 86ed49a5
......@@ -5,32 +5,32 @@ include:
# --------------------------------------------------------------------------------
dependency_scanning:
.ultimate-scanner-config:
stage: test
tags: ['docker-runner']
variables:
MAVEN_REPO_PATH: "$CI_PROJECT_DIR/.m2/repository"
MAVEN_CLI_OPTS: "--batch-mode --settings=$CI_PROJECT_DIR/.mvn/community-maven.settings.xml -Dmaven.repo.local=$CI_PROJECT_DIR/.m2/repository -DskipTests=true"
DS_DISABLE_DIND: "true"
# --------------------------------------------------------------------------------
cache:
paths:
- $MAVEN_REPO_PATH
sast:
stage: test
tags: ['docker-runner']
variables:
MAVEN_CLI_OPTS: "--batch-mode --settings=$CI_PROJECT_DIR/.mvn/community-maven.settings.xml -DskipTests=true"
DS_DISABLE_DIND: "true"
SAST_DISABLE_DIND: "true"
before_script:
- mkdir -p ~/.m2
- mv .m2/repository ~/.m2/
after_script:
- mv ~/.m2/repository .m2/
# --------------------------------------------------------------------------------
license_management:
stage: test
tags: ['docker-runner']
cache:
paths:
- $MAVEN_REPO_PATH
dependency_scanning:
extends: .ultimate-scanner-config
variables:
MAVEN_REPO_PATH: "$CI_PROJECT_DIR/.m2/repository"
MAVEN_CLI_OPTS: "--batch-mode --settings=$CI_PROJECT_DIR/.mvn/community-maven.settings.xml -Dmaven.repo.local=$CI_PROJECT_DIR/.m2/repository -DskipTests=true"
sast:
extends: .ultimate-scanner-config
license_management:
extends: .ultimate-scanner-config
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment