Before you begin
- Install and start IBM UrbanCode Deploy Server. See the installation section of the product documentation that is appropriate for the version you are using.
- Install and start the IBM UrbanCode Deploy agent.
- Install and start the Jenkins master server.
- Start Jenkins slave nodes and connect the slave nodes to the Jenkins master server.
- Install the Jenkins plug-in for IBM UrbanCode Deploy on the Jenkins server. Download the latest version of the plug-in from UrbanCode plug-in website.
- Set up the source control management configuration of the project, such as Git or Maven.
The following scenario shows how to use the Jenkins plug-in to publish a Jenkins build output to versioned artifacts in IBM UrbanCode Deploy and deploy the application.
- Create a resource group and add the IBM UrbanCode Deploy agent to the resource group, as shown in the following screen capture.
- Create components in IBM UrbanCode Deploy. Do not specify a Source Config Type setting. The contents of the component are uploaded from the Jenkins build job.
- Create a component deployment process similar to the process shown in the following screen capture.
- Create the Test_Jenkins application and add the components to the application.
- Create the Test_Jenkins application environment and add a resource group to the environment.
- Create an application deployment process and add the component processes to the application process.
- Configure the default IBM UrbanCode Deploy server profiles on the Jenkins configuration page as shown in the following screen capture.
- Create and configure a Jenkins job. In the Jenkins job, edit the following sections:
- The Source Code Management section. For example, specify a Git repository URL.
- The Build Management section. For example, specify a shell command to run.
- The Post-Build Actions section. Configure the Publish artifacts into IBM UrbanCode Deploy area as shown in the following screen capture. You can also add a downstream job to run after the Jenkins job, specify an IBM UrbanCode Deploy user other than the default user that you set previously, and specify input properties for publishing or deploying component artifacts.
- Create a downstream job that creates an execution chain for multiple components, as shown in the following screen capture.
- Run the upstream job, which triggers the publication process and the application deployment process. Check the corresponding status or log information on Jenkins server as shown in the following screen capture.
The built artifacts are published into a corresponding component version and a Jenkins job link is created. Click the Jenkins job link to trace back to the build on the Jenkins server.
The application deployment process runs.