.github/workflows | ||
debian | ||
docker | ||
jellyfin-server@407cf5d0bf | ||
jellyfin-web@06c3602bd0 | ||
portable | ||
.flake8 | ||
.gitignore | ||
.gitmodules | ||
build.py | ||
build.yaml | ||
checkout.py | ||
README.md | ||
requirements.txt |
Jellyfin
The Free Software Media System
Jellyfin is a Free Software Media System that puts you in control of managing and streaming your media. It is an alternative to the proprietary Emby and Plex, to provide media from a dedicated server to end-user devices via multiple apps. Jellyfin is descended from Emby's 3.5.2 release and ported to the .NET Core framework to enable full cross-platform support. There are no strings attached, no premium licenses or features, and no hidden agendas: just a team who want to build something better and work together to achieve it. We welcome anyone who is interested in joining us in our quest!
This repository contains packaging for Jellyfin 10.9.0 and above, for use by manual builders or the CI system with GitHub workflows.
Inside this repository are 7 major components:
-
Submodules for the
jellyfin
(asjellyfin-server
) andjellyfin-web
repositories. These are dynamic submodules; thecheckout.py
script will check them out to the requiredHEAD
on each build, and thus their actual committed value is irrelevant. Nonetheless, they should be bumped occasionally just to avoid excessive checkout times later. -
Debian/Ubuntu packaging configurations (under
debian
). These will build the 3 Jellyfin packages (jellyfin
metapackage,jellyfin-server
core server, andjellyfin-web
web client) from a single Dockerfile and helper script (build.sh
) underdebian/docker/
. Future packages (e.g. Vue) may be added here as well if and when they are promoted to a production build alongside the others, following one consistent versioning scheme. -
Fedora/CentOS packaging configurations (under
fedora
). These will build the same packages as Debian. This is still a TODO. -
Docker image builder (under
docker
). Like the above two as well, only building the combined Docker images with a single Dockerfile as well as preparing the various manifests needed to push these to the container repos. -
Portable image builder (under
portable
), which covers all the "archive" builds (.NET portable, Linux, Windows, and MacOS) again from a single Dockerfile. -
Script infrastructure to handle coordinating builds (
build.py
). This script takes basic arguments and, using its internal logic, fires the correct Dockerized builds for the given build type. -
The GitHub Actions CI to build all the above for every supported version and architecture.
Design Decisions
General
-
Unified packaging: all packaging is in this repository (vs. within the
jellyfin-server
andjellyfin-web
repositories)This helps ensure two things:
- There is a single source of truth for packaging. Previously, there were at least 3 sources of truth, and this became very confusing to update.
- Packaging can be run and managed independently of actual code, simplifying the release and build process.
-
GitHub Actions for CI: all builds use the GitHub Actions system instead of Azure DevOps
This helps ensure that CI is visible in a "single pane of glass" (GitHub) and is easier to manage long-term.
-
Python script-based builds: Building actually happens via the
build.py
scriptThis helps reduce the complexity of the builds by ensuring that the logic to actually generate specific builds is handled in one place in a consistent, well-known language, instead of the CI definitions.
-
Git Submodules to handle code (vs. cross-repo builds)
This ensures that the code checked out is consistent to both repositories, and allows for the unified builds described below without extra steps to combine.
-
Remote manual-only triggers: CI workers are triggered by a remote bot
This reduces the complexity of triggering builds; while it can be done manually in this repo, using an external bot allows for more release wrapper actions to occur before triggering builds.
Debian/Ubuntu Packages
-
Unified package build: this entire repo is the "source" and the source package is named "jellyfin".
This was chosen to simplify the source package system and simplify building. Now, there is only a single "jellyfin" source package rather than 2. There may be more in the future as other repos might be included (e.g. "jellyfin-ffmpeg", "jellyfin-vue", etc.)
-
Dockerized build (
debian/docker/
): the build is run inside a Docker container that matches the target OS releaseThis was chosen to ensure a clean slate for every build, as well as enable release-specific builds due to the complexities of our shared dependencies (e.g.
libssl
). -
Per-release/version builds: package versions contain the specific OS version (e.g.
-deb11
,-ubu2204
)This enables support for different builds and packages for each OS release, simplifying shared dependency handling as mentioned above.
-
Ubuntu LTS-only support: non-LTS Ubuntu versions have been dropped
This simplifies our builds as we do not need to then track many 9-month-only releases of Ubuntu, and also reduces the build burden. Users of non-LTS Ubuntu releases can use either the closest Ubuntu LTS version or use Docker containers instead.
Fedora/CentOS Packages
TODO - these have not yet been implemented.
Docker
-
Single unified Docker build: the entirety of our Docker images are built as one container from one Dockerfile.
This was chosen to keep our Docker builds as simple as possible without requiring 2 intervening images (as was the case with our previous CI).
-
Push to both DockerHub and GHCR (GitHub Packages)
This ensures flexibility for container users to fetch the containers from whatever repository they choose.
-
Seamless rebuilds: The root images are appended with the build date to keep them unique
This ensures we can trigger rebuilds of the Docker containers arbitrarily, in response to things like base OS updates or packaging changes (e.g. a new version of the Intel compute engine for instance).
-
Based on Debian 12 ("Bookworm"): the latest base Debian release
While possibly not as "up-to-date" as Ubuntu, this release is quite current and should cover all major compatibility issues we had with the old images based on Debian 11.
Portable Builds (Portable .NET, Linux, MacOS, Windows)
-
Single unified build: the entirety of the output package is built in one container from one Dockerfile
This was chosen to keep the portable builds as simple as possible without requiring complex archive combining (as was the case with our previous CI).
-
Multiple archive type support (
.tar.gz
vs..zip
)The output archive type (
.tar.gz
or.zip
) is chosen based on the build target, with Portable providing both for maximum compatibility, Windows providing.zip
, and Linux and MacOS providing.tar.gz
. This can be changed later, for example to add more formats (e.g..tar.xz
) or change what produces what, without major complications. -
Full architecture support
The portable builds support all major architectures now, specifically adding
arm64
Windows builds (I'm certain that someone out there uses it), and making it quite trivial to add new architectures in the future if needed.