Skip to content

Commit

Permalink
Add lidarr image
Browse files Browse the repository at this point in the history
  • Loading branch information
HadrienPatte committed Oct 8, 2024
1 parent 0e33cb2 commit 6e38ee8
Show file tree
Hide file tree
Showing 5 changed files with 57 additions and 3 deletions.
51 changes: 51 additions & 0 deletions images/lidarr/Dockerfile
Original file line number Diff line number Diff line change
@@ -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"]
3 changes: 3 additions & 0 deletions images/lidarr/metadata.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"repository": "Lidarr/Lidarr"
}
2 changes: 1 addition & 1 deletion images/prowlarr/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
2 changes: 1 addition & 1 deletion images/radarr/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
2 changes: 1 addition & 1 deletion images/sonarr/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down

0 comments on commit 6e38ee8

Please sign in to comment.