summary refs log tree commit diff
path: root/extra/admin-api/ConfigTest/Program.cs
diff options
context:
space:
mode:
authorCyber <mateusz.hf18@gmail.com>2025-12-15 08:29:43 +0100
committerGitHub <noreply@github.com>2025-12-15 08:29:43 +0100
commita583d85d443a3af7ebbd3ab87f887748f1439d25 (patch)
tree4da1cc7dc9514969825ef003706849e58840e34f /extra/admin-api/ConfigTest/Program.cs
parentfix: check if event is "opened" or "closed" (diff)
parentfix cors (diff)
downloadserver-ts-a583d85d443a3af7ebbd3ab87f887748f1439d25.tar.xz
Merge branch 'spacebarchat:master' into fix/gh-webhook-events-more
Diffstat (limited to 'extra/admin-api/ConfigTest/Program.cs')
-rw-r--r--extra/admin-api/ConfigTest/Program.cs14
1 files changed, 14 insertions, 0 deletions
diff --git a/extra/admin-api/ConfigTest/Program.cs b/extra/admin-api/ConfigTest/Program.cs
new file mode 100644

index 00000000..5945bcf6 --- /dev/null +++ b/extra/admin-api/ConfigTest/Program.cs
@@ -0,0 +1,14 @@ +using ConfigTest; +using Microsoft.EntityFrameworkCore; +using Spacebar.Db.Contexts; + +var builder = Host.CreateApplicationBuilder(args); +builder.Services.AddHostedService<Worker>(); +builder.Services.AddDbContext<SpacebarDbContext>(options => { + options + .UseNpgsql(builder.Configuration.GetConnectionString("Spacebar")) + .EnableDetailedErrors(); +}, ServiceLifetime.Singleton); + +var host = builder.Build(); +host.Run();