I have developed small spring-boot microservice application and dockerized the same. I have multiple spring-boot services and angular which are dockerized using docker-compose file. My app runs fine in my local. I just wanted to host my app on Heroku for free. please help me how to host my app and how to configure multiple ports with application. how to deploy using docker-compose.
2 Answers
First of all, you can not run your docker-compose in heroku.
Docker is not required
If you will choose heroku, docker is not required. Just ensure that your spring boot apis and angular app are standard. If you fulfill that, just create many applications as git repositories you have (I guess you have it like this).
Smart heroku engine will detect the technology of your git repository and will provide you an standard dyno for your app. After that heroku will run standard commands of open source languages.
For example, heroku will run npm install and npm run start in your angular/nodejs app. If you don't put the start script in your package.json, an error will be trowed. The same will happen with your spring boot rest api.
If you have any error with your current spring boot apis, try to compare it with my templates https://github.com/jrichardsz/spring-boot-templates/tree/master/000-hello-world.
I want docker
Anyway, if you want to use docker in heroku, just put the classic Dockerfile inside of any git repository and push them to heroku. Smart engine will detect it and deploy it.

- 14,356
- 6
- 59
- 94
1.You don't need docker as answered already. See this link for deployment to Heroku
- You could also deploy using Travis CI for continuous integration via github.

- 3,276
- 3
- 24
- 36