How many Docker Host VMs do you create?

ryanjk333

Cadet
Joined
Mar 7, 2016
Messages
6
Hi,

I'm curious to know how many Docker Host VMs people create in FreeNAS for their containers, or if there's a recommended practice for this. The way I see it, there are two options:

1. Create a Docker Host VM for each application (ie. a Docker Host VM for a Wordpress install that contains a Wordpress container and a MariaDB database container), giving each DOcker Host VM a small amount of storage and memory. This method seems like it would allow for good separation of applications, but causes unnecessary overhead with each instance of RancherOS that would be needed, despite it's small size. Plus any unused storage and memory in the Host VM goes to waste.

2. Create one or two large Docker Host VMs with lots of storage and memory and run all Docker containers inside these one or two RancherOS instances. Seems like the least overhead option, but no real separation between applications, and if the Host VM crashes more applications/containers go down.

If it matters, I'm running my FreeNAS in a relatively small production environment on a server large enough to easily accommodate either option.

Thanks in advance for sharing your opinions or any best practices!
 

sretalla

Powered by Neutrality
Moderator
Joined
Jan 1, 2016
Messages
9,703
If you do it right in Rancher (using rancher NFS for all persistent storage), 2 docker host VMs could do it and if one of those fails, Rancher would handle starting up the relevant apps on the second host VM.

Docker is great for reducing overhead when you run many apps on the same host. All you need to worry about is how much risk you want to take if a single host fails.

You would need a third host to run the rancher server itself.
 
Top