This is my project submission for the SCA Cloud School Bootcamp Cohort 4 program.
- Project Documentation
To see complete steps on how this project was built, read the article here: Deploying your Applications to AKS.
This project is focused on the containerization and deployment of a container to Azure Cloud Platform.
The express.js application code
is written and stored in a GitHub Repository
. Whenever a push is made to this repository, a CI/CD pipeline, built with GitHub Actions
, is triggered. This pipeline handles the setup of the project and installs the necessary dependencies. It also builds a Docker image
using the Dockerfile located in the root directory. Once the Docker image is built, it is pushed to an Azure Container Registry
(ACR) for hosting.
To run the application, an Azure Kubernetes Service
(AKS) pulls the Docker image and deploys it within a Kubernetes
Cluster. Within this cluster, a Deployment
is created, accompanied by a Persistent Volume Claim
(PVC) and a Storage Class
. These components ensure data persistence for the containers running in the cluster. The Storage Class is connected to an Azure File Share storage within a Storage Account
on Azure. Additionally, a Service
is established to allow public access to the application using a load balancer.
Terraform
was utilized to provision the infrastructure required for this setup, including the Azure Container Registry (ACR), Azure Kubernetes Service (AKS), Storage Account, and other associated services such as the resource group and AKS role.
Monitoring of the container's performance within AKS is facilitated by Container Insights
, a feature of Azure Monitor. Azure Monitor
collects telemetry data from Container Insights and stores it in a Log Analytics Workspace
as logs.
Tools & Services | Usage |
---|---|
Docker | Containerizes the Docker Image |
Terraform | Automates the provisioning of Infrastructure on Azure |
Azure Container Registry (ACR) | Hosts the container image in a repository |
Azure Kubernetes Service (AKS) | Enables container execution in the Kubernetes cluster it provides |
Azure Storage Account | Provisions an Azure File storage to persist volume from the container |
GitHub Actions | Provides workflows that automate the process of building, testing, and deploying code |
Azure Monitor | Collects and analyzes telemetry data from Container Insights and Log Analytics |
Container Insights | Monitors performance and health of containerized applications within AKS |
Log Analytics Workspace | Provides a centralized storage and management location for log data collected by Azure Monitor and AKS cluster |
-
The application is accessible on this IP Address: http://40.88.195.57
-
Inputed feedbacks are accessible at http://40.88.195.57/feedback/title-of-feedback.txt.
By leveraging Azure Monitor, you gain visibility into the current status of your cluster, ensuring effective monitoring and confirming its healthy state.
This valuable information is collected through the utilization of Container Insights.
npm install express
node server.js
cd terraform-infrastructure
terraform init
terraform fmt
terraform validate
terraform plan
terraform apply