mirror of
https://github.com/QwenLM/qwen-code.git
synced 2025-12-20 16:57:46 +00:00
refactor: consolidate container image tag source of truth to cli package.json (#1156)
This commit is contained in:
@@ -85,18 +85,13 @@ export async function loadSandboxConfig(
|
||||
argv: SandboxCliArgs,
|
||||
): Promise<SandboxConfig | undefined> {
|
||||
const sandboxOption = argv.sandbox ?? settings.sandbox;
|
||||
const sandboxCommand = getSandboxCommand(sandboxOption);
|
||||
if (!sandboxCommand) {
|
||||
return undefined;
|
||||
}
|
||||
const command = getSandboxCommand(sandboxOption);
|
||||
|
||||
const packageJson = await getPackageJson();
|
||||
return {
|
||||
command: sandboxCommand,
|
||||
image:
|
||||
argv['sandbox-image'] ??
|
||||
process.env.GEMINI_SANDBOX_IMAGE ??
|
||||
packageJson?.config?.sandboxImageUri ??
|
||||
'gemini-cli-sandbox',
|
||||
};
|
||||
const image =
|
||||
argv['sandbox-image'] ??
|
||||
process.env.GEMINI_SANDBOX_IMAGE ??
|
||||
packageJson?.config?.sandboxImageUri;
|
||||
|
||||
return command && image ? { command, image } : undefined;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user