Updated lots of stuff, got multi scrape working, need to test not-nullable chapter novel ids with our current model, now supports sqlite and postgres concurrently (and easy add more), need to get it deployed/do auth
Some checks failed
continuous-integration/drone/push Build is failing
Some checks failed
continuous-integration/drone/push Build is failing
This commit is contained in:
21
DBConnection/Contexts/PostgresSqlAppDbContext.cs
Normal file
21
DBConnection/Contexts/PostgresSqlAppDbContext.cs
Normal file
@@ -0,0 +1,21 @@
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
using Microsoft.Extensions.Configuration;
|
||||
|
||||
namespace DBConnection.Contexts;
|
||||
|
||||
/// <summary>
|
||||
/// Pulls connection string from 'PostgresSql' and selected with provider 'PostgresSql'
|
||||
/// </summary>
|
||||
public class PostgresSqlAppDbContext : AppDbContext
|
||||
{
|
||||
public PostgresSqlAppDbContext(DbContextOptions options, IConfiguration configuration) : base(options, configuration)
|
||||
{
|
||||
}
|
||||
|
||||
protected override string ConnectionStringName => "PostgresSql";
|
||||
|
||||
protected override void UseSqlConnection(DbContextOptionsBuilder builder, string connectionString)
|
||||
{
|
||||
builder.UseNpgsql(connectionString);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user