Я новичок в докере. У меня установлена версия VS 2017 Community Edition.
Я установил
- Докер для Windows
- Инструменты Docker для Windows.
Я создал новый проект веб-API ASP Dot Net Core 2.0 с включенной опцией «Включить поддержку 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
Я пропустил какое-либо предварительное условие?