Compare commits

...

2 Commits

Author SHA1 Message Date
flightlevel
f00d8e192a Set the content root to the application folder
https://github.com/Jackett/Jackett/issues/3522
2018-08-04 16:49:26 +10:00
eric@skrobs
9ca4600eab yggtorrent: fix URL (#3515)
Fix YGGTorrent url
2018-08-03 06:15:08 +02:00
2 changed files with 9 additions and 3 deletions

View File

@@ -6,12 +6,13 @@
type: semi-private
encoding: UTF-8
links:
- https://ww2.yggtorrent.is/
- https://ww3.yggtorrent.is/
legacylinks:
- https://yggtorrent.is/
- https://yggtorrent.com/
- https://ww1.yggtorrent.com/
- https://ww1.yggtorrent.is/
- https://ww2.yggtorrent.is/
caps:
categorymappings:

View File

@@ -14,6 +14,7 @@ using System.Collections.Generic;
using System.Diagnostics;
using System.IO;
using System.Linq;
using System.Reflection;
using System.Runtime.InteropServices;
namespace Jackett.Server
@@ -130,7 +131,10 @@ namespace Jackett.Server
try
{
logger.Debug("Creating web host...");
CreateWebHostBuilder(args, url).Build().Run();
string applicationFolder = configurationService.ApplicationFolder();
logger.Debug($"Content root path is: {applicationFolder}");
CreateWebHostBuilder(args, url, applicationFolder).Build().Run();
}
catch (Exception ex)
{
@@ -174,9 +178,10 @@ namespace Jackett.Server
}
}
public static IWebHostBuilder CreateWebHostBuilder(string[] args, string[] urls) =>
public static IWebHostBuilder CreateWebHostBuilder(string[] args, string[] urls, string contentRoot) =>
WebHost.CreateDefaultBuilder(args)
.UseConfiguration(Configuration)
.UseContentRoot(contentRoot)
.UseUrls(urls)
.PreferHostingUrls(true)
.UseStartup<Startup>()