This post on troubleshooting Windows container connectivity issues between Visual Studio and containers comes to us from Premier Developer consultant Rob Vettor.
The Windows Containers tooling is great! It simplifies the process of containerizing your applications, generating Docker and Compose files and giving you the full Docker CLI (command line interface) with the same API that you would use for Linux containers.
That said, you may come across a problem where Visual Studio cannot connect to underlying Windows container. Error messages can manifest themselves in a couple of ways:
Error response from daemon: Container is not running.
Unable to start debugging on the web server. The Visual Studio 2017 Remote Debugger (MSVSMON.EXE) does not appear to be running on the remote computer.
Good chance the container is running just fine, but Visual Studio (or, Windows, for that matter) cannot connect to it.
Continue reading on Rob’s blog here.