microsoft / microsoft/aspire.dev
[What's New Analysis] Document container-based builds / WithDockerfileBuilder
Open
@IEvangelist is already working on this.
Since Jun 2, 2026.
external feedback
- Dominant language
- MDX
- Stars
- 193
- Forks
- 87
- Avg merge
- 1d 22h
- Merged PRs (30d)
- 73
Description
Summary
Aspire 13.0 introduced automatic Dockerfile generation and WithDockerfileBuilder APIs for Python, JavaScript, and custom scenarios. These are experimental but not documented.
What's Missing
From what's-new-in-aspire-13:
Automatic Dockerfile Generation
Python and JavaScript apps automatically generate production-ready Dockerfiles when publishing:
- Multi-stage builds
- Package manager detection (pip/uv, npm/yarn/pnpm)
- Python version detection from
.python-version,pyproject.toml - Node.js version detection from
.nvmrc,.node-version,package.json
WithDockerfileBuilder (Experimental)
// Experimental API
#pragma warning disable ASPIREXXX
var app = builder.AddContainer("myapp", "myimage")
.WithDockerfileBuilder(...);
#pragma warning restore ASPIREXXX
Suggested Content
- Auto Dockerfile generation - How it works for Python/JS
- Version detection - Where versions are read from
- Customizing builds -
WithDockerfileBuilderexperimental API - Multi-stage builds - How they're structured
- Examples - Python with uv, Node with pnpm
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.