lidarr-on-steroids/Dockerfile

58 lines
1.9 KiB
Docker
Raw Permalink Normal View History

2023-09-13 18:37:09 +00:00
FROM --platform=$TARGETPLATFORM docker.io/library/node:16-alpine as deemix
2023-09-10 16:52:32 +00:00
2023-09-13 18:37:09 +00:00
ARG TARGETPLATFORM
ARG BUILDPLATFORM
2023-09-13 18:37:09 +00:00
RUN echo "Building for TARGETPLATFORM=$TARGETPLATFORM | BUILDPLATFORM=$BUILDPLATFORM"
2023-09-09 11:22:14 +00:00
RUN apk add --no-cache git jq python3 make gcc musl-dev g++ && \
rm -rf /var/lib/apt/lists/*
RUN git clone --recurse-submodules https://gitlab.com/RemixDev/deemix-gui.git
WORKDIR deemix-gui
RUN case "$TARGETPLATFORM" in \
"linux/amd64") \
jq '.pkg.targets = ["node16-alpine-x64"]' ./server/package.json > tmp-json ;; \
"linux/arm64") \
jq '.pkg.targets = ["node16-alpine-arm64"]' ./server/package.json > tmp-json ;; \
*) \
2023-09-13 18:37:09 +00:00
echo "Platform $TARGETPLATFORM not supported" && exit 1 ;; \
2023-09-09 11:22:14 +00:00
esac && \
mv tmp-json /deemix-gui/server/package.json
2023-09-09 11:10:47 +00:00
RUN yarn install-all
# Patching deemix: see issue https://github.com/youegraillot/lidarr-on-steroids/issues/63
RUN sed -i 's/const channelData = await dz.gw.get_page(channelName)/let channelData; try { channelData = await dz.gw.get_page(channelName); } catch (error) { console.error(`Caught error ${error}`); return [];}/' ./server/src/routes/api/get/newReleases.ts
RUN yarn dist-server
RUN mv /deemix-gui/dist/deemix-server /deemix-server
2022-07-15 21:35:56 +00:00
FROM cr.hotio.dev/hotio/lidarr:pr-plugins-2.1.1.3878
2022-07-14 23:04:14 +00:00
LABEL maintainer="youegraillot"
ENV DEEMIX_SINGLE_USER=true
ENV AUTOCONFIG=true
2023-09-10 17:15:08 +00:00
ENV CLEAN_DOWNLOADS=true
2022-07-15 12:22:04 +00:00
ENV PUID=1000
ENV PGID=1000
2022-07-14 23:04:14 +00:00
# flac2mp3
RUN apk add --no-cache ffmpeg && \
rm -rf /var/lib/apt/lists/*
2022-07-16 20:40:16 +00:00
COPY lidarr-flac2mp3/root/usr /usr
2022-07-14 23:04:14 +00:00
# deemix
2022-07-15 21:35:56 +00:00
COPY --from=deemix /deemix-server /deemix-server
2022-07-14 23:04:14 +00:00
RUN chmod +x /deemix-server
2022-11-26 15:30:53 +00:00
VOLUME ["/config_deemix", "/downloads"]
2022-07-14 23:04:14 +00:00
EXPOSE 6595
2023-09-10 16:52:32 +00:00
# arl-watch
RUN apk add --no-cache inotify-tools && \
rm -rf /var/lib/apt/lists/*
2022-07-14 23:04:14 +00:00
COPY root /
2023-09-10 16:52:32 +00:00
RUN chmod +x /etc/services.d/*/run && \
chmod +x /usr/local/bin/*.sh
2022-11-26 15:30:53 +00:00
VOLUME ["/config", "/music"]
2022-07-14 23:04:14 +00:00
EXPOSE 6595 8686