> ## Documentation Index
> Fetch the complete documentation index at: https://docs.agno.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Deploy with Docker

> Run AgentOS locally with Docker, then deploy to any cloud.

This template runs AgentOS and PostgreSQL with pgvector in Docker. It includes agents you can extend with Claude Code, hot-reload for development, and works on any cloud that supports Docker.

## Prerequisites

* [Docker Desktop](https://docker.com/desktop)
* [OpenAI API key](https://platform.openai.com)

## Development

Run locally before deploying to production.

<Steps>
  <Step title="Clone the template">
    ```bash theme={null}
    git clone \
      https://github.com/agno-agi/agentos-docker-template.git \
      agentos

    cd agentos
    ```

    The template includes the following agents:

    | Agent      | Pattern          | Description                                       |
    | :--------- | :--------------- | :------------------------------------------------ |
    | WebSearch  | Direct tools     | Search the web using Parallel SDK or keyless MCP. |
    | CodeSearch | Context provider | Answer questions about this codebase.             |
  </Step>

  <Step title="Set your API key">
    ```bash theme={null}
    cp example.env .env
    ```

    Edit `.env` and add your `OPENAI_API_KEY`.
  </Step>

  <Step title="Start AgentOS">
    ```bash theme={null}
    docker compose up -d --build
    ```
  </Step>

  <Step title="Confirm it's running">
    Navigate to [localhost:8000/docs](http://localhost:8000/docs) to see your AgentOS API.
  </Step>

  <Step title="Connect to the control plane">
    1. Go to [os.agno.com](https://os.agno.com)
    2. Click **Connect OS** → Select **Local**
    3. Enter `http://localhost:8000`

    <Frame>
      <img className="block dark:hidden" src="https://mintcdn.com/agno-v2/Is_2Bv3MNVYdZh1v/images/agent-os-connection-dialog.png?fit=max&auto=format&n=Is_2Bv3MNVYdZh1v&q=85&s=dace555ba53468d3b5d8c8a3a50f9acb" alt="AgentOS connection dialog" width="2472" height="2408" data-path="images/agent-os-connection-dialog.png" />

      <img className="hidden dark:block" src="https://mintcdn.com/agno-v2/mJXVoP_-mVmqJ99G/images/agent-os-connection-docker.png?fit=max&auto=format&n=mJXVoP_-mVmqJ99G&q=85&s=e40e57dd9d902d455b783301b97598ca" alt="AgentOS connection dialog" width="1246" height="1322" data-path="images/agent-os-connection-docker.png" />
    </Frame>
  </Step>
</Steps>

<Check>Your AgentOS is running locally.</Check>

## Cloud Deployment

Deploy this template to any cloud that supports Docker:

| Provider     | Service                                                                                               |
| :----------- | :---------------------------------------------------------------------------------------------------- |
| AWS          | [ECS](https://aws.amazon.com/ecs/), [App Runner](https://aws.amazon.com/apprunner/)                   |
| Google Cloud | [Cloud Run](https://cloud.google.com/run), [Compute Engine](https://cloud.google.com/compute-engine/) |
| Azure        | [Container Apps](https://azure.microsoft.com/en-us/products/container-apps/)                          |
| Platforms    | [Railway](/deploy/templates/railway/deploy), [Render](https://render.com/), [Fly.io](https://fly.io/) |

Build and push your image, set the environment variables from `.env`, and ensure your PostgreSQL instance has pgvector enabled.

## Environment Variables

| Variable               | Required   | Description                                           |
| :--------------------- | :--------- | :---------------------------------------------------- |
| `OPENAI_API_KEY`       | Yes        | OpenAI API key                                        |
| `RUNTIME_ENV`          | No         | `dev` enables hot-reload and disables JWT             |
| `JWT_VERIFICATION_KEY` | Production | Public key from os.agno.com                           |
| `AGENTOS_URL`          | No         | Scheduler base URL (default: `http://127.0.0.1:8000`) |
| `SLACK_BOT_TOKEN`      | No         | Enable Slack interface                                |
| `SLACK_SIGNING_SECRET` | No         | Enable Slack interface                                |

## Next Steps

<CardGroup cols={3}>
  <Card title="Extend" icon="wand-magic-sparkles" href="/deploy/templates/improve-agents">
    Build and improve agents with Claude Code and evals.
  </Card>

  <Card title="Interfaces" icon="comments" href="/deploy/interfaces">
    Connect Slack, Discord, WhatsApp, or MCP.
  </Card>

  <Card title="Reference" icon="book" href="/deploy/templates/docker/reference">
    Manage, customize, and troubleshoot.
  </Card>
</CardGroup>
