From 32f677ca0d9399ee3f44311a7a52cdf27b3ede34 Mon Sep 17 00:00:00 2001 From: Girish Ramakrishnan Date: Thu, 26 Nov 2015 19:18:29 -0800 Subject: [PATCH] make app subcontainers share network namespace with app pid namespace sharing is coming in https://github.com/docker/docker/issues/10163 --- src/docker.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/docker.js b/src/docker.js index 214326dbf..01bb0e183 100644 --- a/src/docker.js +++ b/src/docker.js @@ -190,6 +190,7 @@ function createSubcontainer(app, name, cmd, options, callback) { }, CpuShares: 512, // relative to 1024 for system processes VolumesFrom: isAppContainer ? null : [ app.containerId + ":rw" ], + NetworkMode: isAppContainer ? 'default' : ('container:' + app.containerId), // share network namespace with parent SecurityOpt: config.CLOUDRON ? [ "apparmor:docker-cloudron-app" ] : null // profile available only on cloudron } };