heroku-docker-springboot
Sample setup for publishing a Spring Boot app on Heroku within a Docker container.
Adapted from these official sources:
Local launch
Build
$ ./mvnw package
$ docker build -t heroku-docker-springboot .
Run
$ docker run -p 8080:8080 -e PORT=8080 heroku-docker-springboot
The PORT environment variable is set the same way Heroku would.
Test
$ curl localhost:8080
Heroku launch
Create
$ heroku container:login
$ heroku create
Push/release
$ heroku container:push web
$ heroku container:release web
Test
$ heroku open