Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-39344

Publish over CIFS - Please provide pipeline compatibility

    XMLWordPrintable

    Details

    • Similar Issues:

      Description

      Maybe see https://github.com/jenkinsci/pipeline-plugin/blob/master/COMPATIBILITY.md for details.

      Currently publish-over-cifs does not show up as a top level step and also does not show up as a General Build Step (under step).

        Attachments

          Activity

          cobexer Ing. Christoph Obexer created issue -
          Hide
          bdominguez Borja Domínguez added a comment -

          Any news? This plugin has many downloads and I don't understand why it doesn't support Pipeline.

          It applies also to FTP, Dropbox, SSH, plugins as well.

          Show
          bdominguez Borja Domínguez added a comment - Any news? This plugin has many downloads and I don't understand why it doesn't support Pipeline. It applies also to FTP, Dropbox, SSH, plugins as well.
          Hide
          getrostt Tobias Getrost added a comment -

          See PR 5

          Show
          getrostt Tobias Getrost added a comment - See PR 5
          slide_o_mix Alex Earl made changes -
          Field Original Value New Value
          Assignee bap [ bap ] Alex Earl [ slide_o_mix ]
          Hide
          alexkoepke Alex Koepke added a comment - - edited

          I can't seem to get this working. getting a the following error: 
          WorkflowScript: 21: Missing required parameter: "paramPublish"
          Tobias Getrost

          Show
          alexkoepke Alex Koepke added a comment - - edited I can't seem to get this working. getting a the following error:  WorkflowScript: 21: Missing required parameter: "paramPublish" Tobias Getrost
          Hide
          getrostt Tobias Getrost added a comment -

          Hi Alex Koepke,
          could you share your pipeline snippet that is causing the issue?
          Thanks
          Tobias

          Show
          getrostt Tobias Getrost added a comment - Hi Alex Koepke , could you share your pipeline snippet that is causing the issue? Thanks Tobias
          Hide
          alexkoepke Alex Koepke added a comment - - edited

          Hey Tobias Getrost,

           Thanks for the quick reply!  

          pipeline {
              agent any
              stages {
                  stage('Build') {
                      steps {
                          bat 'npm run vendorinstall'
                          bat 'gulp release'
                          bat 'gulp bs_release'
                      }
                  }
                  stage('Deploy') {
                      when {
                          expression {
                              currentBuild.result == null || currentBuild.result == 'SUCCESS'
                          }
                      }
                      steps {
                          echo "Deploy start"
          
                          cifsPublisher masterNodeName:'', alwaysPublishFromMaster: false, continueOnError: false, failOnError: false, publishers: [[configName: 'Foo', transfers: [[cleanRemote: true, excludes: '**/obj/**,**/node_modules/**,**/_src/**,**/_config/**,**/_sassdocs/**', flatten: false, makeEmptyDirs: false, noDefaultExcludes: false, patternSeparator: '[, ]+', remoteDirectory: 'site/root', remoteDirectorySDF: false, removePrefix: '', sourceFiles: '**/*']], usePromotionTimestamp: false, useWorkspaceInPromotion: false, verbose: false]]
                      }
                  }
              }
          }
          

           

           

          Show
          alexkoepke Alex Koepke added a comment - - edited Hey Tobias Getrost ,  Thanks for the quick reply!   pipeline { agent any stages { stage( 'Build' ) { steps { bat 'npm run vendorinstall' bat 'gulp release' bat 'gulp bs_release' } } stage( 'Deploy' ) { when { expression { currentBuild.result == null || currentBuild.result == 'SUCCESS' } } steps { echo "Deploy start" cifsPublisher masterNodeName: '', alwaysPublishFromMaster: false , continueOnError: false , failOnError: false , publishers: [[configName: ' Foo ', transfers: [[cleanRemote: true , excludes: ' **/obj /**,**/ node_modules /**,**/ _src /**,**/ _config /**,**/ _sassdocs /** ', flatten: false , makeEmptyDirs: false , noDefaultExcludes: false , patternSeparator: ' [, ]+ ', remoteDirectory: ' site/root ', remoteDirectorySDF: false , removePrefix: ' ', sourceFiles: ' **/ *']], usePromotionTimestamp: false , useWorkspaceInPromotion: false , verbose: false ]] } } } }    
          getrostt Tobias Getrost made changes -
          Assignee Alex Earl [ slide_o_mix ] Tobias Getrost [ getrostt ]
          Hide
          getrostt Tobias Getrost added a comment -

          Hi Alex Koepke,
          what version of Jenkins and Pipeline are you using? Could you provide me the list of plugins and versions installed?

          I tested it this morning with Jenkins 2.89.2 and it worked without an error.

          Best regards
          Tobias

          Show
          getrostt Tobias Getrost added a comment - Hi Alex Koepke , what version of Jenkins and Pipeline are you using? Could you provide me the list of plugins and versions installed? I tested it this morning with Jenkins 2.89.2 and it worked without an error. Best regards Tobias
          Hide
          getrostt Tobias Getrost added a comment - - edited

          Hi Alex Koepke,
          I run into the issue as well. It is related to declarative pipeline. I am still figuring out what exactly goes wrong.

          As a workaround you can wrap the cifsPublisher step in a script block

           

          script {
             cifsPublisher masterNodeName:'', alwaysPublishFromMaster: false, continueOnError: false, failOnError: false, publishers: [[configName: 'Foo', transfers: [[cleanRemote: true, excludes: '*/obj/,/node_modules/,/_src/,/_config/,/_sassdocs/', flatten: false, makeEmptyDirs: false, noDefaultExcludes: false, patternSeparator: '[, ]+', remoteDirectory: 'site/root', remoteDirectorySDF: false, removePrefix: '', sourceFiles: '/']], usePromotionTimestamp: false, useWorkspaceInPromotion: false, verbose: false]]
          }

          or set the parameter to null (that is what happens when the step is called from a scripted pipeline):

          cifsPublisher paramPublish: null, masterNodeName:'', alwaysPublishFromMaster: false, continueOnError: false, failOnError: false, publishers: [[configName: 'Foo', transfers: [[cleanRemote: true, excludes: '*/obj/,/node_modules/,/_src/,/_config/,/_sassdocs/', flatten: false, makeEmptyDirs: false, noDefaultExcludes: false, patternSeparator: '[, ]+', remoteDirectory: 'site/root', remoteDirectorySDF: false, removePrefix: '', sourceFiles: '/']], usePromotionTimestamp: false, useWorkspaceInPromotion: false, verbose: false]]
          

          xx

          Show
          getrostt Tobias Getrost added a comment - - edited Hi Alex Koepke , I run into the issue as well. It is related to declarative pipeline. I am still figuring out what exactly goes wrong. As a workaround you can wrap the cifsPublisher step in a script block   script {    cifsPublisher masterNodeName: '', alwaysPublishFromMaster: false , continueOnError: false , failOnError: false , publishers: [[configName: ' Foo ', transfers: [[cleanRemote: true , excludes: ' */obj/,/node_modules/,/_src/,/_config/,/_sassdocs/ ', flatten: false , makeEmptyDirs: false , noDefaultExcludes: false , patternSeparator: ' [, ]+ ', remoteDirectory: ' site/root ', remoteDirectorySDF: false , removePrefix: ' ', sourceFiles: ' /']], usePromotionTimestamp: false , useWorkspaceInPromotion: false , verbose: false ]] } or set the parameter to null (that is what happens when the step is called from a scripted pipeline): cifsPublisher paramPublish: null , masterNodeName: '', alwaysPublishFromMaster: false , continueOnError: false , failOnError: false , publishers: [[configName: ' Foo ', transfers: [[cleanRemote: true , excludes: ' */obj/,/node_modules/,/_src/,/_config/,/_sassdocs/ ', flatten: false , makeEmptyDirs: false , noDefaultExcludes: false , patternSeparator: ' [, ]+ ', remoteDirectory: ' site/root ', remoteDirectorySDF: false , removePrefix: ' ', sourceFiles: ' /']], usePromotionTimestamp: false , useWorkspaceInPromotion: false , verbose: false ]] xx
          Hide
          alexkoepke Alex Koepke added a comment - - edited

          Hey Tobias Getrost,

          Thank you so much! I found using

          paramPublish:[parameterName:''],

          worked as well (without the putting it in a script block.

          Next step is to figure out how to bust this out into multiple lines!
          Wrapping it in a script block allowed me to break it out in to multiple lines.

          Thank you so much,
          Alex

          Show
          alexkoepke Alex Koepke added a comment - - edited Hey Tobias Getrost , Thank you so much! I found using paramPublish:[parameterName:''], worked as well (without the putting it in a script block. Next step is to figure out how to bust this out into multiple lines! Wrapping it in a script block allowed me to break it out in to multiple lines. Thank you so much, Alex
          Show
          getrostt Tobias Getrost added a comment - I just submitted two PRs to fix the issue: https://github.com/jenkinsci/publish-over-plugin/pull/7 https://github.com/jenkinsci/publish-over-cifs-plugin/pull/7
          Hide
          scm_issue_link SCM/JIRA link daemon added a comment -

          Code changed in jenkins
          User: Alex Earl
          Path:
          pom.xml
          src/main/java/jenkins/plugins/publish_over_cifs/CifsPublisher.java
          src/main/java/jenkins/plugins/publish_over_cifs/CifsPublisherPlugin.java
          http://jenkins-ci.org/commit/publish-over-cifs-plugin/fcc34c73536a1ce23393192b61c49ae2e6971507
          Log:
          Merge pull request #7 from getrostt/Bugfix/JENKINS-39344

          Fix issue JENKINS-39344

          Compare: https://github.com/jenkinsci/publish-over-cifs-plugin/compare/546f020c40fc...fcc34c73536a

          Show
          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Alex Earl Path: pom.xml src/main/java/jenkins/plugins/publish_over_cifs/CifsPublisher.java src/main/java/jenkins/plugins/publish_over_cifs/CifsPublisherPlugin.java http://jenkins-ci.org/commit/publish-over-cifs-plugin/fcc34c73536a1ce23393192b61c49ae2e6971507 Log: Merge pull request #7 from getrostt/Bugfix/ JENKINS-39344 Fix issue JENKINS-39344 Compare: https://github.com/jenkinsci/publish-over-cifs-plugin/compare/546f020c40fc...fcc34c73536a
          slide_o_mix Alex Earl made changes -
          Resolution Fixed [ 1 ]
          Status Open [ 1 ] Resolved [ 5 ]

            People

            Assignee:
            getrostt Tobias Getrost
            Reporter:
            cobexer Ing. Christoph Obexer
            Votes:
            7 Vote for this issue
            Watchers:
            9 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: