This document describes different approaches avaialble for deploying BookStore application.
There are mainly 2 types of deployment approach currently supported:
Docker Compose is right approach if you want to run the application locally to see all the components in action. We recommended this approach for learning / evaluation only. We have provided Docker-Compose scripts for this task which can be found under deployment/docker-compose.
Following script will help to run all services and required tools like postgres database, redis, grafana, keycloak etc in local.
cd microservices-reference-application
# Build image for all services
./tools/build-docker-image.sh
# Run all services locally with required tools
./tools/docker-compose.sh up
# Stop all services running locally
./tools/docker-compose.sh down
You can find the kubernetes
yaml file under deployment/kubernetes folder to deploy each and every components required for this application.
Before starting deployment make sure your kubectl is pointing to the right kubernetes cluster. All the resources will be created on a separate namespace called bookstore
. If you use provided terraform
scripts, it will automatically create this namespace after provision kubernetes cluster. Make sure you create this namespace manually, if you are not using terraform script.
# Check what namespaces are available
kubectl get namespace
# Create namespace manually
kubectl create namespace bookstore
Following step will deploy all required kubernetes resources for postgres such as volumes, volume claims, storageclass, service, configmap and StatefulSet.
cd microservices-reference-application/deployment/kubernetes/postgres
# Create kubernetes resources for postgres
kubectl apply -f *.yaml
Following step will deploy postgres database and keycloak auth server with initial Realm Bookstore
configuration.
cd microservices-reference-application/deployment/kubernetes/keycloak
Replace KEYCLOAK_URL in keycloak-ingress.yaml with your kubernetes URL.
# Create kubernetes resources for keycloak
kubectl apply -f *.yaml
Access your keycloak instance with your configured domain name:
e.g. https://keycloak.192.168.49.2.nip.io/
TODO
TODO
TODO
TODO
TODO
TODO
TODO
TODO