Kotlin microservice template produces self-executable jar application. For brevity, double-space
formatting is used. Ktor is included to mock Digital Ocean healthy checks.
- Make sure you are signed in to your GitHub account, then just
click
hereto use template. App.ktfile is entry point.
Execute ./gradlew clean build. Your jar will be located at ./build/libs with -all.jar postfix.
Now you can run:
java -jar service-all.jarExecute docker build . -t service. Your image will be located at docker images -a. Now you can
run:
docker run -v `pwd`:`pwd` -w `pwd` -it --rm -p 80:80 serviceYou can edit deploy configuration at file deploy.template.yaml.