Closed Bigisoft closed 3 years ago
No matter what I do, the database name remains BlazorHero.CleanArchitecture. I even tried context.Database.Migrate() in Program.cs and the name is still BlazorHero.CleanArchitecture. Aliens are taking over the project!!
BlazorHero.CleanArchitecture
context.Database.Migrate()
"Logging": { "LogLevel": { "Default": "Information", "Microsoft": "Warning", "Hangfire": "Warning", "Microsoft.Hosting.Lifetime": "Information" } }, "AllowedHosts": "*", "AppConfiguration": { "Secret": "S0M3RAN0MS3CR3T!1!MAG1C!1!" }, "ConnectionStrings": { "DefaultConnection": "Data Source=(localdb)\\mssqllocaldb;Initial Catalog=BrokenDatabase;Integrated Security=True;MultipleActiveResultSets=True" }, "MailConfiguration": { "From": "info@codewithmukesh.com", "Host": "smtp.ethereal.email", "Port": 587, "UserName": "adaline.pfannerstill49@ethereal.email", "Password": "vAKmWQB8CyPUBg8rBQ", "DisplayName": "Mukesh Murugan" }, //For Serilog Configuration, refer https://codewithmukesh.com/blog/serilog-in-aspnet-core-3-1/ "Serilog": { "MinimumLevel": { "Default": "Information", "Override": { "Microsoft": "Error", "Microsoft.Hosting.Lifetime": "Information", "System": "Information", "Hangfire": "Warning" } }, "WriteTo": [ { "Name": "Console", "Args": { "outputTemplate": "{Timestamp} [{Level}] {Message}{NewLine:1}" } }, { "Name": "File", "Args": { "path": "Logs\\log.txt", "rollingInterval": "Day" } } ], "Enrich": [ "FromLogContext", "WithMachineName", "WithProcessId", "WithThreadId" ], "Properties": { "Application": "BlazorHero.CleanArchitecture.Server" } } }```
Found the problem. There was appsettings.Development.json that was not included in the project.
appsettings.Development.json
No matter what I do, the database name remains
BlazorHero.CleanArchitecture
. I even triedcontext.Database.Migrate()
in Program.cs and the name is stillBlazorHero.CleanArchitecture
. Aliens are taking over the project!!