diff --git a/apps/common/utils/tool_code.py b/apps/common/utils/tool_code.py index e3145c1ab..eb044e730 100644 --- a/apps/common/utils/tool_code.py +++ b/apps/common/utils/tool_code.py @@ -260,7 +260,7 @@ exec({dedent(code)!a}) if proc.poll() is None: #如果仍未终止,强制终止 os.killpg(pgid, signal.SIGKILL) proc.wait() - raise Exception(_("Sandbox process execution timeout, consider increasing MAXKB_SANDBOX_PYTHON_PROCESS_TIMEOUT_SECONDS.")) + raise Exception(_(f"Process execution timed out after {self.process_timeout_seconds} seconds.")) def validate_mcp_transport(self, code_str): servers = json.loads(code_str) diff --git a/installer/Dockerfile-base b/installer/Dockerfile-base index c04a7a6d6..e766fe0e7 100644 --- a/installer/Dockerfile-base +++ b/installer/Dockerfile-base @@ -20,6 +20,8 @@ ARG DEPENDENCIES=" \ RUN ln -sf /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && \ echo "Asia/Shanghai" > /etc/timezone && \ + echo "deb http://deb.debian.org/debian testing main" >> /etc/apt/sources.list && \ + printf "Package: redis-server\nPin: release a=testing\nPin-Priority: 501\n" > /etc/apt/preferences.d/redis && \ apt-get update && apt-get install -y --no-install-recommends $DEPENDENCIES && \ chmod 755 /usr/bin/start-*.sh && \ find /etc/ -type f ! -path '/etc/resolv.conf' ! -path '/etc/hosts' | xargs chmod g-rx && \ diff --git a/installer/sandbox.c b/installer/sandbox.c index 570d0c7b1..c17e0381a 100644 --- a/installer/sandbox.c +++ b/installer/sandbox.c @@ -295,8 +295,12 @@ long syscall(long number, ...) { switch (number) { case SYS_execve: case SYS_execveat: +#ifdef SYS_fork case SYS_fork: +#endif +#ifdef SYS_vfork case SYS_vfork: +#endif case SYS_clone: case SYS_clone3: #ifdef SYS_posix_spawn