Welcome to the Cloud Native CI/CD Pipeline project! This repository contains the implementation of a CI/CD pipeline using various cloud-native tools and technologies.
This project demonstrates the creation of a robust CI/CD pipeline leveraging Docker, Google Kubernetes Engine (GKE), REST APIs, Google Cloud Platform (GCP), and Terraform. The main goal is to automate the deployment and management of microservices, ensuring efficient inter-service communication and scalable, repeatable infrastructure deployment.
- Containerization with Docker: Containerized two microservices to ensure consistency across different environments.
- Deployment on GKE: Deployed the containerized microservices on Google Kubernetes Engine (GKE), ensuring efficient inter-service communication via REST APIs.
- CI/CD Pipeline: Built a robust CI/CD pipeline using GCP tools:
- Cloud Source Repository: Used for version control.
- Artifact Registry: Managed Docker images.
- Infrastructure as Code (IaC): Automated the creation and management of Kubernetes clusters using Terraform, enabling scalable and repeatable infrastructure deployment.
- Docker: For containerizing the microservices.
- Google Kubernetes Engine (GKE): For deploying and managing the microservices.
- REST APIs: For inter-service communication.
- Google Cloud Platform (GCP): For various cloud services.
- Cloud Source Repository: Version control system.
- Artifact Registry: Docker image management.
- Terraform: For automating the deployment and management of the Kubernetes clusters.
The architecture of this project involves the following components:
- Microservices: Two microservices containerized using Docker.
- Google Kubernetes Engine (GKE): Microservices are deployed on GKE.
- CI/CD Pipeline:
- Cloud Source Repository: Hosts the source code.
- Artifact Registry: Stores Docker images.
- Cloud Build: Triggers the build and deployment process.
- Terraform: Manages the infrastructure, including the creation and scaling of Kubernetes clusters.
Follow these steps to set up and deploy the project:
-
Clone the Repository:
git clone https://github.com/Dharmil4602/cloud-native-CI-CD.git cd cloud-native-CI-CD
-
Build Docker Images:
docker build -t <your-docker-image-name> ./container-1 docker build -t <your-docker-image-name> ./container-2
-
Push Docker Images to Artifact Registry:
docker tag <your-docker-image-name> <artifact-registry-repo>/<your-docker-image-name> docker push <artifact-registry-repo>/<your-docker-image-name>
-
Deploy with Terraform:
- Initialize Terraform:
terraform init
- Apply Terraform configuration:
terraform apply
- Initialize Terraform:
-
Trigger the CI/CD Pipeline:
- Set up Cloud Build triggers in GCP to automate the build and deployment process whenever changes are pushed to the Cloud Source Repository.