Clone the repository to your local machine:
git clone <https://github.com/pranavtotla/assignment-boilerplate>
cd assignment-boilerplate
Use eksctl to create a Kubernetes cluster with at least 3 nodes:
eksctl create cluster --name=my-cluster --nodes=3 --region=<your-aws-region>
Replace with the desired AWS region (e.g., us-west-2).
After the cluster is created, configure kubectl to use it:
aws eks --region <your-aws-region> update-kubeconfig --name my-cluster
In the cloned repository directory, create a Dockerfile to build the Node.js application:
FROM node:14
# Create and change to the app directory.
WORKDIR /usr/src/app
# Install app dependencies.
COPY package*.json ./
RUN npm install
# Copy app source code.
COPY . .
# Start the app.
CMD [ "node", "index.js" ]