Forum Discussion
Remote debug options for Linux container on App Services
Today I would plan around SSH/tunnel-based diagnostics rather than expecting the Windows App Service "Remote Debugging" switch to work for Linux containers.
For Linux custom containers on App Service, the supported path is to enable SSH in the container, then connect through App Service SSH or `az webapp ssh`. For .NET, you can sometimes attach from Visual Studio to a Linux process over SSH, but it is not the same as the App Service Windows remote debugger experience and it requires the container to expose a usable SSH environment. In production, I would keep that off by default and use a separate debug slot or a temporary diagnostic image.
For routine troubleshooting, I would combine:
1. App Service log stream and container logs.
2. Application Insights/OpenTelemetry traces.
3. SSH only for short-lived inspection.
4. A staging slot with the same image and config for deeper attach-to-process debugging.
Useful docs:
https://learn.microsoft.com/azure/app-service/configure-linux-open-ssh-session
https://learn.microsoft.com/visualstudio/debugger/remote-debugging-dotnet-core-linux-with-ssh