sdk: Windows Container nanoserver:1809 errors out with self-contained ASP.NET 5 app

Steps to reproduce the issue

FROM mcr.microsoft.com/windows/nanoserver:2004 AS runtime  //old

with

FROM mcr.microsoft.com/windows/nanoserver:1809 AS runtime ///new
  • > docker build -t paymentsapp .
  • > docker run -p 8080:80 paymentsapp (API errors out)
Failed to map file. CreateFileMappingW(C:\app\PaymentsService.exe) failed with error 5
Failure processing application bundle.
Failed to map bundle file [C:\app\paymentsservice.runtimeconfig.json]

nanoserver-1809-error

Expected behavior

  • Self-contained ASP.NET 5 should work on nanoserver:1809 base image

Actual behavior

  • Self-contained ASP.NET 5 errors out on nanoserver:1809 base image

Additional information

  • Self-contained ASP.NET 5 works on nanoserver:2004 base image

Output of docker version

Client: Docker Engine - Community
 Azure integration  0.1.15
 Version:           19.03.12
 API version:       1.40
 Go version:        go1.13.10
 Git commit:        48a66213fe
 Built:             Mon Jun 22 15:43:18 2020
 OS/Arch:           windows/amd64
 Experimental:      false

Server: Docker Engine - Community
 Engine:
  Version:          19.03.12
  API version:      1.40 (minimum version 1.24)
  Go version:       go1.13.10
  Git commit:       48a66213fe
  Built:            Mon Jun 22 15:57:30 2020
  OS/Arch:          windows/amd64
  Experimental:     false

Output of docker info

Client:
 Debug Mode: false

Server:
 Containers: 0
  Running: 0
  Paused: 0
  Stopped: 0
 Images: 0
 Server Version: 19.03.12
 Storage Driver: windowsfilter
  Windows: 
 Logging Driver: json-file
 Plugins:
  Volume: local
  Network: ics internal l2bridge l2tunnel nat null overlay private transparent
  Log: awslogs etwlogs fluentd gcplogs gelf json-file local logentries splunk syslog
 Swarm: inactive
 Default Isolation: hyperv
 Kernel Version: 10.0 19041 (19041.1.amd64fre.vb_release.191206-1406)
 Operating System: Windows 10 Pro Version 2004 (OS Build 19041.508)
 OSType: windows
 Architecture: x86_64
 CPUs: 4
 Total Memory: 11.84GiB
 Name: User-dev
 ID: VKKG:XOWC:PWG5:P24F:YDDN:ZDM3:CLXR:NNRV:3BYY:IZKX:KLAY:PZRF
 Docker Root Dir: C:\ProgramData\Docker
 Debug Mode: true
  File Descriptors: -1
  Goroutines: 61
  System Time: 2020-09-22T09:47:20.0758564-04:00
  EventsListeners: 2
 Registry: https://index.docker.io/v1/
 Labels:
 Experimental: false
 Insecure Registries:
  127.0.0.0/8
 Live Restore Enabled: false
 Product License: Community Engine

Original Thread: https://github.com/dotnet/dotnet-docker/issues/2257

About this issue

  • Original URL
  • State: closed
  • Created 4 years ago
  • Reactions: 2
  • Comments: 16 (8 by maintainers)

Most upvoted comments

Re-opening, as this appears to be an issue that needs investigation. I would expect this to work.

I was able to reproduce this issue. It appears related to using PublishSingleFile=true. If you remove the flag, the resulting image works as expected.