jstastny-cz commented on code in PR #6047:
URL: 
https://github.com/apache/incubator-kie-drools/pull/6047#discussion_r1717980823


##########
.ci/jenkins/Jenkinsfile.deploy:
##########
@@ -114,28 +114,32 @@ pipeline {
         stage('Deploy drools') {
             steps {
                 script {
-                    withCredentials([usernamePassword(credentialsId: 
env.MAVEN_REPO_CREDS_ID, usernameVariable: 'REPOSITORY_USER', passwordVariable: 
'REPOSITORY_TOKEN')]) {
-                        def installOrDeploy
-                        if (shouldDeployToRepository()) {
-                            installOrDeploy = "deploy -DdeployAtEnd 
-Dapache.repository.username=${REPOSITORY_USER} 
-Dapache.repository.password=${REPOSITORY_TOKEN} -DretryFailedDeploymentCount=5"
-                        } else {
-                            installOrDeploy = 'install'
-                        }
-                        def mavenCommand = getMavenCommand()
-                           .withOptions(env.DROOLS_BUILD_MVN_OPTS ? [ 
env.DROOLS_BUILD_MVN_OPTS ] : [])
-                           .withOptions(env.BUILD_MVN_OPTS_CURRENT ? [ 
env.BUILD_MVN_OPTS_CURRENT ] : [])
-                           .withProperty('maven.test.failure.ignore', true)
-                           .skipTests(params.SKIP_TESTS)
-
-                        if (isRelease()) {
-                            
releaseUtils.gpgImportKeyFromStringWithoutPassword(getReleaseGpgSignKeyCredsId())
-                            mavenCommand.withProfiles(['apache-release'])
-                        }
-
+                    def installOrDeploy
+                    if (shouldDeployToRepository()) {
+                        installOrDeploy = 'deploy -DdeployAtEnd 
-DretryFailedDeploymentCount=5'
+                    } else {
+                        installOrDeploy = 'install'
+                    }
+                    def mavenCommand = getMavenCommand()
+                        .withOptions(env.DROOLS_BUILD_MVN_OPTS ? [ 
env.DROOLS_BUILD_MVN_OPTS ] : [])
+                        .withOptions(env.BUILD_MVN_OPTS_CURRENT ? [ 
env.BUILD_MVN_OPTS_CURRENT ] : [])
+                        .withProperty('maven.test.failure.ignore', true)
+                        .skipTests(params.SKIP_TESTS)
+
+                    if (isRelease()) {
+                        
releaseUtils.gpgImportKeyFromStringWithoutPassword(getReleaseGpgSignKeyCredsId())
+                        mavenCommand.withProfiles(['apache-release'])
+                    } else {
                         configFileProvider([configFile(fileId: 
env.MAVEN_SETTINGS_CONFIG_FILE_ID, variable: 'MAVEN_SETTINGS_FILE')]) {
-                            
mavenCommand.withSettingsXmlFile(MAVEN_SETTINGS_FILE).run("clean 
$installOrDeploy")
+                            
mavenCommand.withSettingsXmlFile(MAVEN_SETTINGS_FILE)

Review Comment:
   This won't ever use this config file, because its existence is bound to the 
surrounding configFileProvider - thus this ends up with -s pointing at 
non-existent file at the time of mavenCommand.run .... I assume nightly is 
broken by this.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to