16 lines
397 B
C#
16 lines
397 B
C#
using JOBot.Backend.DAL.Context;
|
|
using JOBot.Backend.Services.gRPC;
|
|
using Microsoft.EntityFrameworkCore;
|
|
|
|
var builder = WebApplication.CreateBuilder(args);
|
|
|
|
builder.Services.AddGrpc();
|
|
builder.Services.AddDbContext<AppDbContext>(options =>
|
|
options.UseNpgsql(builder.Configuration.GetConnectionString("PostgreSQL")));
|
|
|
|
|
|
var app = builder.Build();
|
|
|
|
app.MapGrpcService<UserService>();
|
|
|
|
app.Run(); |