将asp.net mvc网站发布到windows容器给出错误

时间:2017-03-26 18:17:49

标签: asp.net-mvc docker visual-studio-2017 windows-container

我正在尝试将基本的mvc网站发布到Windows容器。尝试在分离模式下运行图像时出错。当我运行以下命令时,我能够构建图像并可以看到图像

 docker images

运行图像的命令

 # This line is successful
 docker build -t mvcaspnet . 

 # Error after line mentioned below
 docker run -d --name mvcaspnet1 mvcaspnet 

我跑的时候得到的错误是

docker:来自守护程序的错误响应:容器c0899809 ...在启动期间遇到错误:Windows系统调用失败:由于未从托管Container的虚拟机收到响应,操作超时。 (0xc0370109)。

Docker信息

Containers: 3
 Running: 0
 Paused: 0
 Stopped: 3
Images: 2
Server Version: 17.03.0-ce
Storage Driver: windowsfilter
 Windows:
Logging Driver: json-file
Plugins:
 Volume: local
 Network: l2bridge l2tunnel nat null overlay transparent
Swarm: inactive
Default Isolation: hyperv
Kernel Version: 10.0 14393 (14393.953.amd64fre.rs1_release_inmarket.170303-1614)
Operating System: Windows 10 Pro
OSType: windows
Architecture: x86_64
CPUs: 4
Total Memory: 3.803 GiB
Name: .....
ID: .....
Docker Root Dir: C:\ProgramData\Docker
Debug Mode (client): false
Debug Mode (server): true
 File Descriptors: -1
 Goroutines: 18
 System Time: 2017-03-26T20:15:08.4131848+01:00
 EventsListeners: 0
Registry: https://index.docker.io/v1/
Experimental: true
Insecure Registries:
 127.0.0.0/8
Live Restore Enabled: false

1 个答案:

答案 0 :(得分:0)

不确定用于构建映像的ASP.NET映像,但here是我使用docker compose的方式,因为我需要IIS和SQL Server,并且它按预期工作。