2

I've setup several docker containers for my application:

  1. container for mysql
  2. container for application server (tomcat7)
  3. container for nginx
  4. container for python tornado application

On my local machine, using docker-machine, I've tried all these containers and them interactive with each other. I created one virtualbox machine with boot2linux and setup all these containers on it.

Now, for production I am going to run each one of these containers on a separate server. Is there something docker provides to quickly/easily do this? Or should I set up docker on each server, copy relevant images to that server, and then start docker-images manually on all servers?

Anthony
  • 33,838
  • 42
  • 169
  • 278

1 Answers1

2

Or should I set up docker on each server, copy relevant images to that server, and then start docker-images manually on all servers?

Yes, but you should also:

https://docs.docker.com/engine/userguide/networking/images/overlay_network.png

Then you can create your containers on your machines.

See a practical example at Understand Docker container networks

Community
  • 1
  • 1
VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250
  • I would suggest using a registry for you containers. Building them on each host is fine, but there's not really any need when you can centralise. – Sobrique Jan 22 '16 at 16:38
  • @Sobrique I agree. Interestingly enough, I am currently, for my assignment, building my own registry. Note: beware of the change in addressing the image with docker 1.10 (https://blog.docker.com/2016/01/docker-1-10-rc/) – VonC Jan 22 '16 at 16:40