IW4M-Admin/WebfrontCore/Program.cs
RaidMax d233b8cb50 migrate welcome plugin to .NET Core 2.0
more fixes to stats database for migration
last connection set when client connects and disconnects
update GeoIP datatbase
2018-04-09 14:17:10 -05:00

34 lines
881 B
C#

using System.IO;
using Microsoft.AspNetCore.Hosting;
using SharedLibraryCore.Interfaces;
namespace WebfrontCore
{
public class Program
{
public static IManager Manager;
static void Main(string[] args)
{
throw new System.Exception("Webfront core cannot be run as a standalone application");
}
public static void Init(IManager mgr)
{
Manager = mgr;
BuildWebHost().Run();
}
public static IWebHost BuildWebHost() =>
new WebHostBuilder()
#if DEBUG
.UseContentRoot(Path.GetFullPath(Path.Combine(Directory.GetCurrentDirectory(), @"..\..\..\..\", "WebfrontCore")))
#else
.UseContentRoot(Directory.GetCurrentDirectory())
#endif
.UseKestrel()
.UseStartup<Startup>()
.Build();
}
}