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

Jenkins CLI does not support filesystem-list-paramter-plugin

    • 0.0.16

      Hello,

      when i want to start a build job that contains a file selection paramter over the jenkins-cli, i get the following message:

      ERROR: CLI parameter submission is not supported for the class alex.jenkins.plugins.FileSystemListParameterDefinition type. Please file a bug report for this

       

      When I start a build over the Rest-API it always select the first File in the Elements-List and not the Element i specified in the Post-Message.

          [JENKINS-60978] Jenkins CLI does not support filesystem-list-paramter-plugin

          Daniele added a comment -

          Hello aendter, do you plan to fix this issue?

          Daniele added a comment - Hello aendter , do you plan to fix this issue?

          Which version of jenkins and the plugin you are using?

          Please provide more information to reproduce the issue.

          Alexander Endter added a comment - Which version of jenkins and the plugin you are using? Please provide more information to reproduce the issue.

          Daniele added a comment -

          Jenkins 2.462.3 and 2.479.1 with Filesystem List Parameter Plug-in Version 0.0.14.

          Please also see JENKINS-74886

           

          Daniele added a comment - Jenkins 2.462.3 and 2.479.1 with Filesystem List Parameter Plug-in Version 0.0.14. Please also see JENKINS-74886  

          I'm not sure what the problem is. I have tried this - step by step:

          # create dirs 1_first and 2_second and a job testFSJob with mentioned parameters "my_param" and "my_param_reverseorder"
          
          export JENKINS_URL=http://localhost:8080/jenkins
          export JOB_NAME=testFSJob
          curl -s -X GET $JENKINS_URL/crumbIssuer/api/json --user ***:***|jq '.'
          {
            "_class": "hudson.security.csrf.DefaultCrumbIssuer",
            "crumb": "***",
            "crumbRequestField": "Jenkins-Crumb"
          }
          
          ## use crumb
          curl -s -X POST $JENKINS_URL/job/$JOB_NAME/build \
            --user ***:*** -H 'Jenkins-Crumb: ***' \
            --data-urlencode json='{"parameter": [{"name":"my_param", "value":"2_second"}, {"name":"my_param_reverseorder", "value":"2_second"}]}'
          

           

          I played around - everytime working fine. You can try that..

          Alexander Endter added a comment - I'm not sure what the problem is. I have tried this - step by step: # create dirs 1_first and 2_second and a job testFSJob with mentioned parameters "my_param" and "my_param_reverseorder" export JENKINS_URL=http: //localhost:8080/jenkins export JOB_NAME=testFSJob curl -s -X GET $JENKINS_URL/crumbIssuer/api/json --user ***:***|jq '.' {   "_class" : "hudson.security.csrf.DefaultCrumbIssuer" ,   "crumb" : "***" ,   "crumbRequestField" : "Jenkins-Crumb" } ## use crumb curl -s -X POST $JENKINS_URL/job/$JOB_NAME/build \   --user ***:*** -H 'Jenkins-Crumb: ***' \   --data-urlencode json= '{ "parameter" : [{ "name" : "my_param" , "value" : "2_second" }, { "name" : "my_param_reverseorder" , "value" : "2_second" }]}'   I played around - everytime working fine. You can try that..

          Daniele added a comment -

          I confirm that this syntax is working for me as well.

          Previously I was trying with $JENKINS_URL/job/$JOB_NAME/buildWithParameters and could not make it work.

          Thanks

           

          Daniele added a comment - I confirm that this syntax is working for me as well. Previously I was trying with $JENKINS_URL/job/$JOB_NAME/buildWithParameters and could not make it work. Thanks  

          Fix will be released with 0.0.16. Details see changelog.

           

          Hint from https://wiki.jenkins.io/display/JENKINS/Parameterized+Build:

          http://server/job/myjob/buildWithParameters?token=TOKEN&PARAMETER=Value

          (Note that the & will need to be escaped, or the whole URL quoted, if using a Unix shell script.)

          Alexander Endter added a comment - Fix will be released with 0.0.16. Details see changelog.   Hint from https://wiki.jenkins.io/display/JENKINS/Parameterized+Build : http://server/job/myjob/buildWithParameters?token=TOKEN&PARAMETER=Value (Note that the & will need to be escaped, or the whole URL quoted, if using a Unix shell script. )

            aendter Alexander Endter
            br0grammer Holger
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: