This project is a simple Todo application written in Python, accompanied by a Continuous Integration/Continuous Deployment (CI/CD) pipeline using Docker, Jenkins, ArgoCD, and Kubernetes.
- Add, delete, update, and view todo tasks.
- Dockerized deployment for easy portability and scalability.
- CI/CD pipeline for automated testing and deployment.
- Integration with Jenkins for CI automation.
- Deployment automation through ArgoCD and Kubernetes.
- Docker
- Jenkins
- ArgoCD
- Kubernetes (minikube or any Kubernetes cluster)
- Clone this repository:
git clone https://github.com/ARUP-G/Python-todoApp-Jenkins-Argocd-K8s.git
- Navigate to the project directory:
cd Python-todoApp-Jenkins-Argocd-K8s
- Build the Docker image:
dokcer build -t todo-app:1 .
- Run the Docker container:
docker run -d -p 5000:5000 todo-app:1
- Access the Todo app through your web browser at http://localhost:5000.
The CI/CD pipeline for this project is orchestrated using Jenkins, ArgoCD, and Kubernetes.
-
Continuous Integration (CI) with Jenkins: Upon pushing changes to the repository, Jenkins automatically triggers a build job. This job involves running unit tests and linting to ensure code quality.
- Jenkins: Build jenkins pipeline and build and run the pipeline.
- Continuous Deployment (CD) with ArgoCD and Kubernetes: Once the code passes CI, Jenkins triggers a deployment job. This job builds a Docker image and pushes it to a Docker registry. ArgoCD, configured to monitor the repository, detects changes and automatically deploys the updated Docker image to the Kubernetes cluster.
- Push to Docker Hub: By executing the pipeline the image will be added to dockerhub registry.
Note: Make sure to change "Push the artifacts"
stage in jenkinsfile with proper credentials and registry username.
-
ArgoCD: Go into deployment manifest module and execute the command.
kubectl apply -f service.yaml
*For more information about the deployment manifest visit https://github.com/ARUP-G/Todo-app-deployment-manifest.git
To access the app
-
Minikube way
minikube service todo-service
then you will get the
url
to access the app.
Contributions are welcome! If you find any issues or have suggestions, please open an issue or submit a pull request.
This project is licensed under the MIT License.