Migrate distroless rTorrent runtime to openSUSE Tumbleweed
Build and Push Docker Image / build (push) Successful in 1m23s

This commit is contained in:
Ketan Patel committed 2026-11-01 21:45:11 -05:00
1 parent 18c861f52c
commit 5295c67f77
4 files changed
+84 -25

No files matched your search

+11 -5
View File
@@ -1,7 +1,13 @@
# Keep Alpine's musl ABI and rTorrent version; export only runtime dependencies.
FROM alpine:3.24 AS runtime
RUN apk add --no-cache rtorrent ca-certificates tzdata \
build-base curl-dev lddtreepax python3
# Install the distro-packaged rTorrent/libtorrent pair; export its glibc runtime.
FROM opensuse/tumbleweed:latest AS runtime
RUN zypper --non-interactive dup --no-recommends \
&& zypper --non-interactive install --no-recommends \
rtorrent ca-certificates ca-certificates-mozilla timezone \
gcc glibc-devel libcurl-devel binutils python3 \
&& rpm -q rtorrent libtorrent55 \
&& test "$(rpm -q --qf '%{VERSION}' rtorrent)" = "$(rpm -q --qf '%{VERSION}' libtorrent55)" \
&& test "$(printf '%s\n' 0.16.27 "$(rpm -q --qf '%{VERSION}' rtorrent)" | sort -V | head -n1)" = 0.16.27 \
&& zypper clean --all
COPY install/rtorrent-entrypoint.c /build/rtorrent-entrypoint.c
RUN cc -Os -Wall -Wextra -Werror -o /usr/local/bin/rtorrent-entrypoint /build/rtorrent-entrypoint.c \
&& strip /usr/local/bin/rtorrent-entrypoint
@@ -11,7 +17,7 @@ RUN cc -Os -Wall -Wextra -Werror -o /usr/local/bin/rtorrent-public-ip /build/rto
COPY build/runtime-root.py /build/runtime-root.py
RUN python3 /build/runtime-root.py /runtime /usr/bin/rtorrent /usr/local/bin/rtorrent-entrypoint /usr/local/bin/rtorrent-public-ip
COPY tests/rtorrent-smoke.c /build/rtorrent-smoke.c
RUN cc -static -Os -Wall -Wextra -Werror -o /build/rtorrent-smoke /build/rtorrent-smoke.c
RUN cc -Os -Wall -Wextra -Werror -o /build/rtorrent-smoke /build/rtorrent-smoke.c
FROM scratch
COPY --from=runtime /runtime/ /