17 lines
390 B
C#
17 lines
390 B
C#
using AutoubsApi.Persistence.Contexts;
|
|
using Microsoft.EntityFrameworkCore;
|
|
|
|
var builder = WebApplication.CreateBuilder(args);
|
|
|
|
builder.Services.AddDbContext<PostgresContext>(options =>
|
|
options.UseNpgsql(
|
|
builder.Configuration.GetConnectionString("DefaultConnection"),
|
|
npgsqOptions => npgsqOptions.UseNetTopologySuite()
|
|
));
|
|
|
|
var app = builder.Build();
|
|
|
|
|
|
|
|
app.Run();
|