When I run aspire publish or aspire do prepare-compose command, CLI always rebuilds the apphost and the dependent services.
However, it uses Debug configuration of the solution to build the projects, and there doesn't seem to be a way to set the build configuration.
This can be observed by passing --debug to the CLI and watching the output directories of the dotnet-built projects.
Even if during publishing the CLI uses dotnet publish --configuration Release, I don't understand why it first builds everything in debug.