first commit
This commit is contained in:
commit
07e4e6b381
13 files changed
+388
No files matched your search
+28
@@ -0,0 +1,28 @@
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
using PaperlessAI.Context;
|
||||
|
||||
var builder = WebApplication.CreateBuilder(args);
|
||||
|
||||
// Add services to the container.
|
||||
|
||||
builder.Services.AddControllers();
|
||||
|
||||
builder.Services.AddDbContextPool<MyDbContext>(options =>
|
||||
{
|
||||
options.UseMySql(
|
||||
builder.Configuration.GetConnectionString("MariaDbConnectionString"),
|
||||
ServerVersion.Parse("12.0.2-mariadb")
|
||||
);
|
||||
});
|
||||
|
||||
var app = builder.Build();
|
||||
|
||||
// Configure the HTTP request pipeline.
|
||||
|
||||
app.UseHttpsRedirection();
|
||||
|
||||
app.UseAuthorization();
|
||||
|
||||
app.MapControllers();
|
||||
|
||||
app.Run();
|
||||
Reference in new issue
Block a user