commit
da15618055
@ -1,29 +1,81 @@
|
||||
FROM linuxserver/baseimage.python
|
||||
MAINTAINER smdion <me@seandion.com> ,Sparklyballs <sparklyballs@linuxserver.io>
|
||||
|
||||
ENV BEETSDIR /config
|
||||
ENV APTLIST="ffmpeg lame libav-tools libchromaprint-tools libjpeg8-dev libopenjpeg-dev libpng12-dev libyaml-dev mp3gain python2.7"
|
||||
|
||||
# copy sources.list
|
||||
COPY sources.list /etc/apt/
|
||||
|
||||
RUN add-apt-repository ppa:fkrull/deadsnakes-python2.7 && \
|
||||
add-apt-repository ppa:kirillshkrogalev/ffmpeg-next && \
|
||||
apt-get update -q && \
|
||||
apt-get install $APTLIST -qy && \
|
||||
pip install -U pyacoustid && \
|
||||
pip install -U pylast && \
|
||||
pip install -U flask && \
|
||||
pip install -U pillow && \
|
||||
pip install -U beets && \
|
||||
apt-get clean && rm -rf /tmp/* /var/lib/apt/lists/* /var/tmp/* /root/.cache
|
||||
|
||||
#Adding Custom files
|
||||
ADD init/ /etc/my_init.d/
|
||||
ADD services/ /etc/service/
|
||||
ADD defaults/ /defaults/
|
||||
RUN chmod -v +x /etc/service/*/run /etc/my_init.d/*.sh
|
||||
|
||||
# Volumes and Ports
|
||||
VOLUME /config /downloads /music
|
||||
FROM lsiobase/alpine
|
||||
MAINTAINER sparklyballs
|
||||
|
||||
# environment settings
|
||||
ENV BEETSDIR="/config"
|
||||
|
||||
# install runtime packages
|
||||
RUN \
|
||||
apk add --no-cache \
|
||||
curl \
|
||||
expat \
|
||||
ffmpeg \
|
||||
ffmpeg-libs \
|
||||
gdbm \
|
||||
jpeg \
|
||||
lame \
|
||||
libffi \
|
||||
libpng \
|
||||
openjpeg \
|
||||
py-pip \
|
||||
python \
|
||||
py-unidecode \
|
||||
sqlite-libs \
|
||||
wget && \
|
||||
|
||||
# install build packages
|
||||
apk add --no-cache --virtual=build-dependencies \
|
||||
cmake \
|
||||
ffmpeg-dev \
|
||||
g++ \
|
||||
gcc \
|
||||
git \
|
||||
jpeg-dev \
|
||||
libpng-dev \
|
||||
make \
|
||||
openjpeg-dev \
|
||||
python-dev && \
|
||||
|
||||
# compile mp3gain
|
||||
mkdir -p \
|
||||
/tmp/mp3gain-src && \
|
||||
curl -o \
|
||||
/tmp/mp3gain-src/mp3gain.zip -L \
|
||||
https://sourceforge.net/projects/mp3gain/files/mp3gain/1.5.2/mp3gain-1_5_2_r2-src.zip && \
|
||||
cd /tmp/mp3gain-src && \
|
||||
unzip -qq /tmp/mp3gain-src/mp3gain.zip && \
|
||||
make && \
|
||||
make install && \
|
||||
|
||||
# compile chromaprint
|
||||
git clone https://bitbucket.org/acoustid/chromaprint.git \
|
||||
/tmp/chromaprint && \
|
||||
cd /tmp/chromaprint && \
|
||||
cmake \
|
||||
-DBUILD_EXAMPLES=ON . \
|
||||
-DCMAKE_BUILD_TYPE=Release && \
|
||||
make && \
|
||||
make install && \
|
||||
|
||||
# install pip packages
|
||||
pip install --no-cache-dir -U \
|
||||
beets \
|
||||
flask \
|
||||
pillow \
|
||||
pip \
|
||||
pyacoustid \
|
||||
pylast && \
|
||||
|
||||
# cleanup
|
||||
apk del --purge \
|
||||
build-dependencies && \
|
||||
rm -rf \
|
||||
/root/.cache \
|
||||
/tmp/*
|
||||
|
||||
# copy local files
|
||||
COPY root/ /
|
||||
|
||||
# ports and volumes
|
||||
EXPOSE 8337
|
||||
VOLUME /config /downloads /music
|
||||
|
||||
@ -1,10 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
# opt out for autoupdates
|
||||
[ "$ADVANCED_DISABLEUPDATES" ] && exit 0
|
||||
|
||||
pip install -U pyacoustid
|
||||
pip install -U pylast
|
||||
pip install -U flask
|
||||
pip install -U pillow
|
||||
pip install -U beets
|
||||
@ -1,7 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
[[ ! -f /config/beets.sh ]] && cp /defaults/beets.sh /config/beets.sh
|
||||
[[ ! -f /config/config.yaml ]] && cp /defaults/config.yaml /config/config.yaml
|
||||
|
||||
chown -R abc:abc /config
|
||||
|
||||
@ -0,0 +1,5 @@
|
||||
#!/usr/bin/with-contenv bash
|
||||
umask 002
|
||||
|
||||
exec \
|
||||
s6-setuidgid abc beet web
|
||||
@ -1,4 +0,0 @@
|
||||
#!/bin/bash
|
||||
umask 002
|
||||
|
||||
/sbin/setuser abc beet web
|
||||
@ -1,34 +0,0 @@
|
||||
# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to
|
||||
# newer versions of the distribution.
|
||||
|
||||
deb http://archive.ubuntu.com/ubuntu/ trusty main restricted
|
||||
deb-src http://archive.ubuntu.com/ubuntu/ trusty main restricted
|
||||
|
||||
## Major bug fix updates produced after the final release of the
|
||||
## distribution.
|
||||
deb http://archive.ubuntu.com/ubuntu/ trusty-updates main restricted
|
||||
deb-src http://archive.ubuntu.com/ubuntu/ trusty-updates main restricted
|
||||
|
||||
## Uncomment the following two lines to add software from the 'universe'
|
||||
## repository.
|
||||
## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
|
||||
## team. Also, please note that software in universe WILL NOT receive any
|
||||
## review or updates from the Ubuntu security team.
|
||||
deb http://archive.ubuntu.com/ubuntu/ trusty universe multiverse
|
||||
deb-src http://archive.ubuntu.com/ubuntu/ trusty universe multiverse
|
||||
deb http://archive.ubuntu.com/ubuntu/ trusty-updates universe multiverse
|
||||
deb-src http://archive.ubuntu.com/ubuntu/ trusty-updates universe multiverse
|
||||
|
||||
## N.B. software from this repository may not have been tested as
|
||||
## extensively as that contained in the main release, although it includes
|
||||
## newer versions of some applications which may provide useful features.
|
||||
## Also, please note that software in backports WILL NOT receive any review
|
||||
## or updates from the Ubuntu security team.
|
||||
# deb http://archive.ubuntu.com/ubuntu/ trusty-backports main restricted
|
||||
# deb-src http://archive.ubuntu.com/ubuntu/ trusty-backports main restricted
|
||||
|
||||
deb http://archive.ubuntu.com/ubuntu/ trusty-security main restricted
|
||||
deb-src http://archive.ubuntu.com/ubuntu/ trusty-security main restricted
|
||||
deb http://archive.ubuntu.com/ubuntu/ trusty-security universe multiverse
|
||||
deb-src http://archive.ubuntu.com/ubuntu/ trusty-security universe multiverse
|
||||
|
||||
Loading…
Reference in New Issue