diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 5805bb7b02e2ef95089a728a1b5f9e44baadf649..4d0c0ae173a1b595b488e9958fee40fb19f05602 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -137,7 +137,7 @@ deploySnapshot: only: - develop -deployCentral: +.template_deployCentral: image: eclipse-temurin:17.0.12_7-jdk stage: deploy before_script: @@ -152,10 +152,18 @@ deployCentral: - 'which gpg || ( apt-get update -qy && apt-get install gnupg -qqy )' - export GPG_TTY=$(tty) - gpg -v --batch --import <(echo "${GPG_PRIVATE_KEY}") - script: - git config --global user.email "$env:GITLAB_USER_EMAIL" - git config --global user.name "$env:GITLAB_USER_NAME" - git checkout -B "$CI_COMMIT_REF_NAME" + script: + - mvn $MAVEN_CLI_OPTS release:prepare -DautoVersionSubmodules=true -Dmaven.test.skip=true -DscmCommentPrefix="[skip ci]" -DupdateWorkingCopyVersions=false -DpushChanges=false -DskipTests + - mvn $MAVEN_CLI_OPTS release:perform -Darguments=-Dgpg.passphrase=${GPG_PASSPHRASE} -DlocalCheckout=true -DskipTests -Dmaven.test.skip=true + tags: + - stable + +deployCentral: + extends: .template_deployCentral + script: - mvn $MAVEN_CLI_OPTS release:prepare -DautoVersionSubmodules=true -Dmaven.test.skip=true -DscmCommentPrefix="[skip ci]" -DupdateWorkingCopyVersions=false -DpushChanges=false -DskipTests - mvn $MAVEN_CLI_OPTS release:perform -Darguments=-Dgpg.passphrase=${GPG_PASSPHRASE} -DlocalCheckout=true -DskipTests -Dmaven.test.skip=true only: @@ -163,6 +171,14 @@ deployCentral: tags: - stable +deployCentralDryRun: + extends: .template_deployCentral + script: + - mvn $MAVEN_CLI_OPTS release:prepare -DautoVersionSubmodules=true -Dmaven.test.skip=true -DscmCommentPrefix="[skip ci]" -DupdateWorkingCopyVersions=false -DpushChanges=false -DskipTests -DdryRun + - mvn $MAVEN_CLI_OPTS release:perform -Darguments=-Dgpg.passphrase=${GPG_PASSPHRASE} -DlocalCheckout=true -DskipTests -Dmaven.test.skip=true -DdryRun + tags: + - stable + buildSingularity: stage: build-containers image: