create an isolated docker network named cloudron

we will move from linked containers to an isolated network. This
has the main advantage that linked containers can be upgraded.
For example, I can update the mysql container independently without
breaking the apps that require it. Apps will only see some minor
downtime and will need to reconnect.
This commit is contained in:
Girish Ramakrishnan
2016-06-14 17:44:04 -07:00
parent fee6f3de0f
commit d5ffa53e70

View File

@@ -44,6 +44,7 @@ function initialize(callback) {
async.series([
stopContainers,
createDockerNetwork,
startAddons,
removeOldImages,
existingInfra.version === 'none' ? apps.restoreInstalledApps : apps.configureInstalledApps,
@@ -73,6 +74,10 @@ function stopContainers(callback) {
callback();
}
function createDockerNetwork(callback) {
shell.execSync('createDockerNetwork', 'docker network create --subnet=172.18.0.0/16 cloudron || true', callback);
}
function startGraphite(callback) {
const tag = infra.images.graphite.tag;
const dataDir = paths.DATA_DIR;