view-cloner

The Jenkins project announced an unresolved security vulnerability affecting the current version of this plugin (why?):

Jenkins plugin that adds a build step for cloning a view and jobs that are visible in it.

Summary

View-cloner is a build step plugin that allows to copy a view and jobs visible in it. In the process of copying job names and configurations can be changed with supplied replacement pattern.

Usage

  1. Create a Freestyle Project and add "View clone" step.
  2. Fill all 5 fields
    1. Absolute url of the view (Absolute url to the view you want to clone)
    2. Niew view name (Name of the view that will be created)
    3. Replace pattern (Comma separated list of oldValue=newValue Example: 1.1-SNAPSHOT=1.2-SNAPSHOT, slave1=slave2, master=release_19)
    4. Username to authenticate with (user needs to have rights to job/view configs and job/view creation).
    5. Password for the user
  3.  Save and Build.

If you have role based security it is advised to create the "view clone job" where simple users cant configure it.

NOTE: Views populated using regex are not supported (jobs will not be cloned)

Examples

 Image heavy

Example was done using Nested and Sectioned view plugins.

 Original view

One of the jobs configuration

View clone step

Execution

Niew view

One of the jobs new configuration


Changelog

1.1 initial release

TO DO

  • Add ability to clone from remote Jenkins instances.
  • Add support for views populated with regex.
  • Allow variables in step configuration