© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
C#C
C#•2y ago•
1 reply
tri

what URL should Kestrel listen to in a docker container on Azure App Service

I have an ASP.NET Core in a docker container that will be hosted on Azure App Service. What URL should I have Kestrel, which is inside the container, listen on when deploying to Azure App Service?

My mental model is I could use localhost:8080, then bind that container port 8080 to port 443 of Azure App Service via
-p 443:8080
-p 443:8080
. So when visiting https://myapp.azurewebsites.net, that 443 will be forwarded to 8080 that Kestrel is listening to.

ChatGPT suggested to listen to wildcard 0.0.0.0, but my gut feeling of both localhost and 0.0.0.0 are wrong

So what is the correct way to do? Thank you. I am self-taught and I only have very basic networking knowledge so please explain like I'm 5, and give keywords so that I could research more. Thank you
C# banner
C#Join
We are a programming server aimed at coders discussing everything related to C# (CSharp) and .NET.
61,871Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

deploy rest api container from github & docker hub to Azure app service
C#CC# / help
2y ago
Missing dll on Azure App Service deployment
C#CC# / help
15mo ago
❔ Publish the API app to Azure App Service
C#CC# / help
4y ago
Running gRPC service inside a docker container on a kubernetes cluster
C#CC# / help
2y ago