How to auto reload spring boot application in docker using spring dev tools
docker, intellij-idea, spring-boot
Solution
You should add new Run/Debug configuration and select RemoteSpringApplication as a Main class. Also you should set Program arguments as ip address to your service (ex. http://localhost:8080). Also add spring.devtools.remote.secret: mysecret into your application properties. My configuration:
http://docs.spring.io/spring-boot/docs/current/reference/html/using-boot-devtools.html#_running_the_remote_client_application
Spring boot has bug with RemoteSpringApplication which do not allows to remove or add new class. This will be fixed in Spring Boot 1.4.3 https://github.com/spring-projects/spring-boot/issues/7379
Problem
I followed this link to deploy my application into local docker directly and debug it. I was able to deploy and debug but auto reload was not working for me Can you help me with auto reload for dockers using spring dev tools The reason I am interested in doing it this way because my application talks to 5 different services and running them individually might be little difficult. So will be hosting them individually on the docker. My trouble here is as of now I have to kill the container, then remove it and then add the new one back and I have to do this each time I change something I am using Spring Boot 1.4 | IntelliJ | Docker and spring dev tools