18 lines
551 B
C#
18 lines
551 B
C#
|
using Demo.Data.LocalData.Entity;
|
|||
|
using Microsoft.EntityFrameworkCore;
|
|||
|
|
|||
|
public class RemoteDatabaseContext : DbContext
|
|||
|
{
|
|||
|
public DbSet<User> Users { get; set; }
|
|||
|
|
|||
|
public RemoteDatabaseContext(DbContextOptions<RemoteDatabaseContext> options) : base(options) { }
|
|||
|
|
|||
|
protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
|
|||
|
{
|
|||
|
if (!optionsBuilder.IsConfigured)
|
|||
|
{
|
|||
|
optionsBuilder.UseNpgsql("Host=45.67.56.214;Port=5421;Database=PresenceDB;Username=user5;Password=EtEJqhsf");
|
|||
|
}
|
|||
|
}
|
|||
|
}
|