📝Add Aspire CLI option to publish output file without building container images
- Dominant language
- C#
- Stars
- 6.3k
- Forks
- 991
- Avg merge
- 2d 15h
- Merged PRs (30d)
- 196
Description
Description:
When using , the CLI currently generates deployment output (e.g., Docker Compose) and builds container images as part of the process.
However, there are scenarios where developers only want to produce the publishable configuration/output file and skip building container images.
Example use cases:
• CI/CD pipelines where image building is handled in a separate stage.
• Local development when images are already available in a registry or built previously.
• Need to inspect or version-control the generated deployment files before triggering builds.
Proposed Solution:
Introduce a CLI option to skip the image build phase while still generating the publish output file. For example:
`aspire publish --no-build-images`
or
`dotnet aspire publish --output-only`
or
`true`
Behavior for the proposed flag:
• Generate the deployment file(s) (e.g., , ) as usual.
• Skip all container image builds.
• Optionally allow tag or registry overrides in the generated file.
Benefits:
• Faster iterations when only deployment files are needed.
• Clear separation of responsibilities in build pipelines.
• Supports workflows with prebuilt or externally managed images.
Environment:
• .NET Aspire SDK version: [your version]
• OS: [Windows/macOS/Linux]
• Command:
Additional context:
Other tools like or follow this separation of steps, giving users flexibility to build and deploy in different stages
Contributor guide
Assessment
This issue has not been assessed yet.