Forum Discussion
Hugo O. Ornelas
Apr 18, 2023Copper Contributor
ASP.Net Core 6 Web App - Fails to connect to database after published to on-prem IIS
Dear Community, I started to learn .Net core and entity framework, and its great. I built a small webapp as a test with a database (SQL LocalDB) and locally on my dev machine, it works fine. I publ...
playermaker
Apr 20, 2023Copper Contributor
Could you please provide connection string of your application?
- Hugo O. OrnelasApr 24, 2023Copper Contributorplayermaker this is the connection string in "appsettings.json" before publishing:
///////
"ConnectionStrings": {
"DefaultConnection": "Server=(localdb)\\mssqllocaldb;Database=aspnet-mywebapp-db_0_2023-d96111be-23db-4e9f-8e74-adafb6a9edaa;Trusted_Connection=True;MultipleActiveResultSets=true"
},
"Logging": {
"LogLevel": {
"Default": "Information",
"Microsoft.AspNetCore": "Warning"
}
},
"AllowedHosts": "*"
//////