Yes it is in the job configuration for the multibranch pipeline job

Running the following in the script (Jenkinsfile) should add the parameter 
to the branch projects configuration.
properties([[$class: 'ParametersDefinitionProperty', parameterDefinitions: 
[[$class: 'BooleanParameterDefinition',defaultValue: false, description: 
'Description', name: 'PROP_VERIFY']]]])
The next time building "Build with parameter" you can check this parameter, 
but it is not available in the build.

After SECURITY-170 all parameters not defined in the project was no longer 
available. Triggering a downstream build with a parameter not defined was 
not propagated to the downstream build. After adding the parameter it gets 
propagated.


onsdag 22. juni 2016 13.31.01 UTC+2 skrev Björn Pedersen følgende:
>
> Is '../projectA/master' configured to accept parameter PROP_VERIFY (In 
> the job definition, not in the Jenkinsfile)? Else I guess due to SEC-170 
> fixes, the parameter is not propagetd to the environment. Actually that 
> would be a chicken-and-egg type problem. You need to get and execute the 
> current jenkinsfile to see, if the param is allowed, but the param should 
> already be set. See https://jenkins.io/blog/2016/05/11/security-update/ 
> <https://www.google.com/url?q=https%3A%2F%2Fjenkins.io%2Fblog%2F2016%2F05%2F11%2Fsecurity-update%2F&sa=D&sntz=1&usg=AFQjCNHOcwJz3dPWkCdPNVMRq4ZmjHL0aA>
>  
> for details.
>
> The linked issue seem to be a slightly different problem.
>
> Björn
>
> Am Mittwoch, 22. Juni 2016 13:13:48 UTC+2 schrieb Sverre Moe:
>>
>> Have defined parameter for my pipeline projects in the main pipeline 
>> script:
>> properties([[$class: 'ParametersDefinitionProperty', parameterDefinitions
>> : [[$class: 'BooleanParameterDefinition', defaultValue: false, 
>> description: 'Description', name: 'PROP_VERIFY']]]])
>>
>> After building the first time with this I get the option "Build with 
>> Parameters".
>>
>> Doesn't matter how I start a new build. Either manually or in the script:
>> build job: '../projectA/master', parameters: [[$class: 
>> 'BooleanParameterValue', name: 'PROP_VERIFY', value: true]]
>> The environment variable env.PROP_VERIFY is not available. It it always 
>> null.
>>
>> After building I am checking the following URL and can se that the 
>> parameter is set:
>> http://server.company.com:8080/job/projectA/job/master/70/parameters/
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/327d3829-c6e5-4753-8469-bdbda7d1262d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to