> ## Documentation Index
> Fetch the complete documentation index at: https://libops-renovate-github-com-libops-sitectl-0-x.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# debug

> Collect a diagnostic bundle for the active context.

Use `debug` to capture a snapshot of the active context's state when reporting an issue or diagnosing unexpected behaviour. The bundle prints to stdout by default — pipe it to a file or use `--output` to save it directly.

## Reference

Collect a diagnostic bundle for the active context and print it to stdout.

The bundle includes: host resource summary, Compose service status, container log driver
configuration, Docker image inventory, and plugin-specific diagnostics contributed by the
context's plugin.

Use `--output` to write the bundle to a file instead of printing to stdout.

```bash theme={null}
sitectl debug
```

| Flag            | Default | Description                                   |
| --------------- | ------- | --------------------------------------------- |
| `-o, --output`  |         | Write the bundle to a file instead of stdout. |
| `-v, --verbose` | `false` | Include additional diagnostic details.        |

## Sharing a bundle

```bash theme={null}
# Save to a file
sitectl debug --output debug-bundle.txt

# Capture stdout directly
sitectl debug > debug-bundle.txt
```

Plugin diagnostics are included automatically, so the bundle captures stack-specific state without any extra flags.
