Site does not connect to the database after it has been published

0

I published a WEB application (developed in C# ) in Azure that uses a database, it happens that when I try to run it through the domain provided by Azure, it gives me the following error:

  

"Server Error in '/' Application."
  "Login failed for user '{my name}'".

So I realized the error has to do with access to the data.

When I test the connection in Visual Studio, before publishing, it gives me no error. I can also access the server through Server Object Explorer without any problem. I've researched a lot and tried several things, but nothing seems to work.

In my project I use Entity Framework Code First Migrations .

    
asked by anonymous 13.04.2017 / 20:20

1 answer

0

You should configure your database to be accessed from App Services - in your case, a WebApp.

  • Access the firewall rules of your database.
  • From access permission by Azure Services.
  • Ibelievethisshouldsolvetheproblem.

    Seeheretolearnmoreabout create and manage firewall rules on Azure .

        
    18.04.2017 / 12:28