mirror of https://github.com/captn3m0/muse-dl.git
Finishes Dockerfile for running
This commit is contained in:
parent
2d7430e780
commit
88a23f6370
33
Dockerfile
33
Dockerfile
|
@ -1,4 +1,4 @@
|
||||||
FROM ubuntu:19.04
|
FROM debian:10-slim
|
||||||
|
|
||||||
WORKDIR /build
|
WORKDIR /build
|
||||||
|
|
||||||
|
@ -7,20 +7,37 @@ COPY . .
|
||||||
# Add the key for the crystal debian repo
|
# Add the key for the crystal debian repo
|
||||||
ADD https://keybase.io/crystal/pgp_keys.asc /tmp/crystal.gpg
|
ADD https://keybase.io/crystal/pgp_keys.asc /tmp/crystal.gpg
|
||||||
|
|
||||||
# Install gnupg for the apt-key operation and openssl for our TLS stuff
|
# See https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=863199 for why mkdir is needed
|
||||||
RUN apt-get update && \
|
RUN mkdir -p /usr/share/man/man1 && \
|
||||||
apt-get install --yes --no-install-recommends gnupg=2.2.12-1ubuntu3 libssl-dev=1.1.1b-1ubuntu2.4 && \
|
apt-get update && \
|
||||||
|
apt-get install --yes --no-install-recommends \
|
||||||
|
# Install gnupg for the apt-key operation
|
||||||
|
gnupg=2.2.12-1+deb10u1 \
|
||||||
|
# libssl for faster TLS in Crystal
|
||||||
|
libssl-dev=1.1.1d-0+deb10u2 \
|
||||||
|
# pdftk as a dependency for muse-dl
|
||||||
|
pdftk=2.02-5 \
|
||||||
|
# ca-certificates for talking to crystal-lang.org
|
||||||
|
ca-certificates=20190110 \
|
||||||
|
# git to let shards install happen
|
||||||
|
git=1:2.20.1-2+deb10u1 \
|
||||||
|
# build --release
|
||||||
|
zlib1g-dev=1:1.2.11.dfsg-1 && \
|
||||||
# See https://crystal-lang.org/install/
|
# See https://crystal-lang.org/install/
|
||||||
apt-key add /tmp/crystal.gpg && \
|
apt-key add /tmp/crystal.gpg && \
|
||||||
echo "deb https://dist.crystal-lang.org/apt crystal main" > /etc/apt/sources.list.d/crystal.list && \
|
echo "deb https://dist.crystal-lang.org/apt crystal main" > /etc/apt/sources.list.d/crystal.list && \
|
||||||
apt-get update && \
|
apt-get update && \
|
||||||
apt-get install --no-install-recommends --yes crystal=0.33.0-1 pdftk=2.02-5 && \
|
apt-get install --no-install-recommends --yes crystal=0.33.0-1 && \
|
||||||
# Cleanup
|
# Cleanup
|
||||||
apt-get clean && \
|
apt-get clean && \
|
||||||
rm -rf /var/lib/apt/lists/*
|
rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
RUN shards install && shards build --release
|
RUN shards install && shards build --release && \
|
||||||
|
ln /build/bin/muse-dl /usr/bin/muse-dl
|
||||||
|
|
||||||
VOLUME /output
|
RUN apt-get --yes remove git gnupg
|
||||||
|
|
||||||
ENTRYPOINT ["/build/bin/muse-dl"]
|
WORKDIR /data
|
||||||
|
VOLUME /data
|
||||||
|
|
||||||
|
ENTRYPOINT ["/usr/bin/muse-dl"]
|
Loading…
Reference in New Issue