---
title: DigitalOcean Harness Runtime How-Tos (public)
description: Task-focused guides for deploying agents, managing sessions, permissions, files, and tools.
product: Managed Agents
url: https://docs.digitalocean.com/products/managed-agents/agent-harness-runtime/how-to/
last_updated: "2026-09-21"
---

> **For AI agents:** The documentation index is at [https://docs.digitalocean.com/llms.txt](https://docs.digitalocean.com/llms.txt). Markdown versions of pages use the same URL with `index.html.md` in place of the HTML page (for example, append `index.html.md` to the directory path instead of opening the HTML document).

# DigitalOcean Harness Runtime How-Tos (public)

Generated on 5 Oct 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](https://docs.digitalocean.com/products/managed-agents/agent-harness-runtime/details/what-you-can-build/index.html.md) for example use cases.

## Create Environments

[How to Create an Environment Using a Coding Adapter](https://docs.digitalocean.com/products/managed-agents/agent-harness-runtime/how-to/create-managed-agent/index.html.md): Choose a Harness Runtime adapter for Codex CLI, Claude Code, or OpenCode and start a session from a YAML spec or the Control Panel.

[How to Use Environment Configs](https://docs.digitalocean.com/products/managed-agents/agent-harness-runtime/how-to/use-agent-configs/index.html.md): Save a Harness Runtime spec as a reusable Environment Config, then start sessions from it without resubmitting the YAML.

[How to Use a Custom Sandbox Template (BYOT)](https://docs.digitalocean.com/products/managed-agents/agent-harness-runtime/how-to/use-custom-template/index.html.md): Build a Container Registry image, register it as a Harness Runtime template, and start a session from it.

[How to Configure Agent Permissions](https://docs.digitalocean.com/products/managed-agents/agent-harness-runtime/how-to/configure-permissions/index.html.md): Write session permission policies that allow, deny, or require approval for agent actions.

[How to Secure Harness Runtime Sessions](https://docs.digitalocean.com/products/managed-agents/agent-harness-runtime/how-to/secure-sessions/index.html.md): A checklist for hardening a Harness Runtime session, covering workload isolation, credentials, egress, permission policies, unattended controllers, and cleanup.

## Run Agent Frameworks

[How to Run a LangGraph Agent on Harness Runtime](https://docs.digitalocean.com/products/managed-agents/agent-harness-runtime/how-to/run-langgraph-agent/index.html.md): Package a LangGraph repository, configure model credentials, and deploy your graph on Harness Runtime.

[How to Run a Hermes Agent on Harness Runtime](https://docs.digitalocean.com/products/managed-agents/agent-harness-runtime/how-to/run-hermes-agent/index.html.md): Run the Hermes gateway as a long-lived agent inside a Harness Runtime sandbox and reach its admin dashboard from your machine.

[How to Run an OpenAI Agents API Session](https://docs.digitalocean.com/products/managed-agents/agent-harness-runtime/how-to/run-openai-agents-api-session/index.html.md): Connect an OpenAI Agents API session to a DigitalOcean Harness Runtime sandbox using the CLI, PyDo, or an OpenAI webhook controller.

## Connect Tools

[How to Connect Action Gateway to Harness Runtime](https://docs.digitalocean.com/products/managed-agents/agent-harness-runtime/how-to/connect-action-gateway/index.html.md): Connect Harness Runtime to the full Action Gateway catalog or selected tools, with preloading and execution permissions.

[How to Connect GitHub to a Harness Runtime Session](https://docs.digitalocean.com/products/managed-agents/agent-harness-runtime/how-to/connect-github/index.html.md): Connect a team GitHub account with OAuth so a session can clone, commit, and open pull requests.

## Work with Sessions

[How to Manage Harness Runtime Sessions](https://docs.digitalocean.com/products/managed-agents/agent-harness-runtime/how-to/manage-sessions/index.html.md): List, show, pause, resume, attach, detach, log, and remove Harness Runtime sessions with doctl harness-runtime or the Control Panel.

[How to Connect Through the Codex CLI Proxy](https://docs.digitalocean.com/products/managed-agents/agent-harness-runtime/how-to/use-codex-proxy/index.html.md): Start a local doctl proxy so your local Codex CLI drives a hosted Codex session.

[How to Upload and Download Session Files](https://docs.digitalocean.com/products/managed-agents/agent-harness-runtime/how-to/transfer-files/index.html.md): Upload files into a sandbox and download agent output to your local machine.

[How to Forward Sandbox Ports](https://docs.digitalocean.com/products/managed-agents/agent-harness-runtime/how-to/forward-ports/index.html.md): Open a local tunnel to a port inside a session’s sandbox with doctl harness-runtime port-forward.

[How to Checkpoint, Fork, and Roll Back Sessions](https://docs.digitalocean.com/products/managed-agents/agent-harness-runtime/how-to/checkpoint-fork-rollback-sessions/index.html.md): Save a Harness Runtime session as a checkpoint, then fork it into parallel copies or roll the same session back in place.

## Operate Agents

[How to Run Agents on a Schedule or From a Webhook](https://docs.digitalocean.com/products/managed-agents/agent-harness-runtime/how-to/run-agents-with-triggers/index.html.md): Create cron and webhook triggers that start Harness Runtime sessions unattended and deliver the results to email or Slack.

[How to Monitor Harness Runtime Sessions](https://docs.digitalocean.com/products/managed-agents/agent-harness-runtime/how-to/monitor-sessions/index.html.md): View Harness Runtime metrics in DigitalOcean Insights, including session lifecycle, token usage, approval activity, and sandbox resource usage.

[How to Pay for Harness Runtime](https://docs.digitalocean.com/products/managed-agents/agent-harness-runtime/how-to/pay-for-harness-runtime/index.html.md): Payment options for Harness Runtime, the order in which your balances are used, how to manage an Agent Droplets plan, and what happens when all your balances are empty.