Docker Desktop provides a local interface for building, inspecting, and running containers during .NET development, particularly on Windows and macOS. It complements .NET 7 and later container support and remains useful for local hosting. section 13.2
Use Docker Desktop to:
- Build images from a Dockerfile and register them with Docker. section 13.3.1
- Inspect images, layers, tags, and dangling images after rebuilding. section 13.3.1
- Start containers with port mappings and environment variables such as DOTNET_ENVIRONMENT or Level1__Level2. section 13.4.4 section 13.3.1
Figure 13.5 Docker Desktop starting a container with optional environment-variable settings, including DOTNET_ENVIRONMENT set to Prod1
Use the startup view to set DOTNET_ENVIRONMENT and other configuration values before running a container. section 13.4.4


