File tree Expand file tree Collapse file tree 3 files changed +10
-4
lines changed Expand file tree Collapse file tree 3 files changed +10
-4
lines changed Original file line number Diff line number Diff line change @@ -309,6 +309,7 @@ def build_docker(
309309 DOTNET_ARCH = configurations ["docker" ]["archmaps" ][_build_arch ]["DOTNET_ARCH" ]
310310 QEMU_ARCH = configurations ["docker" ]["archmaps" ][_build_arch ]["QEMU_ARCH" ]
311311 IMAGE_ARCH = configurations ["docker" ]["archmaps" ][_build_arch ]["IMAGE_ARCH" ]
312+ TARGET_ARCH = configurations ["docker" ]["archmaps" ][_build_arch ]["TARGET_ARCH" ]
312313
313314 # Use a unique docker image name for consistency
314315 if is_stable :
@@ -327,10 +328,10 @@ def build_docker(
327328
328329 # Build the dockerfile
329330 log (
330- f">>> { docker_build_cmd } --build-arg PACKAGE_ARCH={ PACKAGE_ARCH } --build-arg DOTNET_ARCH={ DOTNET_ARCH } --build-arg QEMU_ARCH={ QEMU_ARCH } --build-arg IMAGE_ARCH={ IMAGE_ARCH } --build-arg JELLYFIN_VERSION={ jellyfin_version } --file { repo_root_dir } /{ dockerfile } --tag { imagename } { repo_root_dir } "
331+ f">>> { docker_build_cmd } --build-arg PACKAGE_ARCH={ PACKAGE_ARCH } --build-arg DOTNET_ARCH={ DOTNET_ARCH } --build-arg QEMU_ARCH={ QEMU_ARCH } --build-arg IMAGE_ARCH={ IMAGE_ARCH } --build-arg TARGET_ARCH= { TARGET_ARCH } --build-arg JELLYFIN_VERSION={ jellyfin_version } --file { repo_root_dir } /{ dockerfile } --tag { imagename } { repo_root_dir } "
331332 )
332333 ret = os .system (
333- f"{ docker_build_cmd } --build-arg PACKAGE_ARCH={ PACKAGE_ARCH } --build-arg DOTNET_ARCH={ DOTNET_ARCH } --build-arg QEMU_ARCH={ QEMU_ARCH } --build-arg IMAGE_ARCH={ IMAGE_ARCH } --build-arg JELLYFIN_VERSION={ jellyfin_version } --file { repo_root_dir } /{ dockerfile } --tag { imagename } { repo_root_dir } "
334+ f"{ docker_build_cmd } --build-arg PACKAGE_ARCH={ PACKAGE_ARCH } --build-arg DOTNET_ARCH={ DOTNET_ARCH } --build-arg QEMU_ARCH={ QEMU_ARCH } --build-arg IMAGE_ARCH={ IMAGE_ARCH } --build-arg TARGET_ARCH= { TARGET_ARCH } --build-arg JELLYFIN_VERSION={ jellyfin_version } --file { repo_root_dir } /{ dockerfile } --tag { imagename } { repo_root_dir } "
334335 )
335336 if ret > 0 :
336337 exit (1 )
Original file line number Diff line number Diff line change @@ -100,16 +100,19 @@ docker:
100100 IMAGE_ARCH : amd64
101101 PACKAGE_ARCH : amd64
102102 QEMU_ARCH : x86_64
103+ TARGET_ARCH : amd64
103104 arm64 :
104105 DOTNET_ARCH : arm64
105106 IMAGE_ARCH : arm64v8
106107 PACKAGE_ARCH : arm64
107108 QEMU_ARCH : aarch64
109+ TARGET_ARCH : arm64/v8
108110 armhf :
109111 DOTNET_ARCH : arm
110112 IMAGE_ARCH : arm32v7
111113 PACKAGE_ARCH : armhf
112114 QEMU_ARCH : arm
115+ TARGET_ARCH : arm/v7
113116 dockerfile : docker/Dockerfile
114117 imagename : jellyfin/jellyfin
115118
Original file line number Diff line number Diff line change @@ -25,8 +25,10 @@ ARG PACKAGE_ARCH
2525ARG DOTNET_ARCH
2626# QEMU architecture (x86_64, aarch64, arm), set by build script
2727ARG QEMU_ARCH
28- # Base Image archiecture (amd64, arm64v8, arm32v7), set by build script
28+ # Base Image architecture (amd64, arm64v8, arm32v7), set by build script
2929ARG IMAGE_ARCH
30+ # Target platform architecture (amd64, arm64/v8, arm/v7), set by build script
31+ ARG TARGET_ARCH
3032
3133# Jellyfin version
3234ARG JELLYFIN_VERSION
@@ -86,7 +88,7 @@ RUN dotnet publish Jellyfin.Server --configuration Release \
8688# Build the final combined image
8789#
8890FROM multiarch/qemu-user-static:x86_64-${QEMU_ARCH} as qemu
89- FROM ${IMAGE_ARCH}/debian:${OS_VERSION}-slim as combined
91+ FROM --platform=linux/${TARGET_ARCH} ${IMAGE_ARCH}/debian:${OS_VERSION}-slim as combined
9092
9193ARG OS_VERSION
9294ARG FFMPEG_PACKAGE
You can’t perform that action at this time.
0 commit comments