Reputation: 3775
I setup an ASP.NET app under IIS as described here: Run ASP.NET 5 (MVC 6) using .NET Core on IIS
Everything works fine when I access the site with "http://localhost:19691/blahblah", BUT if I replace localhost with the machine's internal IP address (http://10.10.38.57:19691/blahblah), connection is refused. Also "127.0.0.1:19691/blahblah" works fine too. I try all this from the same machine that I have IIS on. If I try "10.10.38.57:80" where my IIS root lives I do get the IIS welcome page. Which is what's expected.
I disabled the firewall on the machine. Is there some Kestrel configuration that I am missing?
Upvotes: 0
Views: 1820
Reputation: 3775
To fix this I had create hosting.json file in the root of the project and put the following in it:
{
"server": "Microsoft.AspNet.Server.Kestrel",
"server.urls": "http://10.10.38.57:19691/"
}
Upvotes: 0