Ultimately I want to package an existing WCF application as a docker image. I noticed that setting the enable32BitAppOnWin64 to true causes the service to return HTTP 503.
The system event log on the container contains five entries from the WAS source with the following message:
A process serving application pool 'DefaultAppPool' terminated unexpectedly. The process id was '4484'. The process exit code was '0xc0000139'.
Followed by an entry:
Application pool 'DefaultAppPool' is being automatically disabled due to a series of failures in the process(es) serving that application pool.
When the container is first started, attaching to the container (docker container exec -it test-iis powershell) and listing the app pools (Get-IISAppPool) shows that the default pool is started. After the first request to the service (simple HTTP GET /) HTTP 503 is returned, and listing the app pools shows that the default pool is stopped.
I've tried to distil this down to the simplest example that reproduces the observed behaviour. The following packages a static site, setting the enable32BitAppOnWin64 flag.
Dockerfile
FROM mcr.microsoft.com/windows/servercore/iis:windowsservercore-ltsc2019
SHELL ["powershell"]
RUN Remove-Item -Recurse C:\inetpub\wwwroot\*
# This line seems to cause the issue
RUN Import-Module WebAdministration; Set-ItemProperty -Path 'IIS:\AppPools\DefaultAppPool' -Name 'enable32BitAppOnWin64' -Value 'True';
WORKDIR /inetpub/wwwroot
COPY ./index.html .
Ultimately I want to package an existing WCF application as a docker image. I noticed that setting the
enable32BitAppOnWin64
to true causes the service to return HTTP 503.The system event log on the container contains five entries from the
WAS
source with the following message:Followed by an entry:
When the container is first started, attaching to the container (
docker container exec -it test-iis powershell
) and listing the app pools (Get-IISAppPool
) shows that the default pool is started. After the first request to the service (simple HTTP GET /) HTTP 503 is returned, and listing the app pools shows that the default pool is stopped.I've tried to distil this down to the simplest example that reproduces the observed behaviour. The following packages a static site, setting the
enable32BitAppOnWin64
flag.Dockerfile
Index.html
Build command:
Run command:
Access the service via
http://localhost:8080/
Could someone advise?