Closed NaturalBornCamper closed 1 year ago
Since this is a value set and implemented in jellyfin itself, I'm not sure how you go about changing it besides looking at the documentation; I've personally never had to change it before. As far as I know, the web path is only meant for when jellyfin is hosting the website itself, so if you've got it hosted through something like apache/nginx I'm not sure whether or not jellyfin will load the provided web path at all. If this is not the case (i.e. you didn't go out of your way to unzip jellyfin-web and use different web software), then the web path must already be set, or your website wouldn't work at all.
What do the jellyfin logs say about script injection? Most of the time it's just a permissions error.
Thanks for your answer friend!
Log doesn't say anything, this is what's weird. Just restarted it again, that's the ouput (And you can see the JELLYFIN_WEB_DIR variable that I forced:
[2023-03-18 14:43:23.252 -04:00] [INF] Jellyfin version: "10.8.9"
[2023-03-18 14:43:23.350 -04:00] [INF] Environment Variables: ["[JELLYFIN_CACHE_DIR, /mnt/dietpi_userdata/jellyfin/cache]", "[JELLYFIN_WEB_OPT, --webdir=/usr/share/jellyfin/web]", "[JELLYFIN_FFMPEG_OPT, --ffmpeg=/usr/lib/jellyfin-ffmpeg/ffmpeg]", "[JELLYFIN_DATA_DIR, /mnt/dietpi_userdata/jellyfin]", "[JELLYFIN_USER, jellyfin]", "[JELLYFIN_CONFIG_DIR, /etc/jellyfin]", "[JELLYFIN_ARGS, $JELLYFIN_WEB_OPT $JELLYFIN_RESTART_OPT $JELLYFIN_FFMPEG_OPT $JELLYFIN_SERVICE_OPT $JELLYFIN_NOWEBAPP_OPT $JELLFIN_ADDITIONAL_OPTS]", "[JELLYFIN_RESTART_OPT, --restartpath=/usr/lib/jellyfin/restart.sh]", "[JELLYFIN_ADDITIONAL_OPTS, ]", "[JELLYFIN_WEB_DIR, /usr/share/jellyfin/web]", "[JELLYFIN_LOG_DIR, /var/log/jellyfin]"]
[2023-03-18 14:43:23.361 -04:00] [INF] Arguments: ["/usr/lib/jellyfin/bin/jellyfin.dll", "--webdir=/usr/share/jellyfin/web", "--restartpath=/usr/lib/jellyfin/restart.sh", "--ffmpeg=/usr/lib/jellyfin-ffmpeg/ffmpeg"]
[2023-03-18 14:43:23.363 -04:00] [INF] Operating system: "Linux"
[2023-03-18 14:43:23.363 -04:00] [INF] Architecture: X64
[2023-03-18 14:43:23.366 -04:00] [INF] 64-Bit Process: True
[2023-03-18 14:43:23.366 -04:00] [INF] User Interactive: True
[2023-03-18 14:43:23.366 -04:00] [INF] Processor count: 4
[2023-03-18 14:43:23.366 -04:00] [INF] Program data path: "/mnt/dietpi_userdata/jellyfin"
[2023-03-18 14:43:23.366 -04:00] [INF] Web resources path: "/usr/share/jellyfin/web"
[2023-03-18 14:43:23.366 -04:00] [INF] Application directory: "/usr/lib/jellyfin/bin/"
[2023-03-18 14:43:23.898 -04:00] [INF] Setting cache path: "/mnt/dietpi_userdata/jellyfin/cache"
[2023-03-18 14:43:24.226 -04:00] [INF] Loading assemblies
[2023-03-18 14:43:24.268 -04:00] [INF] Loaded assembly "Jellyfin.Plugin.Fanart, Version=10.0.0.0, Culture=neutral, PublicKeyToken=null" from "/mnt/dietpi_userdata/jellyfin/plugins/Fanart_10.0.0.0/Jellyfin.Plugin.Fanart.dll"
[2023-03-18 14:43:24.277 -04:00] [INF] Loaded assembly "ConfusedPolarBear.Plugin.IntroSkipper, Version=0.1.7.0, Culture=neutral, PublicKeyToken=null" from "/mnt/dietpi_userdata/jellyfin/plugins/Intro Skipper_0.1.7.0/ConfusedPolarBear.Plugin.IntroSkipper.dll"
[2023-03-18 14:43:24.286 -04:00] [INF] Loaded assembly "Nick.Plugin.Jellyscrub, Version=1.1.0.0, Culture=neutral, PublicKeyToken=null" from "/mnt/dietpi_userdata/jellyfin/plugins/Jellyscrub_1.1.0.0/Nick.Plugin.Jellyscrub.dll"
[2023-03-18 14:43:24.292 -04:00] [INF] Loaded assembly "Jellyfin.Plugin.OpenSubtitles, Version=18.0.0.0, Culture=neutral, PublicKeyToken=null" from "/mnt/dietpi_userdata/jellyfin/plugins/Open Subtitles_18.0.0.0/Jellyfin.Plugin.OpenSubtitles.dll"
[2023-03-18 14:43:24.304 -04:00] [INF] Loaded assembly "Jellyfin.Plugin.Tvdb, Version=9.0.0.0, Culture=neutral, PublicKeyToken=null" from "/mnt/dietpi_userdata/jellyfin/plugins/TheTVDB_9.0.0.0/Jellyfin.Plugin.Tvdb.dll"
[2023-03-18 14:43:24.310 -04:00] [INF] Loaded assembly "TvDbSharper, Version=3.2.2.0, Culture=neutral, PublicKeyToken=null" from "/mnt/dietpi_userdata/jellyfin/plugins/TheTVDB_9.0.0.0/TvDbSharper.dll"
[2023-03-18 14:43:24.324 -04:00] [INF] Loaded assembly "Trakt, Version=23.0.0.0, Culture=neutral, PublicKeyToken=null" from "/mnt/dietpi_userdata/jellyfin/plugins/Trakt_23.0.0.0/Trakt.dll"
[2023-03-18 14:43:24.697 -04:00] [INF] Defined LAN addresses : "[10.0.0.0/8,172.16.0.0/12,192.168.0.0/16]"
[2023-03-18 14:43:24.698 -04:00] [INF] Defined LAN exclusions : "[]"
[2023-03-18 14:43:24.700 -04:00] [INF] Using LAN addresses: "[10.0.0.0/8,172.16.0.0/12,192.168.0.0/16]"
[2023-03-18 14:43:24.716 -04:00] [INF] Using bind addresses: "[]"
[2023-03-18 14:43:24.717 -04:00] [INF] Using bind exclusions: "[]"
Oh wait! Nevermind, for some reason the info appears in the log after a few minutes :)
It says it was already injected since I did it myself but after removing it, you are right, it's a permission error.. which is weird since it's the same user that is running Jellyfin when looking at top
but I'll dig deeper, now I know what the issue thanks :)
In the Readme, it says: "If your Jellyfin's web path is set, the plugin should automatically inject the companion client script" but I'm not using a Docker image and you didn't specify the name of the Jellyfin Web path variable. I would set up the variable instead so Jellyscrub could automatically add the companion script on every update.
In your code, I found
var indexFile = Path.Combine(applicationPaths.WebPath, "index.html");
but I have no idea what is the value ofWebPath
Do you think you could add the name it's looking for?
Tried setting
JELLYFIN_WEB_DIR="/usr/share/jellyfin/web"
from the official documentation and I see index.html doesn't contain the Jellyscrub script when restarting Jellyfin.