aspire stop command
aspire stop - Stop a running Aspire AppHost.
Synopsis
Section titled “Synopsis”aspire stop [options]Description
Section titled “Description”The aspire stop command stops a running Aspire AppHost process. When no options are provided, the command scans for running AppHosts and stops the in-scope AppHost directly, or prompts you to choose one when multiple AppHosts are available.
When executed without the --apphost option, the command:
- Scans for all running AppHost processes.
- If multiple AppHosts are running within the current directory scope, prompts you to select which one to stop.
- If only one AppHost is running in scope, stops it directly.
- If no in-scope AppHosts are found but out-of-scope AppHosts exist, displays all running AppHosts for selection.
The command sends a stop signal to the CLI process that started the AppHost, which ensures a clean shutdown of all resources including the dashboard and any containers or processes that were started.
Options
Section titled “Options”The following options are available:
-
--apphost <apphost>The path to the Aspire AppHost project file. When specified, the command stops only the AppHost running from that apphost without prompting for selection.
-
--allStop all running AppHosts without prompting for selection.
-
-?, -h, --helpPrints help and usage documentation for the available commands and options.
-
-l, --log-level <Critical|Debug|Error|Information|None|Trace|Warning>Set the minimum log level for console output. Use this option to increase diagnostics while troubleshooting or reduce output in scripted runs.
-
--non-interactiveRun the command in non-interactive mode, disabling all interactive prompts and spinners.
-
--nologoSuppress the startup banner and telemetry notice.
-
--bannerDisplay the animated Aspire CLI welcome banner.
-
--wait-for-debuggerWait for a debugger to attach before running a command.
Examples
Section titled “Examples”-
Stop the AppHost running in the current directory scope:
Aspire CLI aspire stop -
Stop a specific AppHost project:
Aspire CLI aspire stop --apphost './src/MyApp.AppHost/MyApp.AppHost.csproj' -
Stop all running AppHosts:
Aspire CLI aspire stop --all