I went to publish an ASP.NET Core web application using Azure through the Publish screen in Visual Studio 2017. I used all of the defaults, though my app uses migrations so I had to tell it to run them in the publish profile.
When I try to access the site, however, I get:
The page cannot be displayed because an internal server error has occurred.
I feel like there is something I need to do with the connection string and the ASPNETCORE_ENVIRONMENT
variable.
I still have the default appsettings.json
and appsettings.Development.json
that you get when creating a new ASP.NET Core web app. The appsettings.json
is pointing to my local development database, and the appsettings.Development.json
is pointing to the Azure database from the publish profile.
Or does the publish profile automatically take care of the connection string and I don't have to do any of the above?