How to Connect Through the Codex CLI Proxypublic

Last verified 21 Sep 2026

DigitalOcean Harness Runtime provides managed, hardware-isolated microVM sandboxes with built-in tools such as Chromium to run harnesses and execute arbitrary code. Rich lifecycle APIs preserve conversational history and working state across sessions, letting you pause, resume, and fork work to control costs and adapt to the nonlinear nature of agentic workflows. Scale complete agents such as Claude Code or use sandboxes independently for code execution, all through the same service. See What You Can Build for example use cases.

For Codex sessions, you can drive a hosted session from your local Codex CLI through a local proxy started by doctl.

To connect through the Codex CLI proxy, start a local proxy and connect your local Codex CLI to it. In a terminal, start the proxy for the session:

doctl harness-runtime start-proxy --type codex --session <session-name-or-id>

By default, the proxy listens on local port 1144. You can optionally bind to a different port using the --port argument.

Stop the proxy with Ctrl+C.

Note

Avoid Ctrl+Z, which suspends the process and can leave port 1144 locked.

Next, open another terminal and point Codex at the proxy:

codex --remote ws://127.0.0.1:1144

You can now send prompts to the hosted session through your local Codex interface. Shell commands and some tool calls render in the Codex TUI, and interactive approval prompts follow your agent policy.

To stop a stuck turn, disconnect or terminate the proxy.

When you start the proxy, your session does not auto pause.

We can't find any results for your search.

Try using different keywords or simplifying your search terms.