The question is marked in bold if you wish to skip the explanation of our situation.
I work as a developer for a server network. We deploy multiple instances of our servers. we have 5 types of server types, and between 3-5 instances of each. We use a standalone server with an API for developing add-ons. Each server type has a different set of add-ons that are required.
Currently we're using a folder structure and running the instances manually, as such:
/servers
/server1
/instance1/.
/instance2/.
/server2
/instance1/.
etc...
Each of these instances have a folder named module\ and inside of this folder we have our jar files (the system runs on Java)
Every time our add-on updates, we need to copy it into all instances of the servers that add-on is required on. We want to use symbolic links (ln -s ) and store only one instance of each add-on. This would be ideal, except for the fact that we want to move to virtual instance managing. We've sorted through several options and Docker seems to be the one that fits our needs best, with it's built in load-balancing system.
Most virtual platforms also virtualize the file-system, for example most virtual machines will create a file that contains all information about the file.
The question here is, does Docker virtualize the file-system, or does it mount the instance from the native Ubuntu file-system? I'm aware that Docker uses LXC when available, however I'm not very familliar with how LXC works and if symbolic links can work between instances If it does virtualize then that obviously means sym-links will not be an option. If this is the case then we wouldn't end up using Docker, because for efficiency, systems that save the file-system to a single file or a set of files also increases the amount of writes to the hard-drive, as the file needs to be re-written for any change, and the server instances could be quite large (multiple GB).
lxc.mount.entry
and friends inlxc.container.conf(5)
. However, Docker now has its own library which it uses instead of LXC, from what I understood. Don't use symlinks, use bind-mounts (on folders) in such cases.lxc.container.conf(5)
.