27 lines
707 B
Groovy
27 lines
707 B
Groovy
// SPDX-FileCopyrightText: The openTCS Authors
|
|
// SPDX-License-Identifier: MIT
|
|
|
|
publishing {
|
|
repositories {
|
|
if (Boolean.valueOf(project.findProperty('DO_DEPLOY_PRIVATE'))
|
|
&& System.getenv('CI_API_V4_URL') != null
|
|
&& System.getenv('CI_PROJECT_ID') != null
|
|
&& System.getenv('CI_JOB_TOKEN') != null) {
|
|
|
|
maven {
|
|
name = 'deploy-repo-gitlab'
|
|
url = "${System.env.CI_API_V4_URL}/projects/${System.env.CI_PROJECT_ID}/packages/maven"
|
|
|
|
credentials(HttpHeaderCredentials) {
|
|
name = 'Job-Token'
|
|
value = "${System.env.CI_JOB_TOKEN}"
|
|
}
|
|
authentication {
|
|
header(HttpHeaderAuthentication)
|
|
}
|
|
}
|
|
|
|
}
|
|
}
|
|
}
|