我是Docker的新手。我的机器上安装了VS 2017社区版。
我已经安装
我创建了一个新的ASP Dot net core 2.0 Web API项目,并启用了“启用Docker支持”选项。
我能够构建默认项目,但是当我开始调试时,它给了我下面的错误。我可以看到使用“ docker image list -a”命令创建了新映像,但是VS无法启动容器。
Severity Code Description Project File Line Suppression State
Error Building webapplication9
Creating dockercompose4820272847090409016_webapplication9_1 ...
[1A[2K
Creating dockercompose4820272847090409016_webapplication9_1 ... [31merror[0m
[1B
ERROR: for dockercompose4820272847090409016_webapplication9_1 Cannot start service webapplication9: container be38d8f606526b8957cbce69c30a9cc329ee79e53f6b216e66d0cdc5895f4a14 encountered an error during CreateProcess: failure in a Windows system call: The system cannot find the file specified. (0x2) extra info: {"CommandLine":"powershell -Command [System.Threading.Thread]::Sleep([System.Threading.Timeout]::Infinite)","User":"ContainerUser","WorkingDirectory":"C:\\app","Environment":{"ASPNETCORE_ENVIRONMENT":"Development","ASPNETCORE_PKG_VERSION":"2.0.3","ASPNETCORE_URLS":"http://+:80","DOTNET_USE_POLLING_FILE_WATCHER":"1","NUGET_FALLBACK_PACKAGES":"c:\\.nuget\\fallbackpackages","NUGET_PACKAGES":"C:\\.nuget\\packages"},"CreateStdInPipe":true,"CreateStdOutPipe":true,"CreateStdErrPipe":true,"ConsoleSize":[0,0]}
ERROR: for webapplication9 Cannot start service webapplication9: container be38d8f606526b8957cbce69c30a9cc329ee79e53f6b216e66d0cdc5895f4a14 encountered an error during CreateProcess: failure in a Windows system call: The system cannot find the file specified. (0x2) extra info: {"CommandLine":"powershell -Command [System.Threading.Thread]::Sleep([System.Threading.Timeout]::Infinite)","User":"ContainerUser","WorkingDirectory":"C:\\app","Environment":{"ASPNETCORE_ENVIRONMENT":"Development","ASPNETCORE_PKG_VERSION":"2.0.3","ASPNETCORE_URLS":"http://+:80","DOTNET_USE_POLLING_FILE_WATCHER":"1","NUGET_FALLBACK_PACKAGES":"c:\\.nuget\\fallbackpackages","NUGET_PACKAGES":"C:\\.nuget\\packages"},"CreateStdInPipe":true,"CreateStdOutPipe":true,"CreateStdErrPipe":true,"ConsoleSize":[0,0]}
Encountered errors while bringing up the project..
For more troubleshooting information, go to http://aka.ms/DockerToolsTroubleshooting docker-compose C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\Sdks\Microsoft.Docker.Sdk\build\Microsoft.VisualStudio.Docker.Compose.targets 346
我缺少任何先决条件吗?