Customize Jellyfin with Ansible! - Printable Version +- Jellyfin Forum (https://forum.jellyfin.org) +-- Forum: Support (https://forum.jellyfin.org/f-support) +--- Forum: Guides, Walkthroughs & Tutorials (https://forum.jellyfin.org/f-guides-walkthroughs-tutorials) +--- Thread: Customize Jellyfin with Ansible! (/t-customize-jellyfin-with-ansible) |
Customize Jellyfin with Ansible! - LeviSnoot - 2024-06-04 Greetings! I'm sure many of you are aware of BobHasNoSoul's excellent GitHub repository full of little tweaks like changing Jellyfin's page title to anything you'd like. If not, you can have a look at it here and thank Bob & contributors later! I personally have contributed to the project in the past when a new Jellyfin version has broken one of the mods etc. As 10.9 rolled around, we noticed a good amount of changes in the code which ended up breaking many of these mods. As we've worked on updating the repo for 10.9.x (some of which you can preview here), I decided to shoehorn in another improvement to the repo; Ansible. The major downside to doing these kinds of client modifications is that whenever there's an update to Jellyfin, they need to be applied again, manually. You can probably imagine how tedious this gets when you use a good number of mods, and this is where Ansible comes in. Using Ansible, we can remove this headache by automating the process. I wrote a document detailing how to acheive this which has now been merged into the repo (this document is fully compatible with 10.9.x). It is important as always to note that neither me nor BobHasNoSoul take any responsibility for the code you execute on your machines. Read and understand what you're doing before performing any changes to your environment. You can read the guide for modifying Jellyfin with the use of Ansible here: https://github.com/BobHasNoSoul/jellyfin-mods/blob/main/ansible.md RE: Customize Jellyfin with Ansible! - pcm - 2024-06-06 thanks for this! will definitely take a look at this! this should make managing multiple instances a breeze RE: Customize Jellyfin with Ansible! - TheDreadPirate - 2024-06-06 I've had Ansible on to-learn list for a while. Will add this to the doc. RE: Customize Jellyfin with Ansible! - chuanqi - 2024-06-19 Thank you! It's probably not that simple/possible to do this if you're running Jellyfin inside a Docker Container right? RE: Customize Jellyfin with Ansible! - TheDreadPirate - 2024-06-19 (2024-06-19, 01:38 PM)chuanqi Wrote: Thank you! It's probably not that simple/possible to do this if you're running Jellyfin inside a Docker Container right? I don't see can't also handle Docker. When you setup Jellyfin in Docker you should be mounting a host path for /config and Ansible would be modifying those. Having Ansible modify config files would not be different. Just in a different location. RE: Customize Jellyfin with Ansible! - LeviSnoot - 2024-06-25 (2024-06-19, 03:12 PM)TheDreadPirate Wrote:(2024-06-19, 01:38 PM)chuanqi Wrote: Thank you! It's probably not that simple/possible to do this if you're running Jellyfin inside a Docker Container right? Correct, using volume mounts should take care of any file related actions. As for managing the docker containers using Ansible, it is certainly doable, but not something I've delved into myself. You would need to install the docker modules to Ansible using the following command: Code: ansible-galaxy collection install community.docker Then your host machine needs to have the Docker SDK for Python installed. Documentation for all of this can be found here: https://docs.ansible.com/ansible/latest/collections/community/docker/docsite/scenario_guide.html If it were me, I would create a task workflow like this: Stop container > Pull latest jellyfin docker image > Start container > Stop container > Any steps to modify Jellyfin > Start container Hope that helps. RE: Customize Jellyfin with Ansible! - LeviSnoot - 2024-11-05 There's a pretty significant update which now makes the ansible solution even more portable across versions! I have implemented functionality that essentially greps the files with variable file names by their known strings, so now you shouldn't need to update the script unless one of the values in the javascript itself changes! I have a pending PR for this if you want to try it out right away, I expect it will be merged as soon as Bob has time to review it. |