aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.ci/azure-pipelines.yml2
-rw-r--r--Emby.Server.Implementations/SocketSharp/WebSocketSharpRequest.cs114
-rw-r--r--README.md2
-rwxr-xr-xbuild2
-rw-r--r--deployment/unraid/docker-templates/jellyfin.xml18
5 files changed, 16 insertions, 122 deletions
diff --git a/.ci/azure-pipelines.yml b/.ci/azure-pipelines.yml
index 7a92d4088..b3389caba 100644
--- a/.ci/azure-pipelines.yml
+++ b/.ci/azure-pipelines.yml
@@ -99,7 +99,7 @@ jobs:
pool:
vmImage: ubuntu-16.04
dependsOn: main_build
- condition: and(succeeded(), variables['System.PullRequest.PullRequestNumber']) # Only execute if the pullrequest numer is defined. (So not for normal CI builds)
+ condition: false #and(succeeded(), variables['System.PullRequest.PullRequestNumber']) # Only execute if the pullrequest numer is defined. (So not for normal CI builds)
strategy:
matrix:
Naming:
diff --git a/Emby.Server.Implementations/SocketSharp/WebSocketSharpRequest.cs b/Emby.Server.Implementations/SocketSharp/WebSocketSharpRequest.cs
index e0a0ee286..792615a0f 100644
--- a/Emby.Server.Implementations/SocketSharp/WebSocketSharpRequest.cs
+++ b/Emby.Server.Implementations/SocketSharp/WebSocketSharpRequest.cs
@@ -25,8 +25,6 @@ namespace Emby.Server.Implementations.SocketSharp
this.OperationName = operationName;
this.request = httpContext;
this.Response = new WebSocketSharpResponse(logger, response);
-
- // HandlerFactoryPath = GetHandlerPathIfAny(UrlPrefixes[0]);
}
public HttpRequest HttpRequest => request;
@@ -100,7 +98,6 @@ namespace Emby.Server.Implementations.SocketSharp
switch (crlf)
{
case 0:
- {
if (c == '\r')
{
crlf = 1;
@@ -117,10 +114,8 @@ namespace Emby.Server.Implementations.SocketSharp
}
break;
- }
case 1:
- {
if (c == '\n')
{
crlf = 2;
@@ -128,10 +123,8 @@ namespace Emby.Server.Implementations.SocketSharp
}
throw new ArgumentException("net_WebHeaderInvalidCRLFChars", nameof(name));
- }
case 2:
- {
if (c == ' ' || c == '\t')
{
crlf = 0;
@@ -139,7 +132,6 @@ namespace Emby.Server.Implementations.SocketSharp
}
throw new ArgumentException("net_WebHeaderInvalidCRLFChars", nameof(name));
- }
}
}
@@ -312,97 +304,7 @@ namespace Emby.Server.Implementations.SocketSharp
return pos == -1 ? strVal : strVal.Slice(0, pos);
}
- public static string HandlerFactoryPath;
-
- private string pathInfo;
- public string PathInfo
- {
- get
- {
- if (this.pathInfo == null)
- {
- var mode = HandlerFactoryPath;
-
- var pos = RawUrl.IndexOf("?", StringComparison.Ordinal);
- if (pos != -1)
- {
- var path = RawUrl.Substring(0, pos);
- this.pathInfo = GetPathInfo(
- path,
- mode,
- mode ?? string.Empty);
- }
- else
- {
- this.pathInfo = RawUrl;
- }
-
- this.pathInfo = WebUtility.UrlDecode(pathInfo);
- this.pathInfo = NormalizePathInfo(pathInfo, mode).ToString();
- }
-
- return this.pathInfo;
- }
- }
-
- private static string GetPathInfo(string fullPath, string mode, string appPath)
- {
- var pathInfo = ResolvePathInfoFromMappedPath(fullPath, mode);
- if (!string.IsNullOrEmpty(pathInfo))
- {
- return pathInfo;
- }
-
- // Wildcard mode relies on this to work out the handlerPath
- pathInfo = ResolvePathInfoFromMappedPath(fullPath, appPath);
- if (!string.IsNullOrEmpty(pathInfo))
- {
- return pathInfo;
- }
-
- return fullPath;
- }
-
- private static string ResolvePathInfoFromMappedPath(string fullPath, string mappedPathRoot)
- {
- if (mappedPathRoot == null)
- {
- return null;
- }
-
- var sbPathInfo = new StringBuilder();
- var fullPathParts = fullPath.Split('/');
- var mappedPathRootParts = mappedPathRoot.Split('/');
- var fullPathIndexOffset = mappedPathRootParts.Length - 1;
- var pathRootFound = false;
-
- for (var fullPathIndex = 0; fullPathIndex < fullPathParts.Length; fullPathIndex++)
- {
- if (pathRootFound)
- {
- sbPathInfo.Append("/" + fullPathParts[fullPathIndex]);
- }
- else if (fullPathIndex - fullPathIndexOffset >= 0)
- {
- pathRootFound = true;
- for (var mappedPathRootIndex = 0; mappedPathRootIndex < mappedPathRootParts.Length; mappedPathRootIndex++)
- {
- if (!string.Equals(fullPathParts[fullPathIndex - fullPathIndexOffset + mappedPathRootIndex], mappedPathRootParts[mappedPathRootIndex], StringComparison.OrdinalIgnoreCase))
- {
- pathRootFound = false;
- break;
- }
- }
- }
- }
-
- if (!pathRootFound)
- {
- return null;
- }
-
- return sbPathInfo.Length > 1 ? sbPathInfo.ToString().TrimEnd('/') : "/";
- }
+ public string PathInfo => this.request.Path.Value;
public string UserAgent => request.Headers[HeaderNames.UserAgent];
@@ -500,19 +402,5 @@ namespace Emby.Server.Implementations.SocketSharp
return httpFiles;
}
}
-
- public static ReadOnlySpan<char> NormalizePathInfo(string pathInfo, string handlerPath)
- {
- if (handlerPath != null)
- {
- var trimmed = pathInfo.AsSpan().TrimStart('/');
- if (trimmed.StartsWith(handlerPath.AsSpan(), StringComparison.OrdinalIgnoreCase))
- {
- return trimmed.Slice(handlerPath.Length).ToString().AsSpan();
- }
- }
-
- return pathInfo.AsSpan();
- }
}
}
diff --git a/README.md b/README.md
index 1f635bdd2..6a206eacf 100644
--- a/README.md
+++ b/README.md
@@ -28,7 +28,7 @@ For more information about the project, please see our [about page](https://jell
<p align="center">
<strong>Want to get started?</strong>
-<em>Choose from <a href="https://jellyfin.readthedocs.io/en/latest/administrator-docs/installing/">Prebuilt Packages</a> or <a href="https://jellyfin.readthedocs.io/en/latest/administrator-docs/building/">Build from Source</a>, then see our <a href="https://jellyfin.readthedocs.io/en/latest/administrator-docs/first-time/">first-time setup guide</a>.</em>
+<em>Choose from <a href="https://jellyfin.readthedocs.io/en/latest/administrator-docs/installing/">Prebuilt Packages</a> or <a href="https://jellyfin.readthedocs.io/en/latest/administrator-docs/building/">Build from Source</a>, then see our <a href="https://jellyfin.readthedocs.io/en/latest/administrator-docs/quick-start/">quick start guide</a>.</em>
</p>
<p align="center">
<strong>Want to contribute?</strong>
diff --git a/build b/build
index 51d4b79a2..fb4ff1984 100755
--- a/build
+++ b/build
@@ -29,7 +29,7 @@ usage() {
echo -e "The web_branch defaults to the same branch name as the current main branch or can be 'local' to not touch the submodule branching."
echo -e "To build all platforms, use 'all'."
echo -e "To perform all build actions, use 'all'."
- echo -e "Build output files are collected at '../jellyfin-build/<platform>'."
+ echo -e "Build output files are collected at '../bin/<platform>'."
}
# Show usage on stderr with exit 1 on argless
diff --git a/deployment/unraid/docker-templates/jellyfin.xml b/deployment/unraid/docker-templates/jellyfin.xml
index 1d97a9f00..57b4cc5ae 100644
--- a/deployment/unraid/docker-templates/jellyfin.xml
+++ b/deployment/unraid/docker-templates/jellyfin.xml
@@ -3,14 +3,15 @@
<TemplateURL>https://raw.githubusercontent.com/jellyfin/jellyfin/deployment/unraid/docker-templates/jellyfin.xml</TemplateURL>
<Beta>False</Beta>
<Category>MediaApp:Video MediaApp:Music MediaApp:Photos MediaServer:Video MediaServer:Music MediaServer:Photos</Category>
- <Name>JellyFin</Name>
+ <Name>Jellyfin</Name>
<Description>
- JellyFin is The Free Software Media Browser Converted By Community Applications Always verify this template (and values) against the dockerhub support page for the container!![br][br]
+ Jellyfin is The Free Software Media Browser Converted By Community Applications Always verify this template (and values) against the dockerhub support page for the container!![br][br]
You can add as many mount points as needed for recordings, movies ,etc. [br][br]
[b][span style='color: #E80000;']Directions:[/span][/b][br]
- [b]/config[/b] : this is where Jellyfin will store it's databases and configuration.[br][br]
+ [b]/config[/b] : This is where Jellyfin will store it's databases and configuration.[br][br]
[b]Port[/b] : This is the default port for Jellyfin. (Will add ssl port later)[br][br]
- [b]Media[/b] : This is the mounting point of your media. When you access it in Jellyfin it will be /media or whatever you chose for a mount point
+ [b]Media[/b] : This is the mounting point of your media. When you access it in Jellyfin it will be /media or whatever you chose for a mount point[br][br]
+ [b]Cache[/b] : This is where Jellyfin will store and manage cached files like images to serve to clients. This is not where all images are stored.[br][br]
[b]Tip:[/b] You can add more volume mappings if you wish Jellyfin has access to it.
</Description>
<Overview>
@@ -35,7 +36,7 @@
</Networking>
<Data>
<Volume>
- <HostDir>/mnt/cache/appdata/config</HostDir>
+ <HostDir>/mnt/user/appdata/Jellyfin</HostDir>
<ContainerDir>/config</ContainerDir>
<Mode>rw</Mode>
</Volume>
@@ -44,8 +45,13 @@
<ContainerDir>/media</ContainerDir>
<Mode>rw</Mode>
</Volume>
+ <Volume>
+ <HostDir>/mnt/user/appdata/Jellyfin/cache/</HostDir>
+ <ContainerDir>/cache</ContainerDir>
+ <Mode>rw</Mode>
+ </Volume>
</Data>
<WebUI>http://[IP]:[PORT:8096]/</WebUI>
- <Icon>https://raw.githubusercontent.com/binhex/docker-templates/master/binhex/images/emby-icon.png</Icon>
+ <Icon>https://raw.githubusercontent.com/binhex/docker-templates/master/binhex/images/jellyfin-icon.png</Icon>
<ExtraParams></ExtraParams>
</Containers>