Details
-
Type:
Bug
-
Status: Reopened (View Workflow)
-
Priority:
Major
-
Resolution: Unresolved
-
Component/s: job-dsl-plugin
-
Labels:None
-
Environment:Jenkins ver. 2.53,
Build Pipeline Plugin 1.5.6
Pipeline
-
Similar Issues:
Description
Steps to reproduce
- I have created Pipeline job
- During creation I checked up "This project is parameterized" checkbox and added two Choice parameters
- I have run the job and it failed
- I checked the configuration of the job and parameters are no longer there and "This project is parameterized" checkbox is no longer checked up.
Attachments
Issue Links
- causes
-
JENKINS-51038 Re-defining existing job loses environment variables
-
- Closed
-
So if you're not using Job DSL, please open a separate JIRA. If you're using the properties step in Scripted Pipeline or the parameters directive in Declarative, those do try to preserve job properties and build parameters defined outside of the pipeline, but Job DSL is still going to wipe out whatever is in the properties and parameters when it runs its seed job. Also, don't ever call properties step more than once in a pipeline - you're gonna run into a bunch of potential pitfalls there.