DevOps Project

1. Application

It's a Frontend/Backend application with basic CRUD features, developed using the MERN stack. You can access the application Here image

The application limits the users requests based on their IP address using the express-rate-limit package. Ilimited the requests to 100 requests per 15 minutes Screenshot from 2023-01-17 18-41-22

2. Observability

1. Logging

I used winston on nodejs to enable logging those are the logs generated by app image We can see tha we have a request id image

2. Metrics

I used prom-client to congigure metrics in my application. This is the first metric of tghe total requests image My business metric is the total_tasks in my kanban dashboard image I visualized these metrics in grafana dashboard image

3. Deployment

I built the frontend and the backend using docker and then I deployed them using kubernetes. This is the architecture of the deployment of the application

architecture

Concerning the deployment strategy I did not work on that but I chose a blue/green deployment because I want to maintain two identical production environments, one of which is the active environment (blue) and the other is inactive (green). During an update I wanted the new version deployed and tested on a production environment and redirecting the user traffic after it has been verified to be working correctly.

I chose blue/green over A/B testing because minimizing downtime during updates and the ability to easily rollback is a priority. and A/B testing is used if a decision about which version to use is a priority since it allows for directing a small percentage of traffic to different versions of the application

4. Automation

For the automation I used 3 stacks in terraform.

1. Kubernetes Cluster provisioning

Here I provisioned an AKS cluster whithin an existiing resource group

2. Application deployment

To automate the deployment of my application, I created a Helm Chart and I made the docker image name, the replicas and the http ports configurable via values.yaml. I also made it possible to add arbitrary labels to the deployment via the file values.yaml

3. Monitoring automation

here I created the monitoring setup for our application using Kubernetes provider as well as Helm provider. This stackk will install prometheus, grafana and datadog on our cluster in order to monitor our application

I also configured Terraform to use Azure Blob Storage as remote state backend. image