This is a branch of the Spring PetClinic Sample Application built with Spring Data JDBC
Additionally:
- uses Gradle and Docker for build
- uses K8s for Execution
- Build the spring boot app - petclinic
- $ ./gradlew build
- Build the docker image
- $ ./gradlew dockerBuildImage
- The name of the docker image is 'petclinic:1.0' and 'petclinic:latest'. You can tag them and push to Docker Hub or your private docker registry.
- move to k8s directory
- $ cd k8s
- Create PV for MySQL DB
- $ kubectl create -f mysql-pv.yaml
- Create Deployment and Service(ClusterIP) of MySQL app
- $ kubectl create -f mysql-deployment.yaml
- Before running petclinic app, you should create a directory for logging on each worker node
- $ mkdir /logs && chown 1000:1000 /logs
- Create Deployment and Service and Ingress(for nginx ingress controller) of petclinic app
- $ kubectl create -f petclinic-deployment.yaml