azure-dev/cli
Matt Ellis 6cd82ae9ff
dotnet: Support `dotnet publish` to produce container image (#4573)
The `dotnet` tool has native support for producing (and pushing) a
container image. This does not require a local docker daemon and in
general "does the right thing" and is the prefered way for .NET
customers to produce container
images. https://learn.microsoft.com/dotnet/core/docker/publish-as-container
gives a good overview of how this support works and we've been using
it to build and push container images for Aspire apps.

This change updates things such that we can use this support when
building a non Aspire based .NET app. If a `Dockerfile` exists, we
respect it, but otherwise instead of trying to use Oryx to produce a
container image, we will use `dotnet publish`.

In addition, we now use 8080 as the default port of a `dotnet` based
application (with no Dockerfile) as that's the default port used by
the standard ASP.NET base image.

A new recorded test was added - it builds on top of the existing
`containerapp` sample, and the test aranges to remove the `Dockerfile`
file from the template before running `up`.

Fixes #2632
Fixes #4583
2024-11-22 22:09:57 +00:00
..
azd dotnet: Support `dotnet publish` to produce container image (#4573) 2024-11-22 22:09:57 +00:00
installer Switch rpm tests to use fedora (#4082) 2024-07-11 10:59:28 -07:00
Dockerfile Updates install strategy for kubectl (#3474) 2024-03-05 14:04:03 -08:00
version.txt Increment CLI version after release (#4551) 2024-11-14 20:56:31 +00:00