jellyfin / jellyfin-packaging

Jellyfin Packaging and Build Workflows
GNU General Public License v3.0
16 stars 16 forks source link

Can't build local Docker image #12

Closed vessd closed 5 months ago

vessd commented 5 months ago
[jellyfin-packaging]$ git submodule status 
+e36738c8f194e7e045ce11285209f4e568df2848 jellyfin-server (v10.8.0-alpha5-3257-ge36738c8f) (https://github.com/vessd/jellyfin/tree/amd-transcoding)
 ffc1ffb7c869beb409b8c52a5fc3d3b5edec6f1e jellyfin-server-windows (10.8.10-18-gffc1ffb)
+e0ad798610c6307801802bc16e2b786fc954431c jellyfin-web (v10.8.0-alpha5-5737-ge0ad79861)
[jellyfin-packaging]$ ./build.py auto docker amd64 --local
...
Step 48/63 : COPY --from=qemu /usr/bin/* /usr/bin
COPY failed: no source files were specified
full log ``` [jellyfin-packaging]$ ./build.py auto docker amd64 --local NOTE: Autocorrecting 'master' version to 2024033023 > Building Docker images... NOTE: Building only for arch amd64 >> Building Docker image for amd64... >>> docker run --rm --privileged multiarch/qemu-user-static:register --reset Setting /usr/bin/qemu-alpha-static as binfmt interpreter for alpha Setting /usr/bin/qemu-arm-static as binfmt interpreter for arm Setting /usr/bin/qemu-armeb-static as binfmt interpreter for armeb Setting /usr/bin/qemu-sparc-static as binfmt interpreter for sparc Setting /usr/bin/qemu-sparc32plus-static as binfmt interpreter for sparc32plus Setting /usr/bin/qemu-sparc64-static as binfmt interpreter for sparc64 Setting /usr/bin/qemu-ppc-static as binfmt interpreter for ppc Setting /usr/bin/qemu-ppc64-static as binfmt interpreter for ppc64 Setting /usr/bin/qemu-ppc64le-static as binfmt interpreter for ppc64le Setting /usr/bin/qemu-m68k-static as binfmt interpreter for m68k Setting /usr/bin/qemu-mips-static as binfmt interpreter for mips Setting /usr/bin/qemu-mipsel-static as binfmt interpreter for mipsel Setting /usr/bin/qemu-mipsn32-static as binfmt interpreter for mipsn32 Setting /usr/bin/qemu-mipsn32el-static as binfmt interpreter for mipsn32el Setting /usr/bin/qemu-mips64-static as binfmt interpreter for mips64 Setting /usr/bin/qemu-mips64el-static as binfmt interpreter for mips64el Setting /usr/bin/qemu-sh4-static as binfmt interpreter for sh4 Setting /usr/bin/qemu-sh4eb-static as binfmt interpreter for sh4eb Setting /usr/bin/qemu-s390x-static as binfmt interpreter for s390x Setting /usr/bin/qemu-aarch64-static as binfmt interpreter for aarch64 Setting /usr/bin/qemu-aarch64_be-static as binfmt interpreter for aarch64_be Setting /usr/bin/qemu-hppa-static as binfmt interpreter for hppa Setting /usr/bin/qemu-riscv32-static as binfmt interpreter for riscv32 Setting /usr/bin/qemu-riscv64-static as binfmt interpreter for riscv64 Setting /usr/bin/qemu-xtensa-static as binfmt interpreter for xtensa Setting /usr/bin/qemu-xtensaeb-static as binfmt interpreter for xtensaeb Setting /usr/bin/qemu-microblaze-static as binfmt interpreter for microblaze Setting /usr/bin/qemu-microblazeel-static as binfmt interpreter for microblazeel Setting /usr/bin/qemu-or1k-static as binfmt interpreter for or1k Setting /usr/bin/qemu-hexagon-static as binfmt interpreter for hexagon >>> docker build --no-cache --build-arg PACKAGE_ARCH=amd64 --build-arg DOTNET_ARCH=x64 --build-arg QEMU_ARCH=x86_64 --build-arg IMAGE_ARCH=amd64 --build-arg JELLYFIN_VERSION=2024033023 --file /home/sergey/projects/jellyfin-packaging/docker/Dockerfile --tag jellyfin/jellyfin:2024033023-amd64 /home/sergey/projects/jellyfin-packaging DEPRECATED: The legacy builder is deprecated and will be removed in a future release. Install the buildx component to build images with BuildKit: https://docs.docker.com/go/buildx/ Sending build context to Docker daemon 248MB Step 1/63 : ARG DOTNET_VERSION=8.0 Step 2/63 : ARG NODEJS_VERSION=20 Step 3/63 : ARG OS_VERSION=bookworm Step 4/63 : ARG FFMPEG_PACKAGE=jellyfin-ffmpeg6 Step 5/63 : ARG GMMLIB_VERSION=22.3.17 Step 6/63 : ARG IGC_VERSION=1.0.16238.4 Step 7/63 : ARG NEO_VERSION=24.09.28717.12 Step 8/63 : ARG LEVEL_ZERO_VERSION=1.3.28717.12 Step 9/63 : ARG MALI_PKG_VER=1.9-1_arm64 Step 10/63 : ARG MALI_PKG_TAG=v1.9-1-b5d7972 Step 11/63 : ARG MALI_PKG_CFG=valhall-g610-g13p0-gbm Step 12/63 : ARG PACKAGE_ARCH Step 13/63 : ARG DOTNET_ARCH Step 14/63 : ARG QEMU_ARCH Step 15/63 : ARG IMAGE_ARCH Step 16/63 : ARG JELLYFIN_VERSION Step 17/63 : FROM node:${NODEJS_VERSION}-alpine as web ---> 09c27ad02af8 Step 18/63 : ARG SOURCE_DIR=/src ---> Running in be8b393496f1 ---> Removed intermediate container be8b393496f1 ---> 1c1f32286b4f Step 19/63 : ARG ARTIFACT_DIR=/web ---> Running in 210ed6496072 ---> Removed intermediate container 210ed6496072 ---> 74320190ec6d Step 20/63 : ARG JELLYFIN_VERSION ---> Running in de6eadf0ae4f ---> Removed intermediate container de6eadf0ae4f ---> fff0201a4a1e Step 21/63 : ENV JELLYFIN_VERSION=${JELLYFIN_VERSION} ---> Running in 9134da22365d ---> Removed intermediate container 9134da22365d ---> 87d24699f48e Step 22/63 : RUN apk add autoconf g++ make libpng-dev gifsicle alpine-sdk automake libtool gcc musl-dev nasm python3 ---> Running in 06b9cd86ab48 fetch https://dl-cdn.alpinelinux.org/alpine/v3.19/main/x86_64/APKINDEX.tar.gz fetch https://dl-cdn.alpinelinux.org/alpine/v3.19/community/x86_64/APKINDEX.tar.gz (1/77) Installing libattr (2.5.1-r5) (2/77) Installing attr (2.5.1-r5) (3/77) Installing libcap2 (2.69-r1) (4/77) Installing libcap-getcap (2.69-r1) (5/77) Installing fakeroot (1.32.1-r0) (6/77) Installing lzip (1.23-r1) (7/77) Installing openssl (3.1.4-r5) (8/77) Installing patch (2.7.6-r10) (9/77) Installing pkgconf (2.1.0-r0) (10/77) Installing libacl (2.3.1-r4) (11/77) Installing tar (1.35-r2) (12/77) Installing ca-certificates (20240226-r0) (13/77) Installing brotli-libs (1.1.0-r1) (14/77) Installing c-ares (1.27.0-r0) (15/77) Installing libunistring (1.1-r2) (16/77) Installing libidn2 (2.3.4-r4) (17/77) Installing nghttp2-libs (1.58.0-r0) (18/77) Installing libcurl (8.5.0-r0) (19/77) Installing curl (8.5.0-r0) (20/77) Installing abuild (3.12.0-r0) Executing abuild-3.12.0-r0.pre-install (21/77) Installing jansson (2.14-r4) (22/77) Installing zstd-libs (1.5.5-r8) (23/77) Installing binutils (2.41-r0) (24/77) Installing libmagic (5.45-r1) (25/77) Installing file (5.45-r1) (26/77) Installing libgomp (13.2.1_git20231014-r0) (27/77) Installing libatomic (13.2.1_git20231014-r0) (28/77) Installing gmp (6.3.0-r0) (29/77) Installing isl26 (0.26-r1) (30/77) Installing mpfr4 (4.2.1-r0) (31/77) Installing mpc1 (1.3.1-r1) (32/77) Installing gcc (13.2.1_git20231014-r0) (33/77) Installing libstdc++-dev (13.2.1_git20231014-r0) (34/77) Installing musl-dev (1.2.4_git20230717-r4) (35/77) Installing libc-dev (0.7.2-r5) (36/77) Installing g++ (13.2.1_git20231014-r0) (37/77) Installing make (4.4.1-r2) (38/77) Installing fortify-headers (1.1-r3) (39/77) Installing build-base (0.5-r3) (40/77) Installing libexpat (2.6.2-r0) (41/77) Installing pcre2 (10.42-r2) (42/77) Installing git (2.43.0-r0) (43/77) Installing alpine-sdk (1.0-r1) (44/77) Installing m4 (1.4.19-r3) (45/77) Installing libbz2 (1.0.8-r6) (46/77) Installing perl (5.38.2-r0) (47/77) Installing perl-error (0.17029-r2) (48/77) Installing perl-git (2.43.0-r0) (49/77) Installing git-perl (2.43.0-r0) (50/77) Installing autoconf (2.71-r2) (51/77) Installing automake (1.16.5-r2) (52/77) Installing libxau (1.0.11-r3) (53/77) Installing libmd (1.1.0-r0) (54/77) Installing libbsd (0.11.7-r3) (55/77) Installing libxdmcp (1.1.4-r3) (56/77) Installing libxcb (1.16-r0) (57/77) Installing libx11 (1.8.7-r0) (58/77) Installing gifsicle (1.94-r1) (59/77) Installing libpng (1.6.40-r0) (60/77) Installing zlib-dev (1.3.1-r0) (61/77) Installing libpng-dev (1.6.40-r0) (62/77) Installing libltdl (2.4.7-r3) (63/77) Installing libtool (2.4.7-r3) (64/77) Installing nasm (2.16.01-r2) (65/77) Installing libffi (3.4.4-r3) (66/77) Installing gdbm (1.23-r1) (67/77) Installing xz-libs (5.4.5-r0) (68/77) Installing mpdecimal (2.5.1-r2) (69/77) Installing ncurses-terminfo-base (6.4_p20231125-r0) (70/77) Installing libncursesw (6.4_p20231125-r0) (71/77) Installing libpanelw (6.4_p20231125-r0) (72/77) Installing readline (8.2.1-r2) (73/77) Installing sqlite-libs (3.44.2-r0) (74/77) Installing python3 (3.11.8-r0) (75/77) Installing python3-pycache-pyc0 (3.11.8-r0) (76/77) Installing pyc (3.11.8-r0) (77/77) Installing python3-pyc (3.11.8-r0) Executing busybox-1.36.1-r15.trigger Executing ca-certificates-20240226-r0.trigger OK: 332 MiB in 94 packages ---> Removed intermediate container 06b9cd86ab48 ---> 803cfca228e4 Step 23/63 : WORKDIR ${SOURCE_DIR} ---> Running in cdfb8d558518 ---> Removed intermediate container cdfb8d558518 ---> 7cd365b46fbb Step 24/63 : COPY jellyfin-web . ---> d373f8a2818f Step 25/63 : RUN npm ci --no-audit --unsafe-perm && npm run build:production && mv dist ${ARTIFACT_DIR} ---> Running in 003163be2e63 npm WARN deprecated flatten@1.0.3: flatten is deprecated in favor of utility frameworks such as lodash. npm WARN deprecated @types/vfile-message@2.0.0: This is a stub types definition. vfile-message provides its own type definitions, so you do not need this installed. npm WARN deprecated browserslist@1.7.7: Browserslist 2 could fail on reading Browserslist >3.0 config used in other tools. npm WARN deprecated urix@0.1.0: Please see https://github.com/lydell/urix#deprecated npm WARN deprecated source-map-resolve@0.5.3: See https://github.com/lydell/source-map-resolve#deprecated npm WARN deprecated source-map-url@0.4.1: See https://github.com/lydell/source-map-url#deprecated npm WARN deprecated @stylelint/postcss-css-in-js@0.37.3: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info. npm WARN deprecated @stylelint/postcss-markdown@0.36.2: Use the original unforked package instead: postcss-markdown npm WARN deprecated @types/localforage@0.0.34: This is a stub types definition for localforage (https://github.com/localForage/localForage). localforage provides its own type definitions, so you don't need @types/localforage installed! npm WARN deprecated resolve-url@0.2.1: https://github.com/lydell/resolve-url#deprecated added 1763 packages in 1m > jellyfin-web@10.9.0 build:production > cross-env NODE_ENV="production" webpack --config webpack.prod.js [BABEL] Note: The code generator has deoptimised the styling of /src/node_modules/pdfjs-dist/build/pdf.js as it exceeds the max of 500KB. assets by info 39 MiB [immutable] 2111 assets assets by path *.css 1.71 MiB 158 assets assets by path assets/ 744 KiB 48 assets assets by path libraries/ 8.9 MiB assets by status 8.62 MiB [big] 5 assets + 4 assets assets by path themes/ 125 KiB 9 assets assets by path *.ts 20 KiB asset apiclient.d.ts 19.4 KiB [emitted] [from: apiclient.d.ts] [copied] asset global.d.ts 541 bytes [emitted] [from: global.d.ts] [copied] asset index.d.ts 67 bytes [emitted] [from: index.d.ts] [copied] assets by path *.tsx 2.5 KiB asset RootApp.tsx 1.39 KiB [emitted] [from: RootApp.tsx] [copied] asset RootAppRouter.tsx 1.11 KiB [emitted] [from: RootAppRouter.tsx] [copied] + 38 assets Entrypoint main.jellyfin [big] 2.21 MiB = 26 assets Entrypoint serviceworker 219 KiB = runtime.bundle.js 45.7 KiB node_modules.core-js.bundle.js 173 KiB serviceworker.js 768 bytes orphan modules 15.5 MiB (javascript) 24.5 MiB (asset) 83.3 KiB (runtime) [orphan] 14862 modules runtime modules 55.8 KiB 15 modules built modules 24.6 MiB (javascript) 1.27 MiB (css/mini-extract) 46.9 KiB (asset) [built] modules by path ../node_modules/ 14.9 MiB (javascript) 158 KiB (css/mini-extract) javascript modules 14.9 MiB 1952 modules json modules 30 KiB 4 modules css modules 158 KiB 3 modules modules by path ./ 9.63 MiB (javascript) 1.12 MiB (css/mini-extract) 46.9 KiB (asset) javascript modules 3.93 MiB 440 modules json modules 5.7 MiB 92 modules css modules 1.12 MiB 82 modules asset modules 126 bytes (javascript) 46.9 KiB (asset) 3 modules + 6 modules WARNING in asset size limit: The following asset(s) exceed the recommended size limit (244 KiB). This can impact web performance. Assets: 698bd8550d863c20a3e1.ttf (339 KiB) main.jellyfin.bundle.js (383 KiB) 43091.css (967 KiB) node_modules.@jellyfin.sdk.bundle.js (550 KiB) node_modules.@mui.material.bundle.js (287 KiB) libraries/subtitles-octopus-worker.js (352 KiB) libraries/subtitles-octopus-worker.wasm (2.18 MiB) libraries/pdf.worker.js (1 MiB) libraries/subtitles-octopus-worker-legacy.js (4.25 MiB) libraries/wasm-gen/libarchive.wasm (875 KiB) node_modules.@mui.x-data-grid.d16d629f2abd61a21fbe.chunk.js (285 KiB) node_modules.hls.js.970a5cb5618e7282c138.chunk.js (403 KiB) node_modules.pdfjs-dist.5bb4bdfda8b7a44bea07.chunk.js (434 KiB) WARNING in entrypoint size limit: The following entrypoint(s) combined asset size exceeds the recommended limit (244 KiB). This can impact web performance. Entrypoints: main.jellyfin (2.21 MiB) runtime.bundle.js node_modules.@babel.runtime.bundle.js node_modules.@jellyfin.sdk.bundle.js node_modules.@tanstack.query-core.bundle.js node_modules.@tanstack.react-query.bundle.js node_modules.@mui.material.bundle.js node_modules.@mui.system.bundle.js node_modules.@mui.utils.bundle.js node_modules.lodash-es.bundle.js node_modules.date-fns.esm.bundle.js node_modules.@emotion.react.bundle.js node_modules.core-js.bundle.js node_modules.axios.bundle.js node_modules.react-dom.bundle.js node_modules.jquery.bundle.js node_modules.webcomponents.js.bundle.js node_modules.resize-observer-polyfill.bundle.js node_modules.regenerator-runtime.bundle.js node_modules.jellyfin-apiclient.bundle.js node_modules.intersection-observer.bundle.js node_modules.history.bundle.js node_modules.dompurify.bundle.js 14926.css 14926.bundle.js main.jellyfin.css main.jellyfin.bundle.js webpack 5.91.0 compiled with 2 warnings in 59665 ms ---> Removed intermediate container 003163be2e63 ---> 5e109e88fbe1 Step 26/63 : FROM mcr.microsoft.com/dotnet/sdk:${DOTNET_VERSION}-${OS_VERSION}-slim as server ---> 7dd073a82957 Step 27/63 : ARG DOTNET_ARCH ---> Running in f4f1e5cfb688 ---> Removed intermediate container f4f1e5cfb688 ---> 7a6dbe691daa Step 28/63 : ARG SOURCE_DIR=/src ---> Running in ff0cee7a0694 ---> Removed intermediate container ff0cee7a0694 ---> 367ccbd7e9ed Step 29/63 : ARG ARTIFACT_DIR=/server ---> Running in 89c9a58efb3c ---> Removed intermediate container 89c9a58efb3c ---> e0935adb2a23 Step 30/63 : WORKDIR ${SOURCE_DIR} ---> Running in d71937242b96 ---> Removed intermediate container d71937242b96 ---> 334885c78ca8 Step 31/63 : COPY jellyfin-server . ---> f333ec4e0428 Step 32/63 : ENV DOTNET_CLI_TELEMETRY_OPTOUT=1 ---> Running in f6ec7be2355d ---> Removed intermediate container f6ec7be2355d ---> dfd7a213f22a Step 33/63 : RUN dotnet publish Jellyfin.Server --configuration Release --output="${ARTIFACT_DIR}" --self-contained --runtime linux-${DOTNET_ARCH} -p:DebugSymbols=false -p:DebugType=none ---> Running in c0469b285227 MSBuild version 17.9.6+a4ecab324 for .NET Determining projects to restore... Restored /src/src/Jellyfin.MediaEncoding.Keyframes/Jellyfin.MediaEncoding.Keyframes.csproj (in 24.75 sec). Restored /src/src/Jellyfin.Extensions/Jellyfin.Extensions.csproj (in 24.75 sec). Restored /src/Jellyfin.Data/Jellyfin.Data.csproj (in 24.75 sec). Restored /src/MediaBrowser.Common/MediaBrowser.Common.csproj (in 25.21 sec). Restored /src/Emby.Naming/Emby.Naming.csproj (in 25.21 sec). Restored /src/MediaBrowser.XbmcMetadata/MediaBrowser.XbmcMetadata.csproj (in 360 ms). Restored /src/MediaBrowser.Controller/MediaBrowser.Controller.csproj (in 25.21 sec). Restored /src/src/Jellyfin.Drawing/Jellyfin.Drawing.csproj (in 25.21 sec). Restored /src/Emby.Photos/Emby.Photos.csproj (in 25.21 sec). Restored /src/src/Jellyfin.LiveTv/Jellyfin.LiveTv.csproj (in 25.21 sec). Restored /src/MediaBrowser.LocalMetadata/MediaBrowser.LocalMetadata.csproj (in 25.21 sec). Restored /src/src/Jellyfin.MediaEncoding.Hls/Jellyfin.MediaEncoding.Hls.csproj (in 364 ms). Restored /src/src/Jellyfin.Drawing.Skia/Jellyfin.Drawing.Skia.csproj (in 25.21 sec). Restored /src/MediaBrowser.Providers/MediaBrowser.Providers.csproj (in 25.21 sec). Restored /src/MediaBrowser.Model/MediaBrowser.Model.csproj (in 365 ms). Restored /src/src/Jellyfin.Networking/Jellyfin.Networking.csproj (in 6 ms). Restored /src/Jellyfin.Server.Implementations/Jellyfin.Server.Implementations.csproj (in 25.22 sec). Restored /src/MediaBrowser.MediaEncoding/MediaBrowser.MediaEncoding.csproj (in 2.4 sec). Restored /src/Jellyfin.Api/Jellyfin.Api.csproj (in 27.61 sec). Restored /src/Emby.Server.Implementations/Emby.Server.Implementations.csproj (in 27.61 sec). Restored /src/Jellyfin.Server/Jellyfin.Server.csproj (in 27.62 sec). Jellyfin.MediaEncoding.Keyframes -> /src/src/Jellyfin.MediaEncoding.Keyframes/bin/Release/net8.0/Jellyfin.MediaEncoding.Keyframes.dll Jellyfin.Data -> /src/Jellyfin.Data/bin/Release/net8.0/Jellyfin.Data.dll Jellyfin.Extensions -> /src/src/Jellyfin.Extensions/bin/Release/net8.0/Jellyfin.Extensions.dll MediaBrowser.Model -> /src/MediaBrowser.Model/bin/Release/net8.0/MediaBrowser.Model.dll MediaBrowser.Common -> /src/MediaBrowser.Common/bin/Release/net8.0/MediaBrowser.Common.dll Emby.Naming -> /src/Emby.Naming/bin/Release/net8.0/Emby.Naming.dll MediaBrowser.Controller -> /src/MediaBrowser.Controller/bin/Release/net8.0/MediaBrowser.Controller.dll Jellyfin.Drawing -> /src/src/Jellyfin.Drawing/bin/Release/net8.0/Jellyfin.Drawing.dll MediaBrowser.LocalMetadata -> /src/MediaBrowser.LocalMetadata/bin/Release/net8.0/MediaBrowser.LocalMetadata.dll MediaBrowser.XbmcMetadata -> /src/MediaBrowser.XbmcMetadata/bin/Release/net8.0/MediaBrowser.XbmcMetadata.dll Jellyfin.Networking -> /src/src/Jellyfin.Networking/bin/Release/net8.0/Jellyfin.Networking.dll Jellyfin.Drawing.Skia -> /src/src/Jellyfin.Drawing.Skia/bin/Release/net8.0/Jellyfin.Drawing.Skia.dll MediaBrowser.MediaEncoding -> /src/MediaBrowser.MediaEncoding/bin/Release/net8.0/MediaBrowser.MediaEncoding.dll Jellyfin.LiveTv -> /src/src/Jellyfin.LiveTv/bin/Release/net8.0/Jellyfin.LiveTv.dll Emby.Photos -> /src/Emby.Photos/bin/Release/net8.0/Emby.Photos.dll MediaBrowser.Providers -> /src/MediaBrowser.Providers/bin/Release/net8.0/MediaBrowser.Providers.dll Jellyfin.MediaEncoding.Hls -> /src/src/Jellyfin.MediaEncoding.Hls/bin/Release/net8.0/Jellyfin.MediaEncoding.Hls.dll Jellyfin.Server.Implementations -> /src/Jellyfin.Server.Implementations/bin/Release/net8.0/Jellyfin.Server.Implementations.dll Jellyfin.Api -> /src/Jellyfin.Api/bin/Release/net8.0/Jellyfin.Api.dll Emby.Server.Implementations -> /src/Emby.Server.Implementations/bin/Release/net8.0/Emby.Server.Implementations.dll Jellyfin.Server -> /src/Jellyfin.Server/bin/Release/net8.0/linux-x64/jellyfin.dll Jellyfin.Server -> /server/ ---> Removed intermediate container c0469b285227 ---> 28daf14ec0d1 Step 34/63 : FROM multiarch/qemu-user-static:x86_64-${QEMU_ARCH} as qemu ---> 6f1ad9baf3ab Step 35/63 : FROM ${IMAGE_ARCH}/debian:${OS_VERSION}-slim as combined ---> dd8416105e9e Step 36/63 : ARG OS_VERSION ---> Running in f48b11e00426 ---> Removed intermediate container f48b11e00426 ---> 28783b118f19 Step 37/63 : ARG FFMPEG_PACKAGE ---> Running in 8e178e143bdc ---> Removed intermediate container 8e178e143bdc ---> 195437d31114 Step 38/63 : ARG GMMLIB_VERSION ---> Running in 6d74b23194fa ---> Removed intermediate container 6d74b23194fa ---> 040ab89fbea6 Step 39/63 : ARG IGC_VERSION ---> Running in 27377e628372 ---> Removed intermediate container 27377e628372 ---> ed0cb5cd0b9a Step 40/63 : ARG NEO_VERSION ---> Running in f4ee80d80a77 ---> Removed intermediate container f4ee80d80a77 ---> 36156a7bf1db Step 41/63 : ARG LEVEL_ZERO_VERSION ---> Running in 653f811a2a1e ---> Removed intermediate container 653f811a2a1e ---> 77351252a2dd Step 42/63 : ARG MALI_PKG_VER ---> Running in bb6a4d4b9bba ---> Removed intermediate container bb6a4d4b9bba ---> deb5d538bf06 Step 43/63 : ARG MALI_PKG_TAG ---> Running in 26211f537dba ---> Removed intermediate container 26211f537dba ---> ee8efd97e6fc Step 44/63 : ARG MALI_PKG_CFG ---> Running in 5a439fa0becd ---> Removed intermediate container 5a439fa0becd ---> 9a0d91bbaf9a Step 45/63 : ARG PACKAGE_ARCH ---> Running in a15a7e640805 ---> Removed intermediate container a15a7e640805 ---> 0f2dcb36cfaa Step 46/63 : ARG DOTNET_ARCH ---> Running in 4f0e7a9b2501 ---> Removed intermediate container 4f0e7a9b2501 ---> 75d766d7ffdf Step 47/63 : ARG QEMU_ARCH ---> Running in d7de4c7d79d1 ---> Removed intermediate container d7de4c7d79d1 ---> ef48de77e76f Step 48/63 : COPY --from=qemu /usr/bin/* /usr/bin COPY failed: no source files were specified ```
joshuaboniface commented 5 months ago

What is the distro and architecture of the system you are building this on? The Packaging system is designed to be run from Debian or Ubuntu amd64. Nothing else is supported.

Basically, what's happening is that an earlier conditional depends on the command dpkg --print-architecture to determine what architecture the system you're building on is. This allows it to skip the step that's failing on amd64, which is needed or it fails as you see. So, if the system doesn't have that command, it has no way to determine this without some extensive modifications or exceptions for every possible system and way of determining this.

Perhaps there is a more distro-agnostic way to do this, but not that outputs the format we need (i.e. amd64) elsewhere.

vessd commented 5 months ago

I'm using Arch Linux x64, but I don't really understand how this relates to the problem of building a local Docker image. I looked at the code, dpkg --print-architecture is used only when building a deb package.

And this message does not seem to be an error when trying to use dpkg

Step 48/63 : COPY --from=qemu /usr/bin/* /usr/bin
COPY failed: no source files were specified
joshuaboniface commented 5 months ago

Right I was actually confused about the problem, as I was still thinking about how our old Docker infrastructure worked. Sorry there.

The error then, is with the multiarch/qemu-user-static docker image, as it's somehow missing any files. I know I ran into this while constructing the Docker image builder here but fixed it, but I'm not 100% sure how. I don't see this replicated in the official builds on Ubuntu 22.04 images though, so I'm not certain exactly what's going wrong there.

joshuaboniface commented 5 months ago

I'm also noticing something unusual about your output. The docker commands run by the script should be outputting in a different format than what your logs show. What version of the Docker engine are you running?

vessd commented 5 months ago
$ docker --version 
Docker version 26.0.0, build 2ae903e86c

I changed the command a little because this docker doesn't have progress option

-docker_build_cmd = "docker build --progress=plain --no-cache"
+docker_build_cmd = "docker build --no-cache"
$ docker build --progress=plain --no-cache
DEPRECATED: The legacy builder is deprecated and will be removed in a future release.
            Install the buildx component to build images with BuildKit:
            https://docs.docker.com/go/buildx/

unknown flag: --progress
See 'docker build --help'.
joshuaboniface commented 5 months ago

OK it seems clear then that Docker 26 has broken several things. I've noticed a couple other anomalies in your output including issues with the ordering, though the fact that they removed that log output is frustrating because it makes 1-to-1 comparisons with known working outputs (i.e. my own and our CI) much harder.

It looks like I have the update to the Docker engine pending, so I'll have to try with that to see what modifications need to be made here.

joshuaboniface commented 5 months ago

I think I know what's happening.

On the official Docker Debian packages of both Docker 25 and Docker 26, docker build is an alias to the new-style docker buildx build:

joshua@base git:master ~/Projects/Jellyfin/projects/server/jellyfin-packaging $ docker build --progress=plain --no-cache
ERROR: "docker buildx build" requires exactly 1 argument.
See 'docker buildx build --help'.

Usage:  docker buildx build [OPTIONS] PATH | URL | -

Start a build

Versus in your output, it's mentioning the deprecated old builder; I guess the Arch package for Docker does not include this alias.. The image requires the new builder for proper ordering, which seems to be the underlying issue causing the COPY step to fail as that is running far too late in the image build, and likely after Docker has disposed of the intermediate image, though I can't be 100% sure.

This should be trivial to fix: in build.py line 22, replace docker build with docker buildx build and see if that works. From a quick test on my side it does, so I'll push up the required change if it indeed fixes the issue for you here.

vessd commented 5 months ago

This seems to have fixed the problem, at least the build completed without errors. Thanks

-docker_build_cmd = "docker build --progress=plain --no-cache"
+docker_build_cmd = "docker buildx build --progress=plain --no-cache"
joshuaboniface commented 5 months ago

Great, glad to help. I've pushed the change so this should be OK going forward. And good to know now that it works on Arch!