Given the following simple pipeline
properties([ parameters([ fileParam( description:'', name: 'MYFILE') ]) ]) node('master'){ stage('Clone One') { echo "${MYFILE}" echo params.MYFILE } } It's a simple example, it does show the build as a parametrized build, it ask's for the input file, however, It does not list the file on params object value.
The first echo, returns the name of the file it self, and the second prints out NULL.
Problem, how can I access the actual uploaded file? The upload path? The temporary file name?
parameters([fileParam(...)])andparameters([file(...]})is the same thing, they are short hand forparameters[[$class: 'FileParameterDefinition', ...]](due to symbol definition here; github.com/jenkinsci/jenkins/blob/master/core/src/main/java/…). Please also not the first answer in linked issue, this is an known problem and there is an open issue, especially note this comment in the issue; issues.jenkins-ci.org/browse/…