Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions src/frontend/config/sidebar/reference.topics.ts
Original file line number Diff line number Diff line change
Expand Up @@ -301,6 +301,10 @@ export const referenceTopics: StarlightSidebarTopicsUserConfig = {
label: 'aspire deploy',
slug: 'reference/cli/commands/aspire-deploy',
},
{
label: 'aspire describe',
slug: 'reference/cli/commands/aspire-describe',
},
{ label: 'aspire do', slug: 'reference/cli/commands/aspire-do' },
{
label: 'aspire docs',
Expand Down
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @copilot, we should update what's new in 13.2 with a link to this command.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added a "Resource monitoring with aspire describe" section under the CLI enhancements in the what's new 13.2 page in 3531b21. It covers the rename from aspire resources, the --watch--follow/-f change, and includes a LearnMore link to the command reference.

Original file line number Diff line number Diff line change
@@ -0,0 +1,126 @@
---
title: aspire describe command
description: Learn about the aspire describe command which displays resource details for a running Aspire AppHost, with optional continuous streaming.
---

import Include from '@components/Include.astro';
import { Aside, Steps } from '@astrojs/starlight/components';

## Name

`aspire describe` - Describe resources in a running AppHost.

## Synopsis

```bash title="Aspire CLI"
aspire describe [<resource>] [options]
```

## Description

The `aspire describe` command displays resource details for a running Aspire AppHost. By default, it shows a snapshot table of all resources with their name, type, state, health status, and endpoints. Use the `--follow` option to continuously stream resource state changes in real time.

When a specific resource name is provided, only matching resources are displayed. If no matching resource is found, the command returns an error.

When executed without the `--apphost` option, the command:

<Steps>

1. Scans for all running AppHost processes.
2. If multiple AppHosts are running within the current directory scope, prompts you to select which one to target.
3. If only one AppHost is running in scope, connects to it directly.
4. If no in-scope AppHosts are found but out-of-scope AppHosts exist, displays all running AppHosts for selection.
Comment on lines +29 to +32
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add an import to Steps and wrap this in that component.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done in 3531b21 — added Steps import and wrapped the numbered list in the <Steps> component.


</Steps>

<Aside type="tip">
The `aspire resources` command is a backward-compatible alias for `aspire describe`. Both names invoke the same command.
</Aside>

## Arguments

- **`<resource>`**

The name of the resource to display. If not specified, all resources are shown.

## Options

The following options are available:

- **`-f, --follow`**

Continuously stream resource state changes. In table mode, each update prints a line showing the resource name, state, health, and endpoints. In JSON mode, each update emits a single JSON object per line ([Newline Delimited JSON (NDJSON)](https://github.com/ndjson/ndjson-spec) format).

- **`--apphost <path>`**

The path to the Aspire AppHost project file. When specified, the command connects to the AppHost running from that project file without prompting for selection.

- **`--format <Json|Table>`**
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @copilot, please add a note about the format arg being case-insensitive.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added in 8f50ee5 — follows the same pattern as aspire wait (Values are case-insensitive.).

format option with case-insensitive note


Output format. Use `Json` for machine-readable output suitable for scripting and automation. Defaults to `Table`. Values are case-insensitive.

In snapshot mode (without `--follow`), JSON output wraps resources in a `{ "resources": [...] }` object. In follow mode, JSON output uses [Newline Delimited JSON (NDJSON)](https://github.com/ndjson/ndjson-spec) for streaming, emitting one JSON object per line.

- <Include relativePath="reference/cli/includes/option-help.md" />

- <Include relativePath="reference/cli/includes/option-debug.md" />

## Examples

- Show all resources in a running AppHost:

```bash title="Aspire CLI"
aspire describe
```

Example output:

```text title="Output"
Name Type State Health Endpoints
cache container Running Healthy tcp://localhost:63122
webfrontend project Running Healthy https://localhost:17015, http://localhost:15099
apiservice project Running Healthy https://localhost:17016, http://localhost:15100
```

- Show details for a specific resource:

```bash title="Aspire CLI"
aspire describe webfrontend
```

- Continuously stream resource state changes:

```bash title="Aspire CLI"
aspire describe --follow
```

- Stream state changes for a specific resource:

```bash title="Aspire CLI"
aspire describe webfrontend --follow
```

- Output resource details as JSON:

```bash title="Aspire CLI"
aspire describe --format Json
```

- Stream resource changes as Newline Delimited JSON (NDJSON) for scripting:

```bash title="Aspire CLI"
aspire describe --follow --format Json
```

- Target a specific AppHost project:

```bash title="Aspire CLI"
aspire describe --apphost './src/MyApp.AppHost/MyApp.AppHost.csproj'
```

## See also

- [aspire run](/reference/cli/commands/aspire-run/)
- [aspire ps](/reference/cli/commands/aspire-ps/)
- [aspire wait](/reference/cli/commands/aspire-wait/)
- [aspire stop](/reference/cli/commands/aspire-stop/)
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ The following commands are available:
| [`aspire cache`](../aspire-cache/) | Stable | Manage disk cache for CLI operations. |
| [`aspire config`](../aspire-config/) | Stable | Configures the Aspire environment. |
| [`aspire deploy`](../aspire-deploy/) | Preview | Deploys the artifacts created by `aspire publish`. |
| [`aspire describe`](../aspire-describe/) | Stable | Describe resources in a running AppHost. |
| [`aspire do`](../aspire-do/) | Preview | Execute a specific pipeline step and its dependencies. |
| [`aspire docs`](../aspire-docs/) | Stable | Browse and search Aspire documentation from aspire.dev. |
| [`aspire doctor`](../aspire-doctor/) | Stable | Check the development environment for common issues. |
Expand Down
8 changes: 8 additions & 0 deletions src/frontend/src/content/docs/reference/cli/overview.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,14 @@ The `aspire exec` command runs a command in the context of a specific Aspire res
[Command reference: `aspire exec`](../commands/aspire-exec/)
</LearnMore>

## Describe resources

The `aspire describe` command displays resource details for a running Aspire AppHost, including name, type, state, health status, and endpoints. Use it to get a quick snapshot of all resources or continuously stream state changes with the `--follow` flag.

<LearnMore>
[Command reference: `aspire describe`](../commands/aspire-describe/)
</LearnMore>

## Manage CLI configuration

The `aspire config` command lets you manage Aspire CLI configuration settings. Use it to `list`, `get`, `set`, or `delete` configuration values that control CLI behavior. This command is also used to toggle features on or off.
Expand Down
16 changes: 16 additions & 0 deletions src/frontend/src/content/docs/whats-new/aspire-13-2.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,22 @@ aspire run --isolated

Isolated mode assigns random ports and creates separate user secrets for each run, preventing port conflicts and configuration collisions. This is particularly useful when switching between different Aspire projects or running integration tests that need dedicated ports.

### Resource monitoring with `aspire describe`

The `aspire resources` command has been renamed to `aspire describe` (with `resources` kept as a backward-compatible alias) to better align with `kubectl`-style conventions. The `--watch` flag has also been renamed to `--follow`/`-f` for consistency with `aspire logs --follow`.

```bash title="Aspire CLI — Describe resources"
# Show all resources in a running AppHost
aspire describe

# Continuously stream resource state changes
aspire describe --follow
```

<LearnMore>
Command reference: [`aspire describe`](/reference/cli/commands/aspire-describe/).
</LearnMore>

### Environment diagnostics with `aspire doctor`

The new `aspire doctor` command provides comprehensive diagnostics of your development environment:
Expand Down