Forked from https://gitlab.com/to-be-continuous/maven at 20240725.
gitlab-ci-maven
include:
- component: $CI_SERVER_FQDN/smartdatalab/public/ci-cd-components/maven/gitlab-ci-maven@4.3.0
Name | Mandatory | Type | Description | Default |
---|---|---|---|---|
opts | false | string | [Global Maven options](http://maven.apache.org/configure.html#maven_opts-environment-variable) | -Dhttps.protocols=TLSv1.2 -Dmaven.repo.local=${MAVEN_CFG_DIR}/repository -Dorg.slf4j.simpleLogger.showDateTime=true -Djava.awt.headless=true |
image | false | string | The Docker image used to run Maven - **set the version required by your project** | registry.hub.docker.com/library/maven:latest |
cfg-dir | false | string | The Maven configuration directory | .m2 |
cli-opts | false | string | Additional [Maven options](https://maven.apache.org/ref/3-LATEST/maven-embedder/cli.html) used on the command line | --no-transfer-progress --batch-mode --errors --fail-at-end --show-version -DinstallAtEnd=true -DdeployAtEnd=true |
build-args | false | string | Maven arguments for the build & test job | org.jacoco:jacoco-maven-plugin:prepare-agent verify org.jacoco:jacoco-maven-plugin:report |
deploy-args | false | string | Maven arguments for the deploy job | deploy -Dmaven.test.skip=true |
project-dir | false | string | Maven project root directory | . |
release-args | false | string | Maven arguments for the release job | release:prepare -DtagNameFormat=@{project.version} -Darguments=-Dmaven.test.skip=true |
sbom-disabled | false | boolean | Disable Software Bill of Materials | false |
sbom-gen-args | false | string | Maven command used for SBOM analysis | org.cyclonedx:cyclonedx-maven-plugin:makeAggregateBom |
settings-file | false | string | The Maven `settings.xml` file path | $MAVEN_CFG_DIR/settings.xml |
deploy-enabled | false | boolean | Enable Publish | false |
sonar-host-url | false | string | SonarQube server url | |
release-version | false | string | Explicit version to use when triggering a release _Otherwise uses the current snapshot version from `pom.xml`)_ | |
sonar-base-args | false | string | SonarQube [analysis arguments](https://docs.sonarsource.com/sonarqube-server/latest/analyzing-source-code/analysis-parameters/) | sonar:sonar -Dsonar.links.homepage=${CI_PROJECT_URL} -Dsonar.links.ci=${CI_PROJECT_URL}/-/pipelines -Dsonar.links.issue=${CI_PROJECT_URL}/-/issues |
mvn-sbom-job-tags | false | array | tags to filter applicable runners for mvn-sbom job | [] |
mvn-build-job-tags | false | array | tags to filter applicable runners for mvn-build job | [] |
mvn-sonar-job-tags | false | array | tags to filter applicable runners for mvn-sonar job | [] |
mvn-release-job-tags | false | array | tags to filter applicable runners for mvn-release job | [] |
dependency-check-args | false | string | Maven arguments for Dependency Check job | org.owasp:dependency-check-maven:aggregate -DretireJsAnalyzerEnabled=false -DassemblyAnalyzerEnabled=false -Dformats=HTML,JSON,XML |
release-scm-dev-comment | false | string | Maven release plugin [scmDevelopmentCommitComment](https://maven.apache.org/maven-release/maven-release-plugin/prepare-mojo.html#scmDevelopmentCommitComment) parameter (since Maven `3.0.0-M1`) | |
dependency-check-disabled | false | boolean | Disable Dependency-Check | false |
release-scm-comment-prefix | false | string | Maven release plugin [scmCommentPrefix](https://maven.apache.org/maven-release/maven-release-plugin/prepare-mojo.html#scmCommentPrefix) parameter | chore(maven-release): |
sonar-quality-gate-enabled | false | boolean | Enables SonarQube [Quality Gate](https://docs.sonarsource.com/sonarqube-server/latest/instance-administration/analysis-functions/quality-gates/) verification. _Uses `sonar.qualitygate.wait` parameter ([see doc](https://docs.sonarsource.com/sonarqube-server/latest/analyzing-source-code/ci-integration/overview/#quality-gate-fails))._ | false |
mvn-deploy-release-job-tags | false | array | tags to filter applicable runners for mvn-deploy-release job | [] |
mvn-semrel-release-disabled | false | string | Disable semantic-release integration | |
release-scm-release-comment | false | string | Maven release plugin [scmReleaseCommitComment](https://maven.apache.org/maven-release/maven-release-plugin/prepare-mojo.html#scmReleaseCommitComment) parameter (since Maven `3.0.0-M1`) | |
mvn-deploy-snapshot-job-tags | false | array | tags to filter applicable runners for mvn-deploy-snapshot job | [] |
mvn-dependency-check-job-tags | false | array | tags to filter applicable runners for mvn-dependency-check job | [] |
mvn-no-snapshot-deps-job-tags | false | array | tags to filter applicable runners for mvn-no-snapshot-deps job | [] |
deploy-from-unprotected-disabled | false | boolean | Set to limit snapshot publication to protected branches | false |
deploy-snapshot-with-slug-enabled | false | boolean | Enable to inject the Git branch slug in SNAPSHOT versions | false |
mvn-forbid-snapshot-dependencies-disabled | false | boolean | Disable Snapshot dependencies verification | false |
gitlab-ci-maven-vault
include:
- component: $CI_SERVER_FQDN/smartdatalab/public/ci-cd-components/maven/gitlab-ci-maven-vault@4.3.0
gitlab-ci-maven-jib
include:
- component: $CI_SERVER_FQDN/smartdatalab/public/ci-cd-components/maven/gitlab-ci-maven-jib@4.3.0
Name | Mandatory | Type | Description | Default |
---|---|---|---|---|
sbom-opts | false | string | Options for syft used for SBOM analysis | --override-default-catalogers rpm-db-cataloger,alpm-db-cataloger,apk-db-cataloger,dpkg-db-cataloger,portage-cataloger,nix-store-cataloger,java |
sbom-image | false | string | registry.hub.docker.com/anchore/syft:debug | |
trivy-args | false | string | Additional [`trivy image` options](https://aquasecurity.github.io/trivy/latest/docs/references/configuration/cli/trivy_image/#options) | --ignore-unfixed --pkg-types os |
trivy-image | false | string | The docker image used to scan images with Trivy | registry.hub.docker.com/aquasec/trivy:latest |
skopeo-image | false | string | The image used to publish images with Skopeo | quay.io/skopeo/stable:latest |
jib-build-args | false | string | [Jib Maven Plugin arguments](https://github.com/GoogleContainerTools/jib/tree/master/jib-maven-plugin#extended-usage) | -Djib.to.image=$MAVEN_JIB_SNAPSHOT_IMAGE |
trivy-disabled | false | boolean | Disable Maven Trivy | false |
jib-publish-args | false | string | Additional [`skopeo copy` arguments](https://github.com/containers/skopeo/blob/master/docs/skopeo-copy.1.md#options) | |
jib-release-image | false | string | Maven Jib Release image | $CI_REGISTRY_IMAGE:$CI_COMMIT_REF_NAME |
mvn-sbom-job-tags | false | array | tags to filter applicable runners for mvn-sbom job | [] |
jib-snapshot-image | false | string | Maven Jib Snapshot image | $CI_REGISTRY_IMAGE/snapshot:$CI_COMMIT_REF_SLUG |
mvn-build-job-tags | false | array | tags to filter applicable runners for mvn-build job | [] |
mvn-trivy-job-tags | false | array | tags to filter applicable runners for mvn-trivy job | [] |
jib-prod-publish-strategy | false | string | Defines the publish to production strategy. | manual |
mvn-deploy-release-job-tags | false | array | tags to filter applicable runners for mvn-deploy-release job | [] |
mvn-deploy-snapshot-job-tags | false | array | tags to filter applicable runners for mvn-deploy-snapshot job | [] |