Amazon Web Services is a great choice when it comes to building a CI/CD pipeline. AWS CodePipeline reliably automates the deployment process and many businesses choose the service over Jenkins or Teamcity. Recently, Loves Cloud got the chance of helping a client in building a CI/CD pipeline using AWS CodePipeline.
The client is one of the world’s leading certification training providers. They augment digital skills of the people by providing them with courses on subjects relevant to today’s changing world. From Cyber Security and Cloud Computing to Digital Marketing and Data Science – they have a course for anybody who needs to stay relevant in this ever-changing digital world. They are based in San Francisco, California and have a branch office in Bangalore, India.
A Brief Background
Our client company started as a blog providing ideas back in 2009 and now it is a leading training provider with series C capital already raised. It had scaled greatly and it became necessary to upgrade their internal systems with the intention of ingraining DevOps. Hence, one of the first steps was to implement a CI/CD pipeline.
We sat with our client’s Program Manager and discussed about their issues that forced them to take the path of digital transformation. The company scaled so rapidly that now it was impossible to cater to the requests of students and manage the training process using legacy processes. With other competitors cropping up, it became necessary for the client to build and deploy codes faster with less leg room for bugs. Stable build, automated testing and monitoring and automated deployment were the things that the client wanted. After a detailed discussion, we identified two things that needed to be done:
- Building a CI/CD pipeline using AWS CodePipeline. Since much of the work of our clients is done online, it appeared prudent to take the help of AWS as opposed to Jenkins since the latter would have needed a physical server as well. With AWS, everything happens on cloud.
- With CI/CD pipeline in place, the next step should be ensuring an efficient, continuous, automated deployment process.
The Way We Achieved the Goals –
We employed DevOps best practices and built an end-to-end CI/CD pipeline for our customers. Let’s dive deeper and see what exactly we did:
- As already decided, we took the help of AWS CodePipeline to create our customer’s continuous integration and continuous deployment pipeline.
- In order to have a seamless integration with other AWS services we migrated the client’s software codes from GitHub to Amazon Code Commit. One additional benefit that the company got by opting for Code Commit is having free private repository upto 50 GB.
- Again, in order to have a synchronicity in the pipeline, we used Amazon’s CodeBuild to build and test the codes. As an added advantage the client got the option of pay per minute in CodeBuild. This proved to be a great cost-cutting strategy.
- We used Amazon EC2 to launch virtual servers and created a Tomcat deployment server on it.
- We used Amazon’s Identity and Access Management (IAM) to control which users should be allowed or denied access to various AWS resources of the client.
- The great thing about AWS is – it provides every DevOPs solution – making the deployment a wholesome process without relying on third party resources. Another component of AWS CodePipeline is CloudWatch. We used it to monitor various AWS resources.
- To further bring uniformity to the whole process, we used CodeDeploy to automate deployments.
In this way we complimented AWS CodePipeline by using other Amazon services and created a stable end to end Continuous Integration and Continuous Deployment pipeline.
The Tools We Used
To achieve our goals, we used the following tools –
- AWS Public Cloud Platform
- EC2 for deploying Tomcat
- IAM for regulating access to AWS resources
- S3 for storing software artifacts
- CloudWatch for monitoring code builds and test results as well as AWS resources. We also used Cloud Watch for alerting and logging
- Amazon’s Code Commit as a central code repository
- CodeDEploy for deploying the application
- AWS CodePipeline for creating a Continuous Integration and Continuous Deployment pipeline
- We used YAML for our scripting needs
The Awesome Results:
We were successful in creating a fully functional, stable, secure CI/CD pipeline for our customers. In addition to that, we were able to provide the following benefits:
- Deployment time was significantly reduced. The time gap between putting the code in Code Commit and deploying it was only around two minutes.
- By using other AWS services like Code Commit, CodeBuild, EC2, etc we were able to automate the entire deployment process.
- With continuous integration and the subsequent automate build-test sequence, the developers were able to reduce bugs and increase quality of codes before actual deployment.
- With automated build-test sequence, the hiccups during deployment are greatly reduced. Failed test were not allowed to pass to the deployment phase.
- With CloudWatch, the developers were able to see the detailed logs of build and test failures and fix them early.
- With CloudWatch we set up a real time monitoring system which would timely alert the developers of any build failures. Monitoring of AWS resources were included too.
At Loves Cloud, we are constantly leveraging the power of various open source software solutions to automate, optimize, and scale the workloads of our customers. To learn more about our services aimed at the digital transformation of your business, please visit https://www.loves.cloud/ or write to us at firstname.lastname@example.org.