1
Sep

Build and Deploy OSB Projects using Jenkins

I have been working on Jenkins for a while now. Primarily, my focus is on automated deployment of Oracle Fusion applications using Jenkins. I started with ADF deployments which includes following steps:

  1. Check-out the code from Subversion (SVN)
  2. Build the EAR file
  3. Run SonarQube rules for Code Analysis
  4. Get approval from development lead using Build Promotion Plugin
  5. Application deployment
  6. Send status email to initiator

To extend this workflow, I have setup OSB deployments in a similar fashion. There are only two differences in this process:

  1. Create JAR file instead of EAR
  2. Apply customization file after every deployment

Below is the list of tools/technologies and Jenkins plugins used in this process.

  1. Jenkins
    1. Parametrized build plugin
    2. Build promotion plugin
    3. Build Pipeline plugin
  2. SVN – for version control
  3. configJar – OSB bundled tool to create JAR files
  4. WLST – Scripts to import and deploy JAR files followed by applying customization file

Here is the step-by-step guide of how to setup Jenkins for OSB projects:

Step 1: Since I have many OSB interfaces, I have setup one job per environment instead of creating one job per interfaces. That helps me in effective management of Jenkins’ jobs. Something like this:

  1. OSBBuild_Development – For Dev environment
  2. OSBBuild_Integration – For Integration / Test environment, and so on.

Step 2: Each job will prompt for two parameters – OSB project name and environment where it needs to be deployed.

    

Step 3: These parameters will be passed on to next job which is to get approval from leads. Leads will receive an email with promotion link

Step 4: Once promoted/approved, an email will be received by deployment team. That email will also contain a link which can be used for deployment.

Step 5: Deployment job is divided into following parts:

  1. Checkout code from SVN
  2. Build and Create JAR with same name as provided in the Step 2.
  3. Invoke WLST script and deploy the JAR on environment selected in Step 2.

 

This concludes the high-level details of automation process of OSB deployment using Jenkins along with integrated approval process. If you have any query, please contact me.

22
Sep

How to Configure Jenkins Job with Runtime Parameters

There are two ways to pass parameters between two jobs. First method is to configure the parameters within first job. These variables are configured with hard-coded values.

The second method is configuring the job to accept parameters at runtime. It allows you to pass different value each time you run the job without making any change in the job configuration.

This article is a step by step approach on using the second method in Jenkins. Continue reading

30
Jan

Configure Role Strategy Plugin in Jenkins

image
Allow me start the discussion by stating a real world problem, OR I must say a real world need. Most of the times, we have multiple teams working on different projects. As a matter of security, we don’t want any team peeps in someone else’s projects.
If you’re using Jenkins for your build promotions, you would certainly need to isolate various teams working on different projects. It is obvious that you cannot setup multiple Jenkins instances dedicated to each team. All of the projects will be configured in Jenkins as multiple Jobs.
The best way to grant access on specific projects to specific people is to use Role Strategy Plugin. It is just a piece of cake to configure this Plugin and it allows you to manage your Jenkins instance effectively.

So, here is a step-by-step guide to configure Role Strategy Plugin. Continue reading