This project is a chat application consisting of a frontend client and a backend server. It provides real-time messaging features and can be deployed locally using Docker, Docker Compose, or Kubernetes.
Before you start, ensure you have the following installed:
-
Node.js: Version
v20.11.0
- Install Node.js from nodejs.org.
- Check version:
node -v
-
Docker: Version
27.1.1
- Install Docker from docker.com.
- Check version:
docker --version
-
Kubernetes: Version
v1.30.2
- Install Kubernetes using kubectl.
- Check version:
kubectl version
-
kubectl: Version
v1.30.2
- Install
kubectl
as described in the Kubernetes documentation. - Check version:
kubectl version --client
- Install
-
Docker Compose: Not installed
- To install Docker Compose, follow the instructions at docker.com.
-
Clone the Repository:
git clone https://github.com/Milanshub/Chat-Docker-TS-project-5.git cd Chat-Docker-TS-project-5
-
Build the Backend Server: cd server npm install npm run build
-
Build the Frontend Client: cd ../client npm install npm run build
-
Start the Backend Server: cd ../server npm start
-
Start the Frontend Client: cd ../client npm start
-
Ensure Docker and Docker Compose are Installed.
-
Build and Start the Application: docker-compose up --build
-
Ensure Kubernetes and kubectl are Installed.
-
Apply Kubernetes Configuration: kubectl apply -f k8s/
-
Forward Ports to Access Services Locally: kubectl port-forward svc/client-service 3000:80 -n chat-demo-app kubectl port-forward svc/server-service 5000:5000 -n chat-demo-app