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: ...@@ -5,32 +5,32 @@ include:
# -------------------------------------------------------------------------------- # --------------------------------------------------------------------------------
dependency_scanning: .ultimate-scanner-config:
stage: test stage: test
tags: ['docker-runner'] tags: ['docker-runner']
variables: cache:
MAVEN_REPO_PATH: "$CI_PROJECT_DIR/.m2/repository" paths:
MAVEN_CLI_OPTS: "--batch-mode --settings=$CI_PROJECT_DIR/.mvn/community-maven.settings.xml -Dmaven.repo.local=$CI_PROJECT_DIR/.m2/repository -DskipTests=true" - $MAVEN_REPO_PATH
DS_DISABLE_DIND: "true"
# --------------------------------------------------------------------------------
sast:
stage: test
tags: ['docker-runner']
variables: variables:
MAVEN_CLI_OPTS: "--batch-mode --settings=$CI_PROJECT_DIR/.mvn/community-maven.settings.xml -DskipTests=true" MAVEN_CLI_OPTS: "--batch-mode --settings=$CI_PROJECT_DIR/.mvn/community-maven.settings.xml -DskipTests=true"
DS_DISABLE_DIND: "true"
SAST_DISABLE_DIND: "true" SAST_DISABLE_DIND: "true"
before_script:
- mkdir -p ~/.m2
- mv .m2/repository ~/.m2/
after_script:
- mv ~/.m2/repository .m2/
# -------------------------------------------------------------------------------- # --------------------------------------------------------------------------------
license_management: dependency_scanning:
stage: test extends: .ultimate-scanner-config
tags: ['docker-runner']
cache:
paths:
- $MAVEN_REPO_PATH
variables: sast:
MAVEN_REPO_PATH: "$CI_PROJECT_DIR/.m2/repository" extends: .ultimate-scanner-config
MAVEN_CLI_OPTS: "--batch-mode --settings=$CI_PROJECT_DIR/.mvn/community-maven.settings.xml -Dmaven.repo.local=$CI_PROJECT_DIR/.m2/repository -DskipTests=true"
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