Setting Up Jenkins Integration

Jenkins is a cross-platform, open source build automation tool for delivery pipelines. Whether your goal is continuous integration or continuous delivery Jenkins can help automate it.

Now, Plutora integrates with Jenkins, to bring you easy-to-set-up, one-click environment creation on the fly.

Jenkins Integration Version 2:

  • Aligns multiple instances of Jenkins with Plutora.
  • Allows multiple jobs to be run for a single Environment.
  • Allows parameter definition.
  • Allows job viewing if there are large numbers of jobs in many folders.

To create an environment with a single click, using Plutora and Jenkins:

  1. Open Jenkins.
  2. Click a blue linked job Name.
    Click to open an item in Jenkins red arrow
  3. Click Configure.
    Click Configure in Jenkins red arrow
  4. Click to select the Trigger builds remotely (e.g., from scripts) checkbox.
    Build Triggers Jenkins red arrow
  5. Type an Authentification Token.
  6. Click Save.

To enable Jenkins Integration and create and enable a new Jenkins integration:

  1. Go to Settings > Customization.
  2. Click Jenkins.
  3. Click to select the Enable Jenkins Integration checkbox to toggle on Jenkins Integration.
  4. Click + New Jenkins Instance at the bottom of the left-hand panel.
  5. Type the Jenkins URL.
  6. Type the Login. (Mandatory field.)
  7. Type the Password. (Mandatory field.)
  8. Click Test Connection.
    If the connection fails, check the Jenkins URL, login, and password.
  9. If the connection is successful, click Create.
  10. Enable the new instance by clicking the OFF toggle switch in the left-hand panel until it is blue and ON.

Jenkins Integration now retrieves only the top level (root) folder of Jenkins jobs and the contents of folders are only retrieved when clicked. This minimizes the level of data coming back in response requests and prevents timeouts. 

To enable Jenkins jobs in the new Jenkins instance:

  1. Click Fetch Jobs. The Job Names column should populate with jobs and jobs folders.

    Jenkins now retrieves a job token at runtime, so there is no need to predefine one.
  2. Click to select the job checkboxes to enable the jobs.

    Only enabled jobs will appear in the available jobs list in Environments.
  3. Click Save.

To select and sequence the Jenkins jobs to be used by an Environment:

  1. Go to Environments > Environments.
  2. Click to open an Environment.
  3. Click the Release Automation tab:
    • In the left-hand panel are all the jobs that were enabled in Jenkins Integration.
    • In the right-hand Build Sequence panel are the jobs that will be run, in order from top to bottom.
  4. Click to select the Enable Automation checkbox.
  5. Manage Jenkins jobs:
    1. Add jobs:
      1. Drag and drop Jenkins jobs from the left-hand panel to the right-hand Build Sequence panel.
    2. Order jobs:
      1. Drag and drop the Jenkins jobs in the right-hand panel to sort them into build sequence. The jobs at the top of the list are executed first.
    3. Remove jobs:
      1. Click the red X beside the job to remove it from the sequence. (The job will not be deleted.)

Now that Plutora handles more than one Jenkins instance and many jobs, the administrator has to choose which job’s version number will display under the Environment’s Details tab in the Technical Specs and Configuration panel, and in the Continuous Development Pipeline where all the selected jobs will be run, but only the selected job’s version number will appear.

To choose the version number job:

  1. Click to select a checkbox beside a job in the Build Sequence panel.

  1. Add Parameter values:
    1. Click  + Parameters on a Jenkins job in the Build Sequence panel.

      • The Parameters for that job are retrieved from Jenkins.
      • Parameter String Query displays the full list of all the defined Parameters. It is not editable like a text field.
      • Only the following Parameter types are currently supported:
        • Boolean.
        • Choice.
        • Password.
        • String.
        • Text.
    2. Type or select a value for the Parameters.
    3. Click Save & Close.

Now set which of the Environment’s components will be updated:

  1. Click the Details tab.
  2. Click to select a component under the Technical Specs and Configuration panel.
  3. Click Update on Build.

    The component’s icon becomes a Jenkins icon.

    • The component’s Version will contain a build version number when a build is initiated.
    • The Summary Version checkbox beside the Component will be selected automatically.
    • Only one component can be active with Jenkins at a time.
  4. Click Save & Close.

  1. Go to Environments > Environment Requests.
  2. Click the TECR tab.
  3. Click a blue link to open a TECR.
    Environments in the Progression Path of the TECR will contain the Jenkins icon.

    The buttons below the Jenkins icon have the following functions:

    • Jobs: Opens the fields that are also found in the Environment’s Release Automation tab. See sections 4-6 above for how to fill them in.
    • Build: If there is a build that is “Ready to build”, clicking Build will start it.  The “Ready to build” status bar will show the numbered progress through the jobs, for example, 2 of 5.
    • View History: Shows the list of logs from each build. Each job has its own log.
  4. Click Build to build a new environment, to your specifications, on the fly!
  5. Once the build is complete, Jenkins will update the Environment component’s version number.

Currently, data created by Jenkins, such as the build version number, will only exist in Plutora if triggered by Plutora. Any changes made in Jenkins alone will not flow back into Plutora. (Unless the user is viewing the versions in the Pipeline.)

Back to the top arrow

Was this article helpful?

5 found this helpful.