AWS CodePipeline
Tags: aws, awsdevops, devops, cloud
Published: 2024-02-07 05:20:39

-1-. Now, all stages have been properly configured, and it is running smoothly. However, we are currently executing it manually. Therefore, as the final step in this series, we will configure AWS CodePipeline and explore its functionalities.

-2-. Navigate to 'CodePipeline' and then click on 'Create Pipeline'.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/g0ggejojb90chgbl1lcu.png)

-3-. Next, provide a name for your pipeline, select the pipeline type, choose 'New Role', and then click on 'Next'.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/zz9eoffepysg6hvjxyd6.png)

-4-. Next, in the following window, select 'CodeCommit' as the source provider since our code is stored there. Choose the 'Repository Name' where your code resides, and then select the branch from which you want to build and deploy your application. For the detection option, choose 'AWS CodePipeline', as it is essential for tracking changes in the repository. This ensures that any new changes trigger our pipeline. Finally, click on 'Next'.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/eb3mhxhhvh3aetsrlys8.png)

-5-. In the next stage, the 'Build Stage,' select the 'Build Provider,' indicating where you want to build your code. Choose your region, specify your project name, and then click on 'Next'.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/i25vrlu316ifnbsjidq6.png)

-6-. In the deploy stage, select the 'Deploy Provider' and specify the application name and deployment group where we have configured the deployment. Finally, click on 'Next'.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/04sz6c6qang5mir8r93m.png)

-7-. Review your pipeline settings and configurations, ensuring they are accurate. Then, click on 'Create Pipeline' to initiate the process, which will fetch your code from CodeCommit, build it, and deploy it on EC2.

-8-. Here, you can observe that our pipeline has run successfully, with all stages completing without errors. This indicates that our application has been deployed. You can verify this by checking the latest commit that we made, which triggered the pipeline automatically. To confirm the deployment, you can make changes to the 'index.html' file and see if the changes reflect correctly.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/3ktb4aq5ex4uz8d11ith.png)

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/6qp1rmol5zh7pzwq3sgw.png)

-9-. Exactly! AWS CI/CD, including services like AWS CodePipeline, is indeed a critical component of DevOps practices. Building pipelines in AWS allows for automated and efficient deployment of applications, ensuring faster delivery and higher reliability. I'm glad you found the process of configuring the code pipeline informative. It's an essential skill for modern software development and deployment. If you have any more questions or need further clarification on any aspect, feel free to ask!

This is the last part of our 'AWS DevOps' series. We covered topics such as 'Introduction to AWS DevOps,' 'AWS CodeCommit,' 'AWS CodeBuild,' 'AWS CodeDeploy,' and 'AWS CodePipeline.' We delved into each step in detail, exploring their importance. Make sure to try this out, and after you're finished, remember to terminate or delete the pipeline to avoid unnecessary billing. Please share, like, and let me know in the comment box your thoughts for the next series or any questions you may have. Happy learning!