/// <summary> /// /// </summary> /// <param name="args"></param> public static void Main(string[] args) { var logServerSettings = BaseHelpers.GetConfigurationRoot(args).GetSection("ElasticSearchSettings").Get <ElasticSearchSettings>(); Log.Logger = new LoggerHelpers(logServerSettings).Register(typeof(Startup).Assembly.GetName().Name, LogEventLevel.Warning); CreateHostBuilder(args).Build().Run(); }
/// <summary> /// /// </summary> /// <param name="args"></param> public static void Main(string[] args) { //https://www.humankode.com/asp-net-core/logging-with-elasticsearch-kibana-asp-net-core-and-docker var logServerSettings = BaseHelpers.GetConfigurationRoot(args).GetSection("ElasticSearchSettings").Get <ElasticSearchSettings>(); Log.Logger = new LoggerHelpers(logServerSettings).Register(typeof(Startup).Assembly.GetName().Name, LogEventLevel.Warning); CreateHostBuilder(args).Build().Run(); }