diff --git a/images/lidarr/Dockerfile b/images/lidarr/Dockerfile new file mode 100644 index 0000000..d6bde36 --- /dev/null +++ b/images/lidarr/Dockerfile @@ -0,0 +1,51 @@ +ARG GOLANG_VERSION +FROM golang:$GOLANG_VERSION AS builder + +ARG TARGETARCH +ARG VERSION +ARG CHISEL_VERSION + +# Install chisel and build rootfs with lidarr dependencies +RUN \ + go install github.com/canonical/chisel/cmd/chisel@${CHISEL_VERSION} \ + && curl -LO https://raw.githubusercontent.com/canonical/rocks-toolbox/main/chisel-wrapper \ + && chmod +x ./chisel-wrapper \ + && apt update \ + && apt install file --yes \ + && mkdir -p /rootfs/var/lib/dpkg \ + && ./chisel-wrapper --generate-dpkg-status /rootfs/var/lib/dpkg/status -- \ + --release ubuntu-24.04 \ + --root /rootfs \ + base-files_base \ + ca-certificates_data \ + libicu74_libs \ + libsqlite3-0_libs \ + libssl3t64_libs \ + zlib1g_libs \ + coreutils_bins \ + && useradd \ + --root /rootfs \ + --system \ + --no-create-home \ + --uid 1000 \ + nonroot \ + && rm /rootfs/etc/.pwd.lock \ + && mkdir /rootfs/config \ + && chown 1000 /rootfs/config + +# Download lidarr +RUN \ + case "${TARGETARCH}" in \ + 'amd64') export ARCH='x64' ;; \ + 'arm64') export ARCH='arm64' ;; \ + esac \ + && curl -L "https://github.com/Lidarr/Lidarr/releases/download/v${VERSION}/Lidarr.master.${VERSION}.linux-core-${ARCH}.tar.gz" \ + | tar xzf - -C / \ + && rm -rf /Lidarr/Lidarr.Update + +FROM scratch +COPY --from=builder /rootfs / +COPY --from=builder /Lidarr /Lidarr + +USER nonroot +ENTRYPOINT ["/Lidarr/Lidarr", "--nobrowser", "--data=/config"] diff --git a/images/lidarr/metadata.json b/images/lidarr/metadata.json new file mode 100644 index 0000000..6c84a25 --- /dev/null +++ b/images/lidarr/metadata.json @@ -0,0 +1,3 @@ +{ + "repository": "Lidarr/Lidarr" +} diff --git a/images/prowlarr/Dockerfile b/images/prowlarr/Dockerfile index 629d3e8..22ff436 100644 --- a/images/prowlarr/Dockerfile +++ b/images/prowlarr/Dockerfile @@ -39,7 +39,7 @@ RUN \ 'arm64') export ARCH='arm64' ;; \ esac \ && curl -L "https://github.com/Prowlarr/Prowlarr/releases/download/v${VERSION}/Prowlarr.master.${VERSION}.linux-core-${ARCH}.tar.gz" \ - | tar xzf - -C / \ + | tar xzf - -C / \ && rm -rf /Prowlarr/Prowlarr.Update FROM scratch diff --git a/images/radarr/Dockerfile b/images/radarr/Dockerfile index c225abd..9f1ac14 100644 --- a/images/radarr/Dockerfile +++ b/images/radarr/Dockerfile @@ -39,7 +39,7 @@ RUN \ 'arm64') export ARCH='arm64' ;; \ esac \ && curl -L "https://github.com/Radarr/Radarr/releases/download/v${VERSION}/Radarr.master.${VERSION}.linux-core-${ARCH}.tar.gz" \ - | tar xzf - -C / \ + | tar xzf - -C / \ && rm -rf /Radarr/Radarr.Update FROM scratch diff --git a/images/sonarr/Dockerfile b/images/sonarr/Dockerfile index 9bee003..b9fe89a 100644 --- a/images/sonarr/Dockerfile +++ b/images/sonarr/Dockerfile @@ -39,7 +39,7 @@ RUN \ 'arm64') export ARCH='arm64' ;; \ esac \ && curl -L "https://github.com/Sonarr/Sonarr/releases/download/v${VERSION}/Sonarr.main.${VERSION}.linux-${ARCH}.tar.gz" \ - | tar xzf - -C / \ + | tar xzf - -C / \ && rm -rf /Sonarr/Sonarr.Update FROM scratch