From c8a16a43702d5c9bff06d693993f6bf9facc23d8 Mon Sep 17 00:00:00 2001 From: Andy Date: Fri, 14 Apr 2023 14:48:44 -0400 Subject: [PATCH] Bugfix/base url in docker (#1901) * fixed: BaseUrl option is not supported in Docker - discussion in #1824, the checks should not have been added in the first place * changed: contributors require .NET 7.0+ in order to build --- API/Startup.cs | 1 - CONTRIBUTING.md | 2 +- Kavita.Common/Configuration.cs | 8 -------- 3 files changed, 1 insertion(+), 10 deletions(-) diff --git a/API/Startup.cs b/API/Startup.cs index 8ed57f227..b023d6f51 100644 --- a/API/Startup.cs +++ b/API/Startup.cs @@ -391,7 +391,6 @@ public class Startup { try { - if (new OsInfo(Array.Empty()).IsDocker) return; var htmlDoc = new HtmlDocument(); var indexHtmlPath = Path.Combine(Directory.GetCurrentDirectory(), "wwwroot", "index.html"); htmlDoc.Load(indexHtmlPath); diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 4d81e02a9..238e54542 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -13,7 +13,7 @@ Setup guides, FAQ, the more information we have on the [wiki](https://wiki.kavit - HTML/Javascript editor of choice (VS Code/Sublime Text/Webstorm/Atom/etc) - [Git](https://git-scm.com/downloads) - [NodeJS](https://nodejs.org/en/download/) (Node 16.X.X or higher) -- .NET 6.0+ +- .NET 7.0+ - dotnet tool install -g --version 6.4.0 Swashbuckle.AspNetCore.Cli ### Getting started ### diff --git a/Kavita.Common/Configuration.cs b/Kavita.Common/Configuration.cs index 3a13df04f..96719addb 100644 --- a/Kavita.Common/Configuration.cs +++ b/Kavita.Common/Configuration.cs @@ -213,10 +213,6 @@ public static class Configuration #region BaseUrl private static string GetBaseUrl(string filePath) { - if (new OsInfo(Array.Empty()).IsDocker) - { - return DefaultBaseUrl; - } try { @@ -252,10 +248,6 @@ public static class Configuration private static void SetBaseUrl(string filePath, string value) { - if (new OsInfo(Array.Empty()).IsDocker) - { - return; - } var baseUrl = !value.StartsWith("/") ? $"/{value}"