mirror of
https://gitlab.com/Bockiii/deemix-docker.git
synced 2024-08-30 17:32:18 +00:00
Split pipeline
This commit is contained in:
parent
0f3a734f57
commit
694faba076
66
Dockerfile
66
Dockerfile
@ -1,62 +1,28 @@
|
|||||||
FROM lsiobase/ubuntu:focal as builder
|
|
||||||
|
|
||||||
RUN curl -fsSL https://deb.nodesource.com/setup_16.x | bash && \
|
|
||||||
apt-get -y --no-install-recommends install >/dev/null \
|
|
||||||
nodejs \
|
|
||||||
build-essential \
|
|
||||||
git && \
|
|
||||||
npm install --global yarn
|
|
||||||
|
|
||||||
RUN git clone https://gitlab.com/RemixDev/deemix-gui.git --recursive
|
|
||||||
|
|
||||||
WORKDIR /deemix-gui
|
|
||||||
|
|
||||||
RUN yarn config set network-timeout 1000000 -g && \
|
|
||||||
yarn install-all && \
|
|
||||||
yarn build-server && \
|
|
||||||
yarn build-webui && \
|
|
||||||
yarn cache clean && \
|
|
||||||
find . -name 'node_modules' -type d -prune -exec rm -rf '{}' \;
|
|
||||||
|
|
||||||
FROM lsiobase/ubuntu:focal
|
FROM lsiobase/ubuntu:focal
|
||||||
|
|
||||||
ARG BUILDDATE
|
ARG BUILDDATE
|
||||||
ENV BUILDDATEENV=${BUILDDATE}
|
ENV BUILDDATEENV=${BUILDDATE}
|
||||||
|
|
||||||
LABEL \
|
LABEL \
|
||||||
app.deemix.image.created="${BUILDDATE}" \
|
app.deemix.image.created="${BUILDDATE}" \
|
||||||
app.deemix.image.url="https://gitlab.com/Bockiii/deemix-docker" \
|
app.deemix.image.url="https://gitlab.com/Bockiii/deemix-docker" \
|
||||||
app.deemix.image.title="Docker image for Deemix" \
|
app.deemix.image.title="Docker image for Deemix" \
|
||||||
app.deemix.image.description="Docker image for Deemix" \
|
app.deemix.image.description="Docker image for Deemix" \
|
||||||
maintainer="Bocki"
|
maintainer="Bocki"
|
||||||
|
|
||||||
COPY --from=builder /deemix-gui /deemix-gui
|
|
||||||
|
|
||||||
RUN curl -fsSL https://deb.nodesource.com/setup_16.x | bash && \
|
RUN curl -fsSL https://deb.nodesource.com/setup_16.x | bash && \
|
||||||
apt-get -y --no-install-recommends install >/dev/null \
|
apt-get -y --no-install-recommends install >/dev/null \
|
||||||
nodejs \
|
nodejs \
|
||||||
jq \
|
jq \
|
||||||
iputils-ping \
|
iputils-ping \
|
||||||
curl && \
|
unzip \
|
||||||
apt-get clean && \
|
curl && \
|
||||||
rm -rf /var/lib/apt/lists/* && \
|
apt-get clean && \
|
||||||
npm install --global yarn
|
rm -rf /var/lib/apt/lists/* && \
|
||||||
|
mkdir /downloads
|
||||||
|
|
||||||
RUN rm -R /config && \
|
RUN curl -L -o deemix.zip http://gitlab.com/Bockiii/deemix-src/-/jobs/artifacts/master/download?job=dl_src && \
|
||||||
mkdir /deemix-gui/server/music && \
|
unzip deemix
|
||||||
mkdir -p /deem/.config/deemix && \
|
|
||||||
ln -sf /deemix-gui/server/music /downloads && \
|
|
||||||
ln -sf /deem/.config/deemix /config
|
|
||||||
|
|
||||||
WORKDIR /deemix-gui
|
|
||||||
|
|
||||||
RUN yarn config set network-timeout 1000000 -g && \
|
|
||||||
yarn install --prod && \
|
|
||||||
yarn --cwd server install --prod && \
|
|
||||||
yarn cache clean
|
|
||||||
|
|
||||||
|
|
||||||
WORKDIR /deemix-gui
|
|
||||||
|
|
||||||
COPY root/ /
|
COPY root/ /
|
||||||
|
|
||||||
|
@ -3,10 +3,8 @@
|
|||||||
# test write access to download and config folder and test internet connectivity
|
# test write access to download and config folder and test internet connectivity
|
||||||
printf '[cont-init.d] Fixing Folder Permissions\n'
|
printf '[cont-init.d] Fixing Folder Permissions\n'
|
||||||
|
|
||||||
chown abc:abc /deemix-gui/server
|
|
||||||
chown -R abc:abc /deem
|
|
||||||
chown -R abc:abc /config
|
chown -R abc:abc /config
|
||||||
chown -R abc:abc /deemix-gui/server/music
|
chown -R abc:abc /downloads
|
||||||
|
|
||||||
|
|
||||||
# Fix misconfigured download locations. The container's download map is always /downloads.
|
# Fix misconfigured download locations. The container's download map is always /downloads.
|
||||||
|
@ -3,9 +3,7 @@
|
|||||||
UMASK_SET=${UMASK_SET:-022}
|
UMASK_SET=${UMASK_SET:-022}
|
||||||
umask "$UMASK_SET"
|
umask "$UMASK_SET"
|
||||||
|
|
||||||
cd /deemix-gui/server
|
cd /
|
||||||
|
|
||||||
HOME=/deem
|
|
||||||
|
|
||||||
if [ ! -z ${INTPORT} ]; then
|
if [ ! -z ${INTPORT} ]; then
|
||||||
port=$INTPORT
|
port=$INTPORT
|
||||||
@ -13,6 +11,10 @@ else
|
|||||||
port=6595
|
port=6595
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
export DEEMIX_DATA_DIR=/config/
|
||||||
|
export DEEMIX_MUSIC_DIR=/downloads/
|
||||||
|
export DEEMIX_SERVER_PORT=$port
|
||||||
|
export DEEMIX_HOST=0.0.0.0
|
||||||
|
|
||||||
echo "[services.d] Starting Deemix"
|
echo "[services.d] Starting Deemix"
|
||||||
s6-setuidgid abc yarn start-build --host 0.0.0.0 --port $port
|
s6-setuidgid abc node /deemix-gui/server/dist/app.js
|
Loading…
Reference in New Issue
Block a user