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

# Operate Your AgentOS

> Start, stop, and restart an AgentOS project with Docker Compose, and inspect what is running and connected.

```bash theme={null}
agno up        # docker compose up -d --build
agno down      # docker compose down
agno restart   # down, then up
agno status    # what is running, how it is secured, what is connected
```

`up`, `down`, and `restart` shell out to `docker compose` against your project's compose file. Run them from a project directory created with [`agno create`](https://agno-v2.mintlify.site/cli/create), or point them at a compose file with `--file`.

## Compose File Detection

Without `--file`, the CLI looks for the first match in the current directory, then in `./infra`:

`docker-compose.yml`, `docker-compose.yaml`, `compose.yml`, `compose.yaml`

## up, down, restart

```bash theme={null}
agno up --pull            # pull newer images before starting
agno down --volumes       # also remove named volumes (destroys data)
agno restart --dry-run    # print only the up command; run neither command
```

| Flag | Commands | Description |
| - | - | - |
| `--file`, `-f` | all | Compose file to use |
| `--pull`, `-p` | `up`, `restart` | Always pull newer images |
| `--volumes`, `-v` | `down` | Also remove named volumes. Destroys data. |
| `--dry-run`, `-dr` | all | Print without running. Human-readable `restart` output prints only the `up` command. |
| `--json` | all | Emit a single JSON document after command-line parsing succeeds |

A real `restart` runs `down`, waits two seconds, then runs `up`. A dry run skips the wait and runs neither command. In human-readable mode, `restart --dry-run` prints only the `up` command. With `--json`, its response contains both command payloads.

Typer handles usage errors before the command runs. Unknown commands, unknown flags, missing arguments, and invalid option values exit with code `2` and write diagnostics to stderr. They do not emit JSON, even when `--json` is present.

## status

```bash theme={null}
agno status
```

`status` discovers the AgentOS (see [discovery order](https://agno-v2.mintlify.site/cli/overview.md#how-the-cli-finds-your-agentos)) and reports:

* Base URL and agno version
* MCP endpoint, or `disabled` when the MCP server is off
* Auth mode: `none`, `security_key`, `jwt`, or `unknown` when legacy probing cannot determine the mode
* MCP auth, when the MCP endpoint carries its own OAuth protection
* Each supported client: not detected, detected but not connected, or configured (with the config location)

| Flag | Default | Description |
| - | - | - |
| `--url` | autodiscover | AgentOS base URL |
| `--server-name` | derived from the AgentOS name | MCP server entry name to look for in client configs |
| `--json` | off | Emit a single JSON document after command-line parsing succeeds |

## Next Steps

| Task | Guide |
| - | - |
| Connect coding agents | [agno connect](https://agno-v2.mintlify.site/cli/connect.md) |
| Manage tokens | [agno tokens](https://agno-v2.mintlify.site/cli/tokens.md) |
| Full flag and JSON reference | [agnoctl reference](https://agno-v2.mintlify.site/reference/cli/agnoctl.md) |


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.