Can not use envInjectJobProperty in a MultiJob

310 views
Skip to first unread message

Mark Eisenblätter

unread,
Apr 19, 2017, 10:02:55 AM4/19/17
to job-dsl-plugin
Hello List,

it look like i am note able to get the envInjectJobProperty working in a Multijob.

 I try to add                                                                 
properties { 
  envInjectJobProperty {                                                       
   keepBuildVariables(true)                                                  
   keepJenkinsSystemVariables(true)                                          
   info {                                                                    
     propertiesContent('KEY=VALUE')
   }                                                                         
  }                                                                           
}

to a multijob but i get everytime:

ERROR: (puppet.groovy, line 77) the following options are required and must be specified: propertiesFilePath, scriptFilePath, scriptContent, loadFilesFromMaster, secureGroovyScript

but i don't need any of this.

But if i try 

properties { 
  envInjectJobProperty {                                                       
   keepBuildVariables(true)                                                  
   keepJenkinsSystemVariables(true)                                          
   info {
     secureGroovyScript('')                                                             
     propertiesContent('KEY=VALUE')
   }                                                                         
  }                                                                           
}
i get 
ERROR: (puppet.groovy, line 78) No signature of method: javaposse.jobdsl.plugin.structs.DescribableContext.groovyScriptContent() is applicable for argument types: () values: []

so no idea what is wrong.

Using Jenkins 2.19.4 newest Job DSL Plugin and envinject 2.0

Via gui it is no problem to add only propertiesContent

Any ideas?

Thank in advanced 
Mark
 



Mark Eisenblätter

unread,
Apr 19, 2017, 10:09:35 AM4/19/17
to job-dsl-plugin
Ok just found that info is also a required block?!

Daniel Spilker

unread,
Apr 28, 2017, 12:06:03 PM4/28/17
to job-dsl...@googlegroups.com
Some settings are marked as required by plugins although not strictly necessary. You need to specify the options, but you can provide default or empty values, depending on the plugin. Have a look at the embedded API viewer for the exact syntax. See https://github.com/jenkinsci/job-dsl-plugin/wiki/Automatically-Generated-DSL for details.

Daniel

--
You received this message because you are subscribed to the Google Groups "job-dsl-plugin" group.
To unsubscribe from this group and stop receiving emails from it, send an email to job-dsl-plugin+unsubscribe@googlegroups.com.
To post to this group, send email to job-dsl-plugin@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/job-dsl-plugin/6fa1c742-f7fb-4b5d-86e1-530e577ac55e%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages