Azure app service with custom Windows container default encoding is incorrect
I have a web app in azure app service using a custom Windows container.
The base image for the docker image is :
mcr.microsoft.com/dotnet/framework/aspnet:4.7.2
The default encoding in the running container is not what I want.
When doing this powershell command in the running container:
[System.Text.Encoding]::Default
The output is :
BodyName : utf-8 EncodingName : Unicode (UTF-8) HeaderName : utf-8 WebName : utf-8 WindowsCodePage : 1200 IsBrowserDisplay : True IsBrowserSave : True IsMailNewsDisplay : True IsMailNewsSave : True IsSingleByte : False EncoderFallback : System.Text.EncoderReplacementFallback DecoderFallback : System.Text.DecoderReplacementFallback IsReadOnly : True CodePage : 65001
But I need :
IsSingleByte : True BodyName : iso-8859-1 EncodingName : Western European (Windows) HeaderName : Windows-1252 WebName : Windows-1252 WindowsCodePage : 1252 IsBrowserDisplay : True IsBrowserSave : True IsMailNewsDisplay : True IsMailNewsSave : True EncoderFallback : System.Text.InternalEncoderBestFitFallback DecoderFallback : System.Text.InternalDecoderBestFitFallback IsReadOnly : True CodePage : 1252
How can I change default encoding (the app in the container is a legacy ASP.NET webforms app and needs to run with iso-8859-1) ?