We are using some sample code from Spring Guides:
https://github.com/spring-guides/gs-actuator-service
-
Install Vagrant and VirtualBox:
-
Prepare VM:
$ git clone https://github.com/wybczu/vagrant-java-boilerplate
$ cd vagrant-java-boilerplate
$ vagrant up
$ vagrant ssh
$ cd /vagrant
- Build application with gradle...
$ ./gradlew build && java -jar build/libs/gs-actuator-service-0.1.0.jar
- ...or maven...
$ maven package && java -jar target/gs-actuator-service-0.1.0.jar
- ...and test it!
$ curl http://localhost:9000/hello-world