IPC in AI Tooling: Why GitLab Chose stdio Transport over Local HTTP for MCP GitLab engineers detailed why the company's MCP tooling — the `glab mcp serve` bridge and the GitLab Language Server (`gitlab-lsp --stdio`) — uses stdio pipes rather than a local HTTP listener for agent IPC, citing kernel-enforced file-descriptor isolation, no network surface, and automatic EOF lifecycle coupling. While fixing CLI end-to-end tests in merge request !4793, the team found that gVisor's user-space sentry kernel delivered SIGHUP differently from native Linux when a parent closed stdin and the cleanup routine killed its own process group, causing deterministic teardown failures on sandboxed CI runners. The fix registers a scoped SIGHUP listener only at the stdin-EOF teardown transition, avoiding a global mask that would disarm the CI runner's timeout watchdog. Bind a local HTTP server to 127.0.0.1 for an AI coding agent on a multi-tenant developer workstation or shared build host, and you immediately inherit port-collision races, DNS-rebinding vectors, ambient localhost SSRF exposure, and orphaned daemon processes that outlive the parent IDE session. When architecting local Model Context Protocol MCP bridges—such as glab mcp serve and the GitLab Language Server gitlab-lsp --stdio —the transport layer dictates both the security boundary and the process lifecycle contract. Local HTTP requires opening a TCP listener on the loopback interface, negotiating ephemeral ports, managing CORS preflights, and implementing custom bearer-token handshakes just to verify that a local socket caller is actually the spawning IDE rather than an unprivileged local process probing localhost ports. By contrast, anonymous UNIX pipes over stdin / stdout stdio transport enforce kernel-level file-descriptor inheritance: only the parent process that calls fork / execve holds the write end of the child's stdin pipe and the read end of its stdout pipe. There is zero network surface area, zero TLS/port provisioning overhead, and deterministic backpressure governed directly by the kernel pipe buffer. However, relying on stdio lifecycle semantics across heterogeneous execution environments exposes subtle kernel-level signal edge cases. While working on MR 4793 test cli : ignore SIGHUP during scenario cleanup on gVisor runners https://gitlab.com/gitlab-org/editor-extensions/gitlab-lsp/-/merge requests/4793 for gitlab-lsp , I investigated why CLI end-to-end tests communicating over stdio passed on standard Linux VMs but failed deterministically during teardown on sandboxed gVisor CI runners. When the parent closed stdin signaling EOF to the MCP/LSP child process and the cleanup routine killed its own process group to reap child workers, gVisor's user-space sentry kernel google/gvisor commit 553528ee10349d5235f364c4e2cc500f0d4c488a delivered SIGHUP across the foreground process group differently than a native Linux kernel on session-leader exit. Fixing this required surgical signal handling directly inside the stdin EOF teardown path in MR 4793 https://gitlab.com/gitlab-org/editor-extensions/gitlab-lsp/-/merge requests/4793 : registering a scoped SIGHUP listener at the exact transition where stdin closes and the process terminates its own process group, without globally masking SIGHUP during active execution which would disarm the CI runner's own timeout watchdog . GitLab's MCP architecture pairs zero-trust local stdio process isolation in glab and gitlab-lsp with gVisor-sandboxed CI verification and OAuth 2.0 Dynamic Client Registration to the remote /api/v4/mcp server—giving enterprises end-to-end cryptographic identity without exposing a single unauthenticated local TCP port. Architectural Takeaway: Prefer stdio pipes over loopback HTTP for local AI agent IPC to get kernel-enforced descriptor isolation and automatic EOF lifecycle coupling—and explicitly test POSIX signal propagation SIGHUP / SIGTERM under sandboxed kernels like gVisor.