diff --git a/src/dockerproxy.js b/src/dockerproxy.js index e5483ec6f..d69abde97 100644 --- a/src/dockerproxy.js +++ b/src/dockerproxy.js @@ -68,6 +68,7 @@ function containersCreate(req, res, next) { safe.set(req.body, 'HostConfig.NetworkMode', 'cloudron'); // overwrite the network the container lives in safe.set(req.body, 'Labels', _.extend({ }, safe.query(req.body, 'Labels'), { appId: req.app.id })); // overwrite the app id to track containers of an app + debug('Original volume binds:', req.body.HostConfig.Binds); let binds = []; for (let bind of (req.body.HostConfig.Binds || [])) { if (!bind.startsWith('/app/data')) { @@ -77,6 +78,7 @@ function containersCreate(req, res, next) { binds.push(bind.replace(new RegExp('^/app/data'), path.join(paths.APPS_DATA_DIR, req.app.id, 'data'))); } safe.set(req.body, 'HostConfig.Binds', binds); + debug('Rewritten volume binds:', req.body.HostConfig.Binds); let plainBody = JSON.stringify(req.body);