2

We have multiple spring boot applications where one provide input to other.
As of now we are deploying it in 3 different VM and connect each other.

Is it advisable to make all these 3 into a single docker image?

Say, if I am able to make it into single docker image, it is easy for me to provide this images for different team.
As per the memory need, it is OK to be part of single image, I did that analysis.

VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250
JaVa
  • 53
  • 4

2 Answers2

4

If they are tightly coupled and can be managed under one process, yes.
You need to make sure you can stop the all system properly (to avoid zombie processes: see "Use of Supervisor in docker")

But the idea behind containers remains to isolate each components of your system in its own container, which facilitate debugging (when one part misbehave), upgrade, logging and monitoring.

You can experiment with multi-container apps by using docker bundles (dab) in order to facilitate the distribution of your multi-container application.

To help you with DAB, see:

Community
  • 1
  • 1
VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250
  • Thanks for your input. The links provided is very helpful – JaVa Jan 25 '17 at 17:27
  • @JaVa Thank you. You seem to have selected the wrong answer though: mine mentioned DAB 10 hours earlier. You can easily correct this. I have added links to get you started. – VonC Jan 25 '17 at 20:40
1

Distributed Application Bundle, or DAB, is a new concept introduced in Docker 1.12, is a portable format for multiple containers. Each bundle can be then deployed as a Stack at runtime. Let's use a Docker Compose file, create a DAB from it, and deploy it as a Docker Stack. https://blog.couchbase.com/2016/july/docker-services-stack-distributed-application-bundle

jAvA
  • 557
  • 1
  • 8
  • 22