6

If you create a new ASP.NET Core project in Visual Studio 15.2 and publish it to an Azure App Service, your website says "HTTP Error 502.5 - Process Failure". The same error occurs if you update an existing website.

If you try to run the website manually from the Kudu debug console, you get the error message that ASP.NET Core 1.1.2 isn't installed. This error occurs even though the project has a TargetFramework of netcoreapp1.1 (nothing about 1.1.2).

The exact same new or existing project published just fine a day ago with Visual Studio 15.1. Some subtle change to VS seems to have broken the ability to publish successfully.

How can I fix or work around this problem?

Edward Brey
  • 40,302
  • 20
  • 199
  • 253
  • 4
    This was a horrible example of Microsoft not operating as one company, and .NET Core still being a second-class citizen. How did an out-of-the-box total fail get through testing? And before there was a Googleable solution, debugging was very time consuming. There was no guidance about which log files to dig through, and once you did find the problem, what magical incantation would fix it. The whole thing felt like a fragile black box. – Edward Brey May 11 '17 at 12:07
  • See also http://stackoverflow.com/questions/43915377/azure-web-apps-and-net-core-1-1-2/43924403#43924403 for similar question, and my answer there for more details. – David Ebbo May 11 '17 at 19:54
  • Corresponding [bug report](https://developercommunity.visualstudio.com/content/problem/54605/aspnet-core-http-error-5025-process-failure-error.html) – Edward Brey May 11 '17 at 20:12
  • Actually - not only new project. Seems to be a new bug report. – Andrew Orlov May 11 '17 at 22:43
  • 3
    After spending almost a full day debugging, and learning stuff in Azure, I ended up with this blogpost about how I solved this issue - http://www.danmusk.com/asp-net-core-http-error-502-5-in-azure-webapp/ – DanMusk May 12 '17 at 18:19

1 Answers1

5

My csproj file property TargetFramework contains the value netcoreapp1.0. I have changed it with netcoreapp1.1.1 and all seems going ok for now.

<PropertyGroup> <TargetFramework>netcoreapp1.1.1</TargetFramework> </PropertyGroup>

Andrew Orlov
  • 512
  • 1
  • 4
  • 12
  • 1
    This solution also works fine if your previous TargetFramework was `netcoreapp1.1`. – Edward Brey May 11 '17 at 11:41
  • This problem occurred for me while trying to debug a netcoreapp1.1 locally in a docker container. My TargetFramework was netcoreapp1.1, my dockerfile had "FROM microsoft/aspnetcore:1.1". I changed my dockerfile to "FROM microsoft/aspnetcore:1.1.2" and the problem was solved. – fhilton May 11 '17 at 15:58
  • @fhilton That was a terrible situation for Microsoft. Really - we haven't any tools to debug it. – Andrew Orlov May 11 '17 at 22:33