refactor: add mkvpropedit as alternative for in-place modification

This commit is contained in:
2025-05-12 10:43:23 +02:00
parent 7a49849ee9
commit 4b6576ec53
3 changed files with 82 additions and 25 deletions

View File

@ -1,4 +1,4 @@
FROM debian:bullseye-slim AS builder
FROM debian:bookworm-slim AS builder
# Install ffmpeg and mkvtoolnix
# but only keep the binaries and libs for ffprobe and mkvmerge
@ -7,11 +7,13 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
&& mkdir -p /artifacts/bin /artifacts/lib \
&& cp $(which ffprobe) /artifacts/bin/ \
&& cp $(which mkvmerge) /artifacts/bin/ \
&& cp $(which mkvpropedit) /artifacts/bin/ \
&& ldd $(which ffprobe) | awk '{print $3}' | xargs -I '{}' cp -v '{}' /artifacts/lib/ || true \
&& ldd $(which mkvmerge) | awk '{print $3}' | xargs -I '{}' cp -v '{}' /artifacts/lib/ || true
&& ldd $(which mkvmerge) | awk '{print $3}' | xargs -I '{}' cp -v '{}' /artifacts/lib/ || true \
&& ldd $(which mkvpropedit) | awk '{print $3}' | xargs -I '{}' cp -v '{}' /artifacts/lib/ || true
# Must be the same base as builder image for shared libraries compatibility
FROM python:3.13.3-slim-bullseye
FROM python:3.13.3-slim-bookworm
COPY --from=builder /artifacts/bin/* /usr/local/bin/
COPY --from=builder /artifacts/lib/* /usr/local/lib/