Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 

Spring Boot Admin - Kubernetes Example

Allows to run Spring Boot Admin and two sample apps (hello world, health simulator) in kubernetes.

There are 3 instances of Spring Boot Admin available. All three use the discovery mechanism to find the apps to monitor. There is no self registration used. One SBA is using the spring cloud kubernetes-client, the second one the spring cloud kubernetes-fabric8 and the third one is using the spring cloud kubernetes discovery server to get all running services instead of using kubernetes discovery directly.

This Readme will guide you through all setup steps for the infrastructure.

Enable Kubernetes in Docker Desktop

  1. From the Docker Dashboard, select the Settings.
  2. Select Kubernetes from the left sidebar.
  3. Next to Enable Kubernetes, select the checkbox.
  4. Select Apply & Restart to save the settings and then click Install to confirm. This instantiates images required to run the Kubernetes server as containers, and installs the /usr/local/bin/kubectl command on your machine.

Documentation

Change Kubernetes Context

kubectl config get-contexts
kubectl config use-context docker-desktop

Install Helm

brew install helm
helm version

Documentation

Install Everything

You can run the whole build and installation for all apps with the following script or follow the step-by-step guide below.

chmod u+x buildAndInstallAll.sh
./buildAndInstallAll.sh

http://localhost/spring-boot-admin-kubernetes

http://localhost/spring-boot-admin-fabric8

http://localhost/spring-boot-admin-discoveryclient

Step-by-step Installation

Install Traefik

Build & Install Apps

Uninstall Everything

chmod u+x uninstall.sh
./uninstall.sh

Installing Other Spring Boot Apps

You can install any Spring Boot App using the helm chart (your app must be available as docker image).

helm upgrade --install <your-app-name> helm-charts/spring-boot-app -f <path-to-your>/values.yaml

OR

helm upgrade --install <your-app-name> helm-charts/spring-boot-app --set name=<your-spring-app> --set deployment.image=<yourImage>
helm uninstall <your-app-name>