spring-petclinic
spring-petclinic copied to clipboard
Add deployment for spring boot in k8s
I want to contribute in the spring-pet clinic by adding k8s deployment file and SQL file in k8s.
We've talked about it before but never really had a consensus on what should go into the manifest. There are lots of choices and not many are obviously right. If you had a suggestion you could send a PR and we could go over it again.
I want to contribute in the spring-pet clinic by adding k8s deployment file and SQL file in k8s.
I just want to mention: https://github.com/spring-petclinic/spring-petclinic-cloud (official fork)
That would be a useful reference for anyone wanting to contribute. Also see here for some working example code: https://github.com/dsyer/spring-petclinic/tree/k8s.
I would say we need as few lines of YAML as we can get away with using just vanilla kubectl
and Spring Boot features.
- Use the image generated by
mvn spring-boot:build-image
and deploy either in a local repository or a public one (like dockerhub) - minimal service and deployment
- just one database (probably mysql) and a config map following the Service Binding spec because Spring Boot will pick that up automatically
- maybe
/livez
and/readyz
(can be exposed through a system property or application property)