Skip to content
Snippets Groups Projects
Commit 8e04e2e5 authored by OZGCloud's avatar OZGCloud
Browse files

OZG-4792 Set build profile

parent ca4d1609
No related branches found
No related tags found
No related merge requests found
......@@ -78,7 +78,7 @@ pipeline {
configFileProvider([configFile(fileId: 'maven-settings', variable: 'MAVEN_SETTINGS')]) {
withCredentials([usernamePassword(credentialsId: 'jenkins-nexus-login', usernameVariable: 'USER', passwordVariable: 'PASSWORD')]) {
sh 'mvn -s $MAVEN_SETTINGS spring-boot:build-image -DskipTests -Dmaven.wagon.http.retryHandler.count=3 -P $BUILD_PROFILE -Ddocker.publishRegistry.username=${USER} -Ddocker.publishRegistry.password=${PASSWORD}'
sh 'mvn -s $MAVEN_SETTINGS spring-boot:build-image -DskipTests -Dmaven.wagon.http.retryHandler.count=3 $BUILD_PROFILE -Ddocker.publishRegistry.username=${USER} -Ddocker.publishRegistry.password=${PASSWORD}'
}
}
}
......@@ -166,11 +166,11 @@ String getPomVersion() {
String getBuildProfile() {
if (isMasterBranch()) {
return "dev"
return "-P dev"
} else if (isReleaseBranch()) {
return "release"
return "-P release"
} else {
return "feature"
return ""
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment