From: Marcel van der Veldt Date: Mon, 2 Nov 2020 23:39:33 +0000 (+0100) Subject: Update Dockerfile X-Git-Url: https://git.kitaultman.com/?a=commitdiff_plain;h=8581d10807ab9937f07f4332c90f8d029ba1d59d;p=music-assistant-server.git Update Dockerfile --- diff --git a/Dockerfile b/Dockerfile index d9925207..2c1e796b 100755 --- a/Dockerfile +++ b/Dockerfile @@ -1,39 +1,50 @@ -FROM python:3.8-slim +FROM alpine:3.12 # Versions ARG JEMALLOC_VERSION=5.2.1 -ARG MASS_VERSION=0.0.61 - -# Base system -WORKDIR /tmp +ARG MASS_VERSION=0.0.62 # Install packages RUN set -x \ - && apt-get update && apt-get install -y --no-install-recommends \ - # required packages - git jq tzdata curl ca-certificates flac sox libsox-fmt-all zip curl ffmpeg libsndfile1 libtag1v5 \ - # build packages - # build-essential libtag1-dev libffi-dev\ - && rm -rf /var/lib/apt/lists/* \ - && mkdir -p /usr/share/man/man1 + && apk update \ + && echo "http://dl-8.alpinelinux.org/alpine/edge/community" >> /etc/apk/repositories \ + && echo "http://dl-8.alpinelinux.org/alpine/edge/testing" >> /etc/apk/repositories \ + # default packages + && apk add --no-cache \ + tzdata \ + ca-certificates \ + curl \ + bind-tools \ + flac \ + sox \ + ffmpeg \ + python3 \ + py3-numpy \ + py3-scipy \ + py3-pytaglib \ + py3-pillow \ + # build packages + && apk add --no-cache --virtual .build-deps \ + build-base # setup jmalloc -RUN curl -L -s https://github.com/jemalloc/jemalloc/releases/download/${JEMALLOC_VERSION}/jemalloc-${JEMALLOC_VERSION}.tar.bz2 | tar -xjf - -C /usr/src \ +RUN mkdir /usr/src \ + && curl -L -f -s "https://github.com/jemalloc/jemalloc/releases/download/${JEMALLOC_VERSION}/jemalloc-${JEMALLOC_VERSION}.tar.bz2" \ + | tar -xjf - -C /usr/src \ && cd /usr/src/jemalloc-${JEMALLOC_VERSION} \ && ./configure \ && make \ && make install \ && rm -rf /usr/src/jemalloc-${JEMALLOC_VERSION} \ - \ + # change workdir back to /tmp && cd /tmp # install uvloop and music assistant RUN pip install --upgrade uvloop music-assistant==${MASS_VERSION} # cleanup build files -RUN apt-get purge -y --auto-remove libtag1-dev libffi-dev build-essential \ - && rm -rf /var/lib/apt/lists/* - +RUN apk del .build-deps \ + && rm -rf /usr/src/* ENV DEBUG=false VOLUME [ "/data" ]