Loading page...Загружаем страницу...正在加载页面...
AtlasRepo

My AI Agent Deploys Code to My Server. Here’s What Keeps It in a Box.

Описание и применение

AI‑агент развертывает приложения на сервере, но стандартные контейнеры не обеспечивают достаточной изоляции. Используя gVisor, каждый контейнер получает собственный пользовательский ядро, что предотвращает escape и ограничивает ресурсы, защищая хост от потенциальных угроз.

Задача

When an AI agent deploys code to a server, there is a risk that buggy dependencies, misbehaving code, or malicious behavior could compromise the host system.

Результат

Deployments are now confined to a gVisor sandbox, preventing container escape and limiting resource usage, thereby protecting the host from agent‑generated code failures or attacks.

Рабочий процесс

  • 1. Install gVisor’s runsc runtime on the server. 2. Register runsc with Docker via daemon.json. 3. Verify gVisor is available with docker info and a hello‑world test. 4. Deploy agentic‑hosting (ah) which checks for runsc on startup. 5. Agent registers and requests a service via the /v1/services API. 6. ah starts the container with runsc, drops all capabilities, sets no‑new‑privileges, read‑only root FS, limited scratch space, process, memory, CPU caps, and a private internal network. 7. Traefik routes external traffic through a separate network; app‑to‑app traffic is disabled. 8. Use the /v1/system/health/detailed endpoint to confirm gVisor is installed. 9. Inspect the container’s Docker inspect output to verify runtime, capabilities, and filesystem settings.

Доказательства

Most apps today ship as containers. A container feels like its own small computer, with its own files and processes. It isn't one.

Источник

gVisor is an open‑source project from Google that adds that wall. It gives each container its own kernel, written in Go, that runs as an ordinary program on the host.

Источник

ah starts the container with these settings. They’re hardcoded in internal/docker/client.go, so you can read them yourself.

Источник

In production, if Docker doesn’t list runsc, ah exits with this error: FATAL: gVisor runtime (runsc) not found in Docker daemon.

Источник

  • Дата записи: 2026-10-17T15:41:23.562Z