forked from linuxserver/docker-lidarr
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
46 lines (41 loc) · 1.19 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
FROM lsiobase/mono:LTS
# set version label
ARG BUILD_DATE
ARG VERSION
ARG LIDARR_RELEASE
LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DATE}"
LABEL maintainer="thelamer"
# environment settings
ARG DEBIAN_FRONTEND="noninteractive"
ARG LIDARR_BRANCH="master"
ENV XDG_CONFIG_HOME="/config/xdg"
RUN \
echo "**** install packages ****" && \
apt-get update && \
apt-get install --no-install-recommends -y \
libchromaprint-tools \
jq && \
echo "**** install lidarr ****" && \
mkdir -p /app/lidarr && \
if [ -z ${LIDARR_RELEASE+x} ]; then \
LIDARR_RELEASE=$(curl -sL "https://services.lidarr.audio/v1/update/${LIDARR_BRANCH}/changes?os=linux" \
| jq -r '.[0].version'); \
fi && \
lidarr_url=$(curl -sL "https://services.lidarr.audio/v1/update/${LIDARR_BRANCH}/changes?os=linux" \
| jq -r "first(.[] | select(.version == \"${LIDARR_RELEASE}\")) | .url") && \
curl -o \
/tmp/lidarr.tar.gz -L \
"${lidarr_url}" && \
tar ixzf \
/tmp/lidarr.tar.gz -C \
/app/lidarr --strip-components=1 && \
echo "**** cleanup ****" && \
rm -rf \
/tmp/* \
/var/lib/apt/lists/* \
/var/tmp/*
# copy local files
COPY root/ /
# ports and volumes
EXPOSE 8686
VOLUME /config /downloads /music