cd contrib; make reinstall
This commit is contained in:
parent
bdc974b29b
commit
198d5bc202
13 changed files with 61 additions and 23 deletions
|
|
@ -29,6 +29,10 @@ internal class Program
|
|||
|
||||
var builder = WebApplication.CreateBuilder(args);
|
||||
|
||||
builder.Configuration
|
||||
.AddJsonFile("appsettings-api.json", optional: false, reloadOnChange: false)
|
||||
.AddJsonFile($"appsettings-api.{builder.Environment.EnvironmentName}.json", optional: false, reloadOnChange: false)
|
||||
.AddEnvironmentVariables();
|
||||
var services = builder.Services;
|
||||
|
||||
// Anthropic client
|
||||
|
|
|
|||
|
|
@ -29,7 +29,11 @@ internal class Program
|
|||
Console.Title = "Yavsc.Blogs";
|
||||
|
||||
var builder = WebApplication.CreateBuilder(args);
|
||||
|
||||
builder.Configuration
|
||||
.AddJsonFile("appsettings-blogs.json", optional: false, reloadOnChange: false)
|
||||
.AddJsonFile($"appsettings-blogs.{builder.Environment.EnvironmentName}.json", optional: false, reloadOnChange: false)
|
||||
.AddEnvironmentVariables();
|
||||
|
||||
var services = builder.Services;
|
||||
|
||||
var authority = builder.GetAuthority();
|
||||
|
|
@ -103,9 +107,10 @@ internal class Program
|
|||
.AddSupportedCultures(supportedCultures)
|
||||
.AddSupportedUICultures(supportedCultures);
|
||||
});
|
||||
|
||||
|
||||
using (var app = builder.Build())
|
||||
{
|
||||
|
||||
if (app.Environment.IsDevelopment())
|
||||
app.UseDeveloperExceptionPage();
|
||||
|
||||
|
|
|
|||
|
|
@ -9,7 +9,10 @@ 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();
|
||||
var app = await builder
|
||||
.ConfigureWebAppServices()
|
||||
.ConfigurePipeline();
|
||||
|
|
|
|||
|
|
@ -35,8 +35,7 @@
|
|||
},
|
||||
"Smtp": {
|
||||
"Host": "[YOURSMTPHOST]",
|
||||
"Port": 25,
|
||||
"EnableSSL": false
|
||||
"Port": 465
|
||||
},
|
||||
"DataProtection": {
|
||||
"Keys": {
|
||||
|
|
@ -16,15 +16,18 @@ using Microsoft.AspNetCore.Authentication;
|
|||
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();
|
||||
var authSection = builder.Configuration.GetSection("Authentication");
|
||||
|
||||
var issuer = authSection.GetValue<String>("Issuer");
|
||||
var issuer = authSection.GetValue<String>("Issuer");
|
||||
var clientSection = authSection.GetSection("Client");
|
||||
var clientId = clientSection.GetValue<String>("Id");
|
||||
var clientSecret = clientSection.GetValue<String>("Secret");
|
||||
|
||||
|
||||
|
||||
|
||||
builder.Services.AddControllersWithViews();
|
||||
|
||||
builder.Services
|
||||
|
|
|
|||
|
|
@ -12,6 +12,11 @@ internal class Program
|
|||
private static void Main(string[] args)
|
||||
{
|
||||
HostApplicationBuilder builder = Host.CreateApplicationBuilder(args);
|
||||
builder.Configuration
|
||||
.AddJsonFile("appsettings-cli.json", optional: false, reloadOnChange: false)
|
||||
.AddJsonFile($"appsettings-cli.{builder.Environment.EnvironmentName}.json", optional: false, reloadOnChange: false)
|
||||
.AddEnvironmentVariables();
|
||||
|
||||
AppHost = builder.Build();
|
||||
AppConfiguration = builder.Configuration;
|
||||
AppHost.Start();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue