File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -12,7 +12,9 @@ RUN mvn -q -DskipTests package && \
1212FROM golang:1.25-bookworm AS golibrespot-build
1313WORKDIR /src
1414
15- RUN apt-get update && apt-get install -y --no-install-recommends \
15+ ARG APT_FLAGS="-o Acquire::Retries=5 -o Acquire::http::Timeout=30 -o Acquire::https::Timeout=30"
16+
17+ RUN apt-get ${APT_FLAGS} update && apt-get ${APT_FLAGS} install -y --no-install-recommends \
1618 git \
1719 pkg-config \
1820 libogg-dev \
@@ -26,21 +28,26 @@ RUN git clone --depth 1 --branch v0.7.1 https://github.com/devgianlu/go-librespo
2628WORKDIR /src/go-librespot
2729RUN go build -o /out/go-librespot ./cmd/daemon
2830
29- FROM eclipse-temurin:17-jre
31+ FROM debian:bookworm-slim
3032WORKDIR /app
3133
32- RUN apt-get update && apt-get install -y --no-install-recommends \
34+ ARG APT_FLAGS="-o Acquire::Retries=5 -o Acquire::http::Timeout=30 -o Acquire::https::Timeout=30"
35+
36+ RUN apt-get ${APT_FLAGS} update && apt-get ${APT_FLAGS} install -y --no-install-recommends \
3337 ffmpeg \
3438 ca-certificates \
35- libasound2t64 && \
39+ libasound2 && \
3640 rm -rf /var/lib/apt/lists/*
3741
42+ COPY --from=build /opt/java/openjdk /opt/java/openjdk
3843COPY --from=build /out/JMusicBot.jar /app/JMusicBot.jar
3944COPY --from=golibrespot-build /out/go-librespot /usr/local/bin/go-librespot
4045COPY docker/docker-entrypoint.sh /usr/local/bin/docker-entrypoint.sh
4146
4247RUN chmod +x /usr/local/bin/docker-entrypoint.sh /usr/local/bin/go-librespot
4348
49+ ENV JAVA_HOME=/opt/java/openjdk
50+ ENV PATH="${JAVA_HOME}/bin:${PATH}"
4451ENV JMUSICBOT_HOME=/data
4552VOLUME ["/data" ]
4653
You can’t perform that action at this time.
0 commit comments