Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

396
Views
dotnet ef force me to have connectionString in appsettings.Development.json

I always had connectionString in following files: appsettings.json and appsettings.Development.json. But then I realized. It's enough to have it one place - appsettings.json. Because it's replaced in CI builds anyway. So I removed it from there and application is still working fine.

But then I was trying to update database with command dotnet ef database update --Context AppIdentityDbContext and it turned out that i cannot because dotnet cannot find connection string

System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation.
 ---> System.InvalidOperationException: Could not find a connection string named 'Identity'.

So now I'm forced again to revert that connection string in appsettings.Development.json.

Is there anyway to get rid of it that connectionString from that file. I don't see any reason to keep in two places, just because of that minor reason.

over 4 years ago · Santiago Trujillo
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!