detect missing sandbox image and provide useful error message (#174)
This commit is contained in:
parent
320f54e205
commit
415ec91c6d
|
@ -24,6 +24,12 @@ CMD=$(scripts/sandbox_command.sh)
|
||||||
IMAGE=gemini-code-sandbox
|
IMAGE=gemini-code-sandbox
|
||||||
DEBUG_PORT=9229
|
DEBUG_PORT=9229
|
||||||
|
|
||||||
|
# stop if image is missing
|
||||||
|
if ! $CMD images -q "$IMAGE" | grep -q .; then
|
||||||
|
echo "ERROR: $IMAGE is missing. Try \`npm run build\` with sandboxing enabled."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
PROJECT=$(basename "$PWD")
|
PROJECT=$(basename "$PWD")
|
||||||
WORKDIR=/sandbox/$PROJECT
|
WORKDIR=/sandbox/$PROJECT
|
||||||
CLI_PATH=/usr/local/share/npm-global/lib/node_modules/\@gemini-code/cli
|
CLI_PATH=/usr/local/share/npm-global/lib/node_modules/\@gemini-code/cli
|
||||||
|
|
Loading…
Reference in New Issue