From d771dcbdb975664647ebc555f6adfcbba5a2b7da Mon Sep 17 00:00:00 2001 From: Seth Troisi Date: Wed, 23 Apr 2025 22:35:40 +0000 Subject: Support GEMINI_CODE_SANDBOX=0/false as no SANDBOXing --- scripts/sandbox_command.sh | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'scripts') diff --git a/scripts/sandbox_command.sh b/scripts/sandbox_command.sh index f22d1295..81775db6 100755 --- a/scripts/sandbox_command.sh +++ b/scripts/sandbox_command.sh @@ -40,6 +40,10 @@ if [ -z "${GEMINI_CODE_SANDBOX:-}" ]; then exit 1; fi # lowercase GEMINI_CODE_SANDBOX GEMINI_CODE_SANDBOX=$(echo "${GEMINI_CODE_SANDBOX:-}" | tr '[:upper:]' '[:lower:]') +if [[ "${GEMINI_CODE_SANDBOX:-}" =~ ^(0|false)$ ]]; then + exit 1 +fi + # if GEMINI_CODE_SANDBOX is set to 1 or true, then try to use docker or podman if [[ "${GEMINI_CODE_SANDBOX:-}" =~ ^(1|true)$ ]]; then if command -v docker &> /dev/null; then -- cgit v1.2.3