Day 53: Your CI/CD pipeline on AWS - Part 4 🚀 ☁

Day 53: Your CI/CD pipeline on AWS - Part 4 🚀 ☁

Welcome to the fourth and final part of our journey in creating a robust CI/CD pipeline on AWS! In this segment, we'll explore AWS CodePipeline, a fully managed continuous integration and continuous delivery (CI/CD) service that orchestrates the steps of your release process.

What is CodePipeline?

CodePipeline builds, tests, and deploys your code every time there is a code change, based on the release process models you define. Think of it as a CI/CD Pipeline service.

Task-01 :

Create a Deployment group of EC2 Instance.

Create a CodeDeploy application:

In CodeDeploy, go to Applications and click on 'Create application'.

Select compute platform ‘EC2/on premises’ and click on ‘Create application’.

Application is successfully created.

Create 'service role' for enabling communication between code deploy and other aws services. Create 'code-deploy-service-role' with below permissions.

Create an ubuntu EC2 instance:

Create a deployment group:

Add deployment group name and choose 'Service role'.

Add instance name.

Deployment group is created.

Install the CodeDeploy agent in ec2 insatnce:

You can install the CodeDeploy agent by running the following script on your EC2 instance:

Code agent is running.

2. Create a CodePipeline that gets the code from CodeCommit, Builds the code using CodeBuild and deploys it to a Deployment Group.

Go to the CodePipeline console. Click "Create pipeline."

Enter a name for your pipeline.

Under "Source provider," choose "AWS CodeCommit."

Select the repository and branch you want to deploy.

Click "Next."

Under "Build provider," choose "AWS CodeBuild."

Select "build project name."

Click "Next.

Under "Deploy provider," choose "AWS CodeDeploy."

Select the deployment group you created earlier.

Click "Next."

Review the pipeline settings and click "Create pipeline."

The pipeline will automatically trigger a build and deploy the new code to the EC2 instance.

Successfully created a CodePipeline that automates the deployment process.

Browse your instance public-ip address, you can see final output of index.html

Congratulations! You've successfully created a CI/CD pipeline on AWS using CodePipeline, CodeCommit, CodeBuild, and CodeDeploy. This pipeline automates the build and deployment of your application, ensuring efficient and reliable software delivery.

Keep innovating, iterating, and optimizing your CI/CD processes to achieve continuous improvement in your software development lifecycle. Happy coding! 🚀 ☁️

I'm confident that this article will prove to be valuable, helping you discover new insights and learn something enriching .

thank you : )