- How do I create a custom builder with the templates plugin?
- How do I create a custom publisher with the templates plugin?
- CloudBees Jenkins Enterprise
- CloudBees Template plugin
The CloudBees template plugin allows you to create custom build or publish step which can be used in other Jenkins projects.
Note: The instructions below are for a new builder, however the same configuration also applies to a publisher (post build action) as well.
Steps to create a new builder/publisher:
- Go to New Item > and select the Builder/Publisher template
- Under the attributes section add all of the attributes you would like to configure. Attributes are the options when you navigate to the job configuration page. This allows you to customize the builder configuration.
- Once you configure all of the attributes, then configure a Shell/Batch script. This part you can put any shell or batch operation you would like this plugin to use. If you would like to use the attribute values from step 2, then you can obtain that information by doing
AttributeIDis the ID of the attribute.
- Save the configuration.
When you navigate to any new project the builder template that was made above should now be available in the build section.