WIP: refactoring pour déploiement

Non testé en conditions réelles. À valider avant de pousser.
This commit is contained in:
Paul Schneider 2026-06-14 04:55:18 +01:00
commit 9415521bcb
14 changed files with 125 additions and 28 deletions

View file

@ -12,14 +12,12 @@
using System.IdentityModel.Tokens.Jwt;
using Microsoft.AspNetCore.Authentication;
using Yavsc.Server.Helpers;
JwtSecurityTokenHandler.DefaultMapInboundClaims = true;
var builder = WebApplication.CreateBuilder(args);
builder.Configuration
.AddJsonFile("appsettings-web.json", optional: false, reloadOnChange: false)
.AddJsonFile($"appsettings-blogs.{builder.Environment.EnvironmentName}.json", optional: false, reloadOnChange: false)
.AddEnvironmentVariables();
builder.AddConfiguration("web");
var authSection = builder.Configuration.GetSection("Authentication");
var issuer = authSection.GetValue<String>("Issuer");

View file

@ -6,6 +6,7 @@
</PropertyGroup>
<ItemGroup>
<ProjectReference Include="..\Yavsc.Abstract\Yavsc.Abstract.csproj" />
<ProjectReference Include="..\Yavsc.Abstract\Yavsc.Server.csproj" />
<PackageReference Include="IdentityModel.AspNetCore" />
<PackageReference Include="Microsoft.AspNetCore.Authentication.JwtBearer" />
</ItemGroup>
@ -15,4 +16,4 @@
<CopyToPublishDirectory>PreserveNewest</CopyToPublishDirectory>
</Content>
</ItemGroup>
</Project>
</Project>