tweak log parser startup
This commit is contained in:
parent
f44df025ca
commit
698c270211
|
@ -1,4 +1,4 @@
|
|||
using System.IO;
|
||||
using Microsoft.AspNetCore;
|
||||
using Microsoft.AspNetCore.Hosting;
|
||||
|
||||
namespace StardewModdingAPI.Web
|
||||
|
@ -14,10 +14,8 @@ namespace StardewModdingAPI.Web
|
|||
public static void Main(string[] args)
|
||||
{
|
||||
// configure web server
|
||||
new WebHostBuilder()
|
||||
.UseKestrel()
|
||||
.UseContentRoot(Directory.GetCurrentDirectory())
|
||||
.UseIISIntegration()
|
||||
WebHost
|
||||
.CreateDefaultBuilder(args)
|
||||
.UseStartup<Startup>()
|
||||
.Build()
|
||||
.Run();
|
||||
|
|
|
@ -33,7 +33,7 @@ namespace StardewModdingAPI.Web
|
|||
.SetBasePath(env.ContentRootPath)
|
||||
.AddJsonFile("appsettings.json", optional: false, reloadOnChange: true)
|
||||
.AddJsonFile($"appsettings.{env.EnvironmentName}.json", optional: true)
|
||||
.Add(new BeanstalkEnvPropsConfigProvider()) //.AddEnvironmentVariables()
|
||||
.Add(new BeanstalkEnvPropsConfigProvider())
|
||||
.Build();
|
||||
}
|
||||
|
||||
|
@ -63,6 +63,10 @@ namespace StardewModdingAPI.Web
|
|||
{
|
||||
loggerFactory.AddConsole(this.Configuration.GetSection("Logging"));
|
||||
loggerFactory.AddDebug();
|
||||
|
||||
if (env.IsDevelopment())
|
||||
app.UseDeveloperExceptionPage();
|
||||
|
||||
app
|
||||
.UseCors(policy => policy
|
||||
.AllowAnyHeader()
|
||||
|
|
Loading…
Reference in New Issue