Skip to content
Snippets Groups Projects
Unverified Commit 7b1c1170 authored by Rhys Arkins's avatar Rhys Arkins Committed by GitHub
Browse files

fix: log containerbaseDir (#17509)

parent 9b1115a7
Branches
Tags 37.437.1
No related merge requests found
...@@ -232,8 +232,15 @@ export async function generateDockerCommand( ...@@ -232,8 +232,15 @@ export async function generateDockerCommand(
} }
const volumeDirs: VolumeOption[] = [localDir, cacheDir]; const volumeDirs: VolumeOption[] = [localDir, cacheDir];
if (containerbaseDir && cacheDir && !containerbaseDir.startsWith(cacheDir)) { if (containerbaseDir) {
volumeDirs.push(containerbaseDir); if (cacheDir && containerbaseDir.startsWith(cacheDir)) {
logger.debug('containerbaseDir is inside cacheDir');
} else {
logger.debug('containerbaseDir is separate from cacheDir');
volumeDirs.push(containerbaseDir);
}
} else {
logger.debug('containerbaseDir is missing');
} }
volumeDirs.push(...volumes); volumeDirs.push(...volumes);
result.push(...prepareVolumes(volumeDirs)); result.push(...prepareVolumes(volumeDirs));
......
...@@ -105,6 +105,7 @@ async function prepareRawExec( ...@@ -105,6 +105,7 @@ async function prepareRawExec(
GlobalConfig.get(); GlobalConfig.get();
if (binarySource === 'docker' || binarySource === 'install') { if (binarySource === 'docker' || binarySource === 'install') {
logger.debug(`Setting BUILDPACK_CACHE_DIR to ${containerbaseDir!}`);
opts.env ??= {}; opts.env ??= {};
opts.env.BUILDPACK_CACHE_DIR = containerbaseDir; opts.env.BUILDPACK_CACHE_DIR = containerbaseDir;
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment