|
|
@ -14,13 +14,15 @@ namespace NzbDrone.Host.Owin
|
|
|
|
{
|
|
|
|
{
|
|
|
|
private readonly IConfigFileProvider _configFileProvider;
|
|
|
|
private readonly IConfigFileProvider _configFileProvider;
|
|
|
|
private readonly IEnumerable<IOwinMiddleWare> _owinMiddleWares;
|
|
|
|
private readonly IEnumerable<IOwinMiddleWare> _owinMiddleWares;
|
|
|
|
|
|
|
|
private readonly IServiceProvider _serviceProvider;
|
|
|
|
private readonly Logger _logger;
|
|
|
|
private readonly Logger _logger;
|
|
|
|
private IDisposable _host;
|
|
|
|
private IDisposable _host;
|
|
|
|
|
|
|
|
|
|
|
|
public OwinHostController(IConfigFileProvider configFileProvider, IEnumerable<IOwinMiddleWare> owinMiddleWares, Logger logger)
|
|
|
|
public OwinHostController(IConfigFileProvider configFileProvider, IEnumerable<IOwinMiddleWare> owinMiddleWares, IServiceProvider serviceProvider, Logger logger)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
_configFileProvider = configFileProvider;
|
|
|
|
_configFileProvider = configFileProvider;
|
|
|
|
_owinMiddleWares = owinMiddleWares;
|
|
|
|
_owinMiddleWares = owinMiddleWares;
|
|
|
|
|
|
|
|
_serviceProvider = serviceProvider;
|
|
|
|
_logger = logger;
|
|
|
|
_logger = logger;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
@ -37,7 +39,7 @@ namespace NzbDrone.Host.Owin
|
|
|
|
|
|
|
|
|
|
|
|
_logger.Info("starting server on {0}", url);
|
|
|
|
_logger.Info("starting server on {0}", url);
|
|
|
|
|
|
|
|
|
|
|
|
_host = WebApp.Start(options, BuildApp);
|
|
|
|
_host = WebApp.Start(_serviceProvider, options, BuildApp);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
private void BuildApp(IAppBuilder appBuilder)
|
|
|
|
private void BuildApp(IAppBuilder appBuilder)
|
|
|
|