I can not debug a container using Visual Studio and ASP.NET 6. Why?
I open the VS2022, go to Debug, Attach to Process...:
Then I select a Connection type, through Find button I select a Connection target:
Then I select a process I need and click Attach. And I pick the Managed (.NET Core for Unix) option:
Then I click OK.
The debug session actually starts, but my breakpoints behave as if there is no debugging going on. So, I can not debug my application.
The application (and hence the container I want to debug) is started outside of the VS as a part of a docker compose (which starts a few other containers). So, now I just opened the source code using VS and hope to somehow debug the application in the container utilizing the opened source code. Is it even possible? Can VS somehow infer that the source code is actually the code of the application in container or what is a correct way to attach to a running container and debug code inside it?


