diff --git a/src/janitor.js b/src/janitor.js index 9849f415a..c964c4701 100644 --- a/src/janitor.js +++ b/src/janitor.js @@ -28,7 +28,7 @@ async function cleanupTmpVolume(containerInfo) { const cmd = 'find /tmp -type f -mtime +10 -exec rm -rf {} +'.split(' '); // 10 day old files - debug('cleanupTmpVolume %j', containerInfo.Names); + debug(`cleanupTmpVolume ${JSON.stringify(containerInfo.Names)}`); const [error, execContainer] = await safe(gConnection.getContainer(containerInfo.Id).exec({ Cmd: cmd, AttachStdout: true, AttachStderr: true, Tty: false })); if (error) throw new BoxError(BoxError.DOCKER_ERROR, `Failed to exec container: ${error.message}`); @@ -53,4 +53,6 @@ async function cleanupDockerVolumes() { for (const container of containers) { await safe(cleanupTmpVolume(container), { debug }); // intentionally ignore error } + + debug('Cleaned up docker volumes'); }