Create a deployment package using Jenkins
- Creating a deployment package containing artifacts from a build
- Publishing the package to an XL Deploy server
- Performing a deployment of the package to a target environment
After you install the XL Deploy plugin in Jenkins:
- Go to Manage Jenkins > Configure System.
In the XL Deploy section, enter credentials for your XL Deploy server and test the connection.
Note: You can add multiple XL Deploy credentials.
In XL Deploy, a deployment package contains the components that form your application. For example, web content, web server configuration, database scripts, compiled binaries such as .NET applications and Java Enterprise Edition (JEE) Enterprise Archive (EAR) files, and so on. For more information see, What’s in an application deployment package
Using the XL Deploy Jenkins plugin you can provide the contents of your deployment package, and define your application. This is completed as a post-build action.
- Select the Deploy with XL Deploy post-build action: Note: The XL Deploy post-build action can create an XL Deploy Deployment Archive (DAR file).
- Provide basic information about the application. You can use Jenkins variables in the fields. For example, the version is typically linked to the Jenkins
$BUILD_TAGvariable, as in
1.0.$BUILD_TAG. Note: The Jenkins XL Deploy plugin cannot set values for hidden CI properties.
- Add deployables to the package, select Package Application.
- To add artifacts, the Location field indicates where the artifact resides. For example, this can be the Jenkins workspace, a remote URI, or coordinates in a Maven repository.
Add additional properties as required for each artifact or resource.
Note: For properties of type
MAP_STRING_STRING, enter a single property value in the format
key1=value1. You can enter multiple values using the format
If you modify existing configuration item (CI) types or add new ones in XL Deploy, for example, by installing a new plugin, ensure that you click Reload types for credential in the post-build action. This reloads the CI types for the XL Deploy server that you have selected for the action. This prevents errors by ensuring that the most up-to-date CI types are available to the Jenkins job.
To publish the package to XL Deploy, select Publish package to XL Deploy. You can select the generated package or a package from another location, from the file system or from an artifact repository.
Note: The application must exist in XL Deploy before you can publish a package.
To deploy the application with XL Deploy, select the target environment and deployment options.