Jenkins is the way to save your valuable time

Automating Large Workflows With Single-click Deployment

Submitted By Jenkins User Abhineet Saxena
India's first mobile healthcare communication and delivery platform wanted a software deployment process that was faster with a single-click setup.
Industries: Healthcare, Information Technology
Programming Languages: Java, Node.js
Platform: : Docker or Kubernetes, Linux, Windows, Git
Version Control System: GitHub, GitLab
Build Tools: Maven
Community Support: websites & blogs, Spoke with colleagues and peers

Saving time by automating a cumbersome deployment process across five cloud servers.

Background: In our organization, we have multiple web apps and five servers in the cloud for each individual app. So whenever a developer added a new feature, the DevOps Team needed to do a release on all servers. Our five servers run behind an AWS Application Load Balancer. We first Deploy the application on one server and after final testing, deployment happens on all of the remaining servers. The main challenge is that when the developer confirms to start a release, we first need to deregister the server from the Application Load Balancer, then do the respective deployment, and then register the server to the load balancer again.

Performing this task for all servers consumes a lot of time and we knew automation was the solution. We created Jenkins Job to build and release the application to the individual server but we need some end-to-end automation program to make this happen.

Goals: Automating long software development processes and transitioning to a single-click action for production.

Goals: Automating long software development processes and transitioning to a single-click action for production.

Jenkins just saved 3 to 4 hours of being stuck in the deployment process. It also saved lots of energy, which we can use to make our infrastructure more reliable for customers.
profile picture
Abhineet Saxena, DevOps Engineer

Solution & Results: To meet this needed a combination of Jenkins, Groovy Scripts, and Bash Scripts to automate our complete process as a Pipeline. We installed AWS Command Line Interface in our Jenkins server. Then we created one master script in which we have functions to register and deregister the servers from the AWS Cloud Application Load Balancer.

We then created two Jenkins jobs to register and deregister the server from the application load balancer. In these jobs, we have called 'function' from the master script and created a parameterized job where the server name was selected automatically. We already have the job to deploy the application on individual servers.

The final task is to create a pipeline job which will first trigger the deregister job and then trigger the deployment job followed by the register job. We do the same for all servers. So we now have four Jenkins Jobs where the pipeline job will trigger all jobs as needed to automate the deployment on all five servers.

What did we learn?

  • Jenkins is extremely fast for your desired task. Wherever I have integrated Jenkins it performs all the triggering and options operating very quickly.
  • Jenkins is highly flexible and we can implement any plugins for any technology. There are an enormous number of plugins available in Jenkins which can be used to integrate Jenkins with nearly any technology out there.
  • Jenkins is a highly available tool as you can implement a distributed Jenkins environment in your Infrastructure and build jobs as per your need.

Results include:

  • A deployment process that is 5X faster
  • No human error as things are automated with scripts
  • Single-click setup