This project is a Microservices application consists of there components,
- ExpressJS module
- SpringBoot module
- Flask module
Each service is containerized using Docker and is deployed on Google Kubernetes Engine (GKE).
The goal of this application is to get familiar with the basic concepts of microservices architecture.
These application is currently up and running on GKE cluster.
This micro-service is written using Java and SpringBoot Frmaework.
The service is hosted on following endpoint: http://34.94.35.116/hello
This returns a Json response with message as "Hello".
{
message : "Hello"
}
This micro-service is written using Javascript and ExpressJS Frmaework.
The service is hosted on following endpoint: http://34.94.193.46/world
This returns a Json response with message as "World".
{
message : "World"
}
This webapplication is written using Python and Flask Frmaework.
This app makes call to other two service endpoint and display message : "Hello World".
The web-app is hosted on : http://34.94.205.204
The App and it's images are hosted on Google Kubernetes Engine and Artifact Registry.
Below is running status of cluster.
Here are the resources and links for accesing the Docker Images.\
- Docker
- Node.js
- Python3
- Java 17
- VScode IDE
cd express
npm install
node server.js
To build and run docker image :
docker build -t express-app .
docker run -p 3000:3000 express-app
cd springBoot/hello
mvn clean install
java -jar target/hello-0.0.1-SNAPSHOT.jar
To build and run docker image :
docker build -t springboot-app .
docker run -p 8080:8080 springboot-app
cd flask_helloWorld
python3 -m venv venv
source venv/bin/activate
pip install -r requirements.txt
python app.py
To build and run docker image :
docker build -t flask-app .
docker run -p 5000:5000 flask-app
End with an example of getting some data out of the system or using it for a little demo
- Express: Access at http://localhost:3000 \
- Flask: Access at http://localhost:5000 \
- Spring Boot: Access at http://localhost:8080 \
- Spring Boot: Access at http://34.94.35.116/hello \
- Express: Access at http://34.94.193.46/world \
- Flask: Access at http://34.94.205.204
Images are deployed on GKE.
To scale up the applications, login to gcloud through cli and run following command:
kubectl scale deployment flask-app --replicas=2
kubectl scale deployment express-app --replicas=2
kubectl scale deployment springboot-app --replicas=2
To scale down,
kubectl scale deployment flask-app --replicas=0
kubectl scale deployment express-app --replicas=0
kubectl scale deployment springboot-app --replicas=0
- Shantanu Joshi - LinkedIn -



