.NET 10: further align the runtime image with Microsoft images.#519
.NET 10: further align the runtime image with Microsoft images.#519tmds merged 3 commits intoredhat-developer:mainfrom
Conversation
SDK specific envvars are moved from the runtime to the SDK image. All s2i related functionality is moved into the SDK image. WORKDIR, CMD, and PATH envvar are set to match with Microsoft images. The DOTNET_DATA_PATH dir is removed. It is left to the user's application to create such a directory (if needed).
|
|
||
| USER 0 | ||
| # Don't clutter the app user's HOME | ||
| ENV HOME= |
There was a problem hiding this comment.
I prefer this over letting root mess in the app user's HOME and then having to fix permissions for those files.
This way, we separate between the root and app user's HOME.
| # Don't download/extract docs for nuget packages | ||
| NUGET_XMLDOC_MODE=skip \ | ||
| # Configure ASP.NET Core to use the exposed port | ||
| ASPNETCORE_URLS=http://*:8080 \ |
There was a problem hiding this comment.
Or, maybe set ASPNETCORE_HTTP_PORTS like the Microsoft image does?
There was a problem hiding this comment.
We adopted and reverted it for .NET 8: #474.
I'm ok with changing to ASPNETCORE_HTTP_PORTS for .NET 10.
There was a problem hiding this comment.
Thank you for that context. Given the regression and that we reverted it, I am okay with leaving it as it is. Up to you what you prefer here.
There was a problem hiding this comment.
I'm going to merge this without changing ASPNETCORE_HTTP_PORTS. As time permits, I'll take a closer look into making this change for .NET 10 or not.
| DOTNET_APP_PATH=/opt/app-root/app \ | ||
| DOTNET_DEFAULT_CMD=default-cmd.sh \ | ||
| # Don't generate a developer certificate | ||
| DOTNET_GENERATE_ASPNET_CERTIFICATE=false \ |
There was a problem hiding this comment.
Microsoft images also set DOTNET_ROLL_FORWARD.
There was a problem hiding this comment.
It seems they do it in the SDK image because PowerShell (which is part of the MS SDK image) didn't roll forward.
I think we can continue to leave it out.
|
@omajid, thanks for the thorough review! |
SDK specific envvars are moved from the runtime to the SDK image.
All s2i related functionality is moved into the SDK image.
WORKDIR, CMD, and PATH envvar are set to match with Microsoft images.
The DOTNET_DATA_PATH dir is removed. It is left to the user's application to create such a directory (if needed).