This repo contains the slides and the sample code of the talk Managing an Akka Cluster on Kubernetes.
- Install minikube:
brew cask install minikube
- Start minikube:
minikube start
- Enable Kubernetes Ingress addon:
minikube addons enable ingress
- After a minute, verify that Ingress addon has been started:
kubectl get pods -n kube-system | grep nginx-ingress-controller
- In order that Kubernetes finds the locally published Docker image of our application run:
eval $(minikube docker-env)
- Publish the
trip
backend service to the local Docker registry:cd code sbt docker:publishLocal
- Deploy the backend service, and create Kubernetes service and ingress resource:
kubectl apply -f .deployment/outgoing.yml kubectl apply -f .deployment/deployment.yml
- Verify that backend service is running:
kubectl get pod NAME READY STATUS RESTARTS AGE trip-646cddc7b7-46k82 1/1 Running 0 32m trip-646cddc7b7-6zf5k 1/1 Running 0 32m trip-646cddc7b7-zjtvd 1/1 Running 0 32m
- Access backend service via minikube IP address:
http POST $(minikube ip)/trip/offer origin=A destination=B HTTP/1.1 200 OK Connection: keep-alive Content-Length: 45 Content-Type: application/json Date: Thu, 04 Oct 2018 05:32:02 GMT Server: nginx/1.13.12 { "price": { "amount": "10.00", "currency": "EUR" } }