fix: remap host paths to container mount points for EJCLAW_WORK_DIR and CLAUDE_CONFIG_DIR
Host paths passed via envOverrides don't exist inside the container, causing ENOENT when the SDK tries to spawn with a non-existent CWD. Now remaps EJCLAW_WORK_DIR to /workspace/project and CLAUDE_CONFIG_DIR to /home/node/.claude (matching the container mount points).
This commit is contained in:
@@ -234,6 +234,15 @@ function buildContainerArgs(
|
|||||||
key === 'CLAUDE_CODE_OAUTH_TOKEN'
|
key === 'CLAUDE_CODE_OAUTH_TOKEN'
|
||||||
)
|
)
|
||||||
continue;
|
continue;
|
||||||
|
// Remap host paths to container mount points
|
||||||
|
if (key === 'EJCLAW_WORK_DIR') {
|
||||||
|
args.push('-e', 'EJCLAW_WORK_DIR=/workspace/project');
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
if (key === 'CLAUDE_CONFIG_DIR') {
|
||||||
|
args.push('-e', 'CLAUDE_CONFIG_DIR=/home/node/.claude');
|
||||||
|
continue;
|
||||||
|
}
|
||||||
args.push('-e', `${key}=${value}`);
|
args.push('-e', `${key}=${value}`);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user