WIP: refactoring pour déploiement
Non testé en conditions réelles. À valider avant de pousser.
This commit is contained in:
parent
2564d9938e
commit
9415521bcb
14 changed files with 125 additions and 28 deletions
|
|
@ -1,6 +1,7 @@
|
|||
using Anthropic.SDK;
|
||||
using Yavsc.Abstract.Interfaces;
|
||||
using Yavsc.Extensions;
|
||||
using Yavsc.Server.Helpers;
|
||||
|
||||
namespace Yavsc
|
||||
{
|
||||
|
|
@ -9,15 +10,14 @@ namespace Yavsc
|
|||
public static async Task Main(string[] args)
|
||||
{
|
||||
var builder = WebApplication.CreateBuilder(args);
|
||||
builder.Configuration
|
||||
.AddJsonFile("appsettings-org.json", optional: false, reloadOnChange: false)
|
||||
.AddJsonFile($"appsettings-org.{builder.Environment.EnvironmentName}.json", optional: false, reloadOnChange: false)
|
||||
.AddEnvironmentVariables();
|
||||
builder.AddConfiguration("org");
|
||||
var app = await builder
|
||||
.ConfigureWebAppServices()
|
||||
.ConfigurePipeline();
|
||||
|
||||
app.Run();
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
|
@ -2,14 +2,14 @@
|
|||
"Logging": {
|
||||
"LogLevel": {
|
||||
"Default": "Information",
|
||||
"Microsoft.AspNetCore": "Warning" ,
|
||||
"Microsoft.AspNetCore": "Warning",
|
||||
"Microsoft.AspNetCore.SignalR": "Debug",
|
||||
"Microsoft.AspNetCore.Http.Connections": "Debug"
|
||||
}
|
||||
},
|
||||
"AllowedHosts": "*",
|
||||
"ConnectionStrings": {
|
||||
"YavscConnection": "Server=[YOURSERVERNAME];Port=5432;Database=[YOURDBNAME];Username=[YOURDBUSERNAME];Password=[YOURDBPASSW];"
|
||||
"YavscConnection": "*** via dotnet user-secrets ou variable d'environnement *** Server=[YOURSERVERNAME];Port=5432;Database=[YOURDBNAME];Username=[YOURDBUSERNAME];Password=[YOURDBPASSW];"
|
||||
},
|
||||
"Site": {
|
||||
"Title": "yavsc",
|
||||
|
|
@ -81,5 +81,12 @@
|
|||
"Moderation": {
|
||||
"AutoApproveThreshold": 0.7,
|
||||
"AutoRejectThreshold": 0.9
|
||||
},
|
||||
"Kestrel": {
|
||||
"Endpoints": {
|
||||
"Http": {
|
||||
"Url": "http://localhost:3002"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue