diff options
Diffstat (limited to 'MediaBrowser.Model/Configuration/ServerConfiguration.cs')
| -rw-r--r-- | MediaBrowser.Model/Configuration/ServerConfiguration.cs | 107 |
1 files changed, 82 insertions, 25 deletions
diff --git a/MediaBrowser.Model/Configuration/ServerConfiguration.cs b/MediaBrowser.Model/Configuration/ServerConfiguration.cs index 063ccd9b9..48d1a7346 100644 --- a/MediaBrowser.Model/Configuration/ServerConfiguration.cs +++ b/MediaBrowser.Model/Configuration/ServerConfiguration.cs @@ -1,7 +1,10 @@ +#nullable disable #pragma warning disable CS1591 using System; +using System.Collections.Generic; using MediaBrowser.Model.Dto; +using MediaBrowser.Model.Updates; namespace MediaBrowser.Model.Configuration { @@ -49,17 +52,24 @@ namespace MediaBrowser.Model.Configuration public int HttpsPortNumber { get; set; } /// <summary> - /// Gets or sets a value indicating whether [use HTTPS]. + /// Gets or sets a value indicating whether to use HTTPS. /// </summary> - /// <value><c>true</c> if [use HTTPS]; otherwise, <c>false</c>.</value> + /// <remarks> + /// In order for HTTPS to be used, in addition to setting this to true, valid values must also be + /// provided for <see cref="CertificatePath"/> and <see cref="CertificatePassword"/>. + /// </remarks> public bool EnableHttps { get; set; } + public bool EnableNormalizedItemByNameIds { get; set; } /// <summary> - /// Gets or sets the value pointing to the file system where the ssl certificate is located.. + /// Gets or sets the filesystem path of an X.509 certificate to use for SSL. /// </summary> - /// <value>The value pointing to the file system where the ssl certificate is located..</value> public string CertificatePath { get; set; } + + /// <summary> + /// Gets or sets the password required to access the X.509 certificate data in the file specified by <see cref="CertificatePath"/>. + /// </summary> public string CertificatePassword { get; set; } /// <summary> @@ -68,10 +78,14 @@ namespace MediaBrowser.Model.Configuration /// <value><c>true</c> if this instance is port authorized; otherwise, <c>false</c>.</value> public bool IsPortAuthorized { get; set; } + /// <summary> + /// Gets or sets if quick connect is available for use on this server. + /// </summary> + public bool QuickConnectAvailable { get; set; } + public bool AutoRunWebApp { get; set; } + public bool EnableRemoteAccess { get; set; } - public bool CameraUploadUpgraded { get; set; } - public bool CollectionsUpgraded { get; set; } /// <summary> /// Gets or sets a value indicating whether [enable case sensitive item ids]. @@ -86,6 +100,7 @@ namespace MediaBrowser.Model.Configuration /// </summary> /// <value>The metadata path.</value> public string MetadataPath { get; set; } + public string MetadataNetworkPath { get; set; } /// <summary> @@ -101,19 +116,19 @@ namespace MediaBrowser.Model.Configuration public string MetadataCountryCode { get; set; } /// <summary> - /// Characters to be replaced with a ' ' in strings to create a sort name + /// Characters to be replaced with a ' ' in strings to create a sort name. /// </summary> /// <value>The sort replace characters.</value> public string[] SortReplaceCharacters { get; set; } /// <summary> - /// Characters to be removed from strings to create a sort name + /// Characters to be removed from strings to create a sort name. /// </summary> /// <value>The sort remove characters.</value> public string[] SortRemoveCharacters { get; set; } /// <summary> - /// Words to be removed from strings to create a sort name + /// Words to be removed from strings to create a sort name. /// </summary> /// <value>The sort remove words.</value> public string[] SortRemoveWords { get; set; } @@ -152,12 +167,6 @@ namespace MediaBrowser.Model.Configuration public bool EnableDashboardResponseCaching { get; set; } /// <summary> - /// Gets or sets a custom path to serve the dashboard from. - /// </summary> - /// <value>The dashboard source path, or null if the default path should be used.</value> - public string DashboardSourcePath { get; set; } - - /// <summary> /// Gets or sets the image saving convention. /// </summary> /// <value>The image saving convention.</value> @@ -208,28 +217,63 @@ namespace MediaBrowser.Model.Configuration public int RemoteClientBitrateLimit { get; set; } public bool EnableFolderView { get; set; } + public bool EnableGroupingIntoCollections { get; set; } + public bool DisplaySpecialsWithinSeasons { get; set; } + public string[] LocalNetworkSubnets { get; set; } + public string[] LocalNetworkAddresses { get; set; } + public string[] CodecsUsed { get; set; } + + public List<RepositoryInfo> PluginRepositories { get; set; } + public bool IgnoreVirtualInterfaces { get; set; } + public bool EnableExternalContentInSuggestions { get; set; } + + /// <summary> + /// Gets or sets a value indicating whether the server should force connections over HTTPS. + /// </summary> public bool RequireHttps { get; set; } - public bool IsBehindProxy { get; set; } + public bool EnableNewOmdbSupport { get; set; } public string[] RemoteIPFilter { get; set; } + public bool IsRemoteIPFilterBlacklist { get; set; } public int ImageExtractionTimeoutMs { get; set; } public PathSubstitution[] PathSubstitutions { get; set; } + public bool EnableSimpleArtistDetection { get; set; } public string[] UninstalledPlugins { get; set; } /// <summary> + /// Gets or sets a value indicating whether slow server responses should be logged as a warning. + /// </summary> + public bool EnableSlowResponseWarning { get; set; } + + /// <summary> + /// Gets or sets the threshold for the slow response time warning in ms. + /// </summary> + public long SlowResponseThresholdMs { get; set; } + + /// <summary> + /// Gets or sets the cors hosts. + /// </summary> + public string[] CorsHosts { get; set; } + + /// <summary> + /// Gets or sets the known proxies. + /// </summary> + public string[] KnownProxies { get; set; } + + /// <summary> /// Initializes a new instance of the <see cref="ServerConfiguration" /> class. /// </summary> public ServerConfiguration() @@ -242,6 +286,9 @@ namespace MediaBrowser.Model.Configuration PathSubstitutions = Array.Empty<PathSubstitution>(); IgnoreVirtualInterfaces = false; EnableSimpleArtistDetection = false; + SkipDeserializationForBasicTypes = true; + + PluginRepositories = new List<RepositoryInfo>(); DisplaySpecialsWithinSeasons = true; EnableExternalContentInSuggestions = true; @@ -255,9 +302,13 @@ namespace MediaBrowser.Model.Configuration EnableHttps = false; EnableDashboardResponseCaching = true; EnableCaseSensitiveItemIds = true; + EnableNormalizedItemByNameIds = true; + DisableLiveTvChannelUserDataName = true; + EnableNewOmdbSupport = true; AutoRunWebApp = true; EnableRemoteAccess = true; + QuickConnectAvailable = false; EnableUPnP = false; MinResumePct = 5; @@ -293,24 +344,24 @@ namespace MediaBrowser.Model.Configuration new MetadataOptions { ItemType = "MusicVideo", - DisabledMetadataFetchers = new [] { "The Open Movie Database" }, - DisabledImageFetchers = new [] { "The Open Movie Database" } + DisabledMetadataFetchers = new[] { "The Open Movie Database" }, + DisabledImageFetchers = new[] { "The Open Movie Database" } }, new MetadataOptions { ItemType = "Series", - DisabledMetadataFetchers = new [] { "TheMovieDb" }, - DisabledImageFetchers = new [] { "TheMovieDb" } + DisabledMetadataFetchers = new[] { "TheMovieDb" }, + DisabledImageFetchers = new[] { "TheMovieDb" } }, new MetadataOptions { ItemType = "MusicAlbum", - DisabledMetadataFetchers = new [] { "TheAudioDB" } + DisabledMetadataFetchers = new[] { "TheAudioDB" } }, new MetadataOptions { ItemType = "MusicArtist", - DisabledMetadataFetchers = new [] { "TheAudioDB" } + DisabledMetadataFetchers = new[] { "TheAudioDB" } }, new MetadataOptions { @@ -319,21 +370,27 @@ namespace MediaBrowser.Model.Configuration new MetadataOptions { ItemType = "Season", - DisabledMetadataFetchers = new [] { "TheMovieDb" }, + DisabledMetadataFetchers = new[] { "TheMovieDb" }, }, new MetadataOptions { ItemType = "Episode", - DisabledMetadataFetchers = new [] { "The Open Movie Database", "TheMovieDb" }, - DisabledImageFetchers = new [] { "The Open Movie Database", "TheMovieDb" } + DisabledMetadataFetchers = new[] { "The Open Movie Database", "TheMovieDb" }, + DisabledImageFetchers = new[] { "The Open Movie Database", "TheMovieDb" } } }; + + EnableSlowResponseWarning = true; + SlowResponseThresholdMs = 500; + CorsHosts = new[] { "*" }; + KnownProxies = Array.Empty<string>(); } } public class PathSubstitution { public string From { get; set; } + public string To { get; set; } } } |
