Skip to content

UrbanCode/jenkins-pipeline-ucd-plugin

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Overview

This is the IBM UrbanCode Deploy plugin for Jenkins Pipeline (Jenkins 2.0). This plugin is also referred to as the Build Steps plugin since you are able to interact with UrbanCode Deploy via a job step in Jenkins versus a post-processing action. The plugin allows you to upload component versions, create snapshots, and run processes among other things.

More information about this plugin is available here and here.

Installation

The compiled plugin is available for download on the IBM UrbanCode website. Download the plugin from our website if you wish to skip the manual build step. No special steps are required for installation. Otherwise, clone this repository and run the ant command in the top level folder. This should compile the code and create a .hpi file within the /dist folder. Use this command if you wish to make local changes to the plugin. The build process will automatically install Apache Ivy if it is not previously installed.

Support

Plug-ins downloaded directly from the IBM UrbanCode Plug-ins microsite are fully supported by IBM. Create a GitHub Issue or Pull Request for minor requests and bug fixes. For time sensitive issues that require immediate assistance, file a PMR through the normal IBM support channels. Plug-ins built externally or modified with custom code are supported on a best-effort-basis using GitHub Issues.

Locally Build the Plug-in

This open source plug-in uses Gradle as its build tool. Install the latest version of Gradle to build the plug-in locally. Build the plug-in by running the gradle jpi command in the plug-in's root directory. The plug-in distributable will be placed under the build/libs folder.

Pipeline Examples

Full explanation of these Pipeline syntax examples can be found on our Jenkins Pipeline Syntax documentation.

Create Component Version

node {
   step([$class: 'UCDeployPublisher',
        siteName: 'local',
        component: [
            $class: 'com.urbancode.jenkins.plugins.ucdeploy.VersionHelper$VersionBlock',
            componentName: 'Jenkins',
            createComponent: [
                $class: 'com.urbancode.jenkins.plugins.ucdeploy.ComponentHelper$CreateComponentBlock',
                componentTemplate: '',
                componentApplication: 'Jenkins'
            ],
            delivery: [
                $class: 'com.urbancode.jenkins.plugins.ucdeploy.DeliveryHelper$Push',
                pushVersion: '${BUILD_NUMBER}',
                baseDir: 'jobs\\test-ucd\\workspace\\build\\distributions',
                fileIncludePatterns: '*.zip',
                fileExcludePatterns: '',
                pushProperties: 'jenkins.server=Local\njenkins.reviewed=false',
                pushDescription: 'Pushed from Jenkins'
            ]
        ]
    ])
}

Deploy Component

node {
   step([$class: 'UCDeployPublisher',
        siteName: 'local',
        component: [
            $class: 'com.urbancode.jenkins.plugins.ucdeploy.VersionHelper$VersionBlock',
            componentName: 'Jenkins'
        ],
        deploy: [
            $class: 'com.urbancode.jenkins.plugins.ucdeploy.DeployHelper$DeployBlock',
            deployApp: 'Jenkins',
            deployEnv: 'Test',
            deployProc: 'Deploy Jenkins',
            createProcess: [
                $class: 'com.urbancode.jenkins.plugins.ucdeploy.ProcessHelper$CreateProcessBlock',
                processComponent: 'Deploy'
            ],
            deployVersions: 'Jenkins:${BUILD_NUMBER}',
            deployOnlyChanged: false
        ]
    ])
}

Trigger Version Import

node {
   step([$class: 'UCDeployPublisher',
        siteName: 'local',
        component: [
            $class: 'com.urbancode.jenkins.plugins.ucdeploy.VersionHelper$VersionBlock',
            componentName: 'Jenkins',
            createComponent: [
                $class: 'com.urbancode.jenkins.plugins.ucdeploy.ComponentHelper$CreateComponentBlock',
                componentTemplate: '',
                componentApplication: 'Local'
            ],
            delivery: [
                $class: 'com.urbancode.jenkins.plugins.ucdeploy.DeliveryHelper$Pull',
                pullProperties: 'FileSystemImportProperties/name=${BUILD_NUMBER}\nFileSystemImportProperties/description=Pushed from Jenkins',
                pullSourceType: 'File System',
                pullSourceProperties: 'FileSystemComponentProperties/basePath=C:\\Test',
                pullIncremental: false
            ]
        ]
    ])
}

Release Notes

Version 2.28

Added Update Component version in existing Snapshot feature.

Version 2.27

Fixed : 401 unauthorised error while pushing artifacts to IBM UrbanCode Deploy server. Added Global Fields for Skip Application Properties Import and Always Create New Client. Added fields for Extensions of files to Convert field and Charset to push artifacts to component version step.

Version 2.26

Fixed : Removed httpcore dependencies as it is no more used.

Version 2.25

Fixed : Removed checkbox to push failed build as it was causing Trigger version Import step to work improperly.

Version 2.24

Fixed : Updated plugin url.

Version 2.23

Fixed : Added checkbox to push failed build.

Version 2.22

RFE - Add Application Property in Environment Variable

Version 2.21

Fixed : UI Issue compatible for save and apply button.

Version 2.20

RFE 147414 : Added ucd application process log url for more details.

Version 2.19

Fixed : Addition of latest version to specified component only instead of all components.

Version 2.18

Fixed APAR PH28324 - UCD Jenkins Plugin - Fail the Jenkins job if nothing is found to push to UCD( avoid false positive).

Version 2.17

Block "Run as Alternative User" : Help text added for "Alternative Username" and "Alternative Password".

Version 2.16

Fixed APAR PH25862 - Making deploy version "not required" field to support following, which needs no version:

  1. Operational component process.
  2. Application generic process.

Version 2.15

Fixed APAR PH23739 - Fixed : Jenkins Plugin Shows success on Canceled job in UCD

Version 2.14

Fixing CVE:CVE-2019-4233

Version 2.13

Modified process to continue if user is unable to set environment variable.

Version 2.12

Set component version as environment variable when pushing a new version.

Version 2.11

Added option to skip waiting for a successful deployment from UCD.

Version 2.10

Added functionality to preemptively create environment snapshot to use during deployment.

Version 2.9

Fixed 401 http error when setting version properties by using latest uDeployRestClient.

Version 2.8

Fixed all Null pointer and bad casting exceptions returned in Jenkins system logs upon saving a job. Removed administrative checkbox from global and job configuration of user credentials.

Version 2.7

Fixed APAR PI91900 - Unfilled application process properties unable to be checked with a snapshot.

Version 2.6

Fixed APAR PI85407 - Importing component versions no longer fails when runtime properties aren't provided.

Version 2.5

RFE 104275 - Support for Description and Application Request Properties on deployments.

Version 2.4

Fixed APAR PI80038 - Snapshot names no longer require a leading equals sign.

Version 2.3

Fixed APAR PI77548 - Component process properties failing to resolve on deployment.

Version 2.2

RFE 98375 - Jenkins Plugin only allows Global credentials instead of job-based credentials.

Fixed PI75045 - UCD server maintenance mode check requires admin privileges.

Version 2.1

Fixed PI61971 - Connection pool leak in Jenkins ibm-ucdeploy-build-steps.

Older Versions

Fixed PI32899 - Jenkins plugin fails on slave nodes with an UnserializbleException

Fixed PI36005 - Jenkins plugin 1.2.1 not compatible with builds created with earlier versions of the plugin

Fixed PI37957 - Pulled in a fix for excludes options not being handled by a common library.

Releases

No releases published

Packages

No packages published

Languages

  • Java 92.5%
  • HTML 7.5%