Disabling hosting startup

- VS injects a bad version of AppInsights because it doesn't
check the shared framework version in use. Since we constantly
are on the bleeding edge, we get out of sync frequently. This
change disables them from running.
This commit is contained in:
David Fowler 2017-05-21 16:46:47 -07:00
parent 2aabce48b4
commit 87c4da41e8
3 changed files with 3 additions and 0 deletions

View File

@ -12,6 +12,7 @@ namespace ChatSample
public static void Main(string[] args)
{
var host = new WebHostBuilder()
.UseSetting(WebHostDefaults.PreventHostingStartupKey, "true")
.ConfigureLogging((context, factory) =>
{
factory.UseConfiguration(context.Configuration.GetSection("Logging"));

View File

@ -12,6 +12,7 @@ namespace SocialWeather
public static void Main(string[] args)
{
var host = new WebHostBuilder()
.UseSetting(WebHostDefaults.PreventHostingStartupKey, "true")
.ConfigureLogging(factory =>
{
factory.AddConsole();

View File

@ -18,6 +18,7 @@ namespace SocketsSample
var host = new WebHostBuilder()
.UseConfiguration(config)
.UseSetting(WebHostDefaults.PreventHostingStartupKey, "true")
.ConfigureLogging(factory =>
{
factory.AddConsole();