From 9fc6febbc2acc541af068334cf5940bf61fe5bc2 Mon Sep 17 00:00:00 2001 From: Sebastian Hugentobler Date: Thu, 5 Aug 2021 21:21:37 +0200 Subject: [PATCH] download the prebuilt jar... --- Dockerfile | 33 ++++++++++----------------------- 1 file changed, 10 insertions(+), 23 deletions(-) diff --git a/Dockerfile b/Dockerfile index 5cda0b9..9036f1b 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,25 +1,15 @@ -FROM openjdk:16-alpine as builder - -RUN apk --no-cache add \ - patch \ - maven \ - git - -RUN git config --global user.email "papermcbuilder@vanwa.ch" -RUN git config --global user.name "Vanwa papermc builder" - -ENV VERSION=f521a18a17f32997793b2d0b2ebcd7890f200fc8 -RUN git clone https://github.com/PaperMC/Paper.git - -WORKDIR /Paper -RUN git checkout "$VERSION" -RUN ./gradlew applyPatches -RUN ./gradlew build -RUN mv /Paper/Paper-Server/build/libs/Paper-Server-*-dev.jar /Paper/Paper-Server/build/libs/paper.jar - FROM thallian/confd-env:latest -COPY --from=builder /Paper/Paper-Server/build/libs/paper.jar /var/lib/minecraft/paper.jar +RUN addgroup minecraft -g 2222 +RUN adduser -u 2222 -h /var/lib/minecraft -D -G minecraft minecraft + +ENV VERSION=1.17.1 +ENV SERIAL=157 +ENV SHA256_SUM=862b043fbc0be948c380bced4aee224200568954db941ca6f6ac568cab263991 +RUN wget -O /var/lib/minecraft/paper.jar \ + https://papermc.io/api/v2/projects/paper/versions/$VERSION/builds/$SERIAL/downloads/paper-$VERSION-$SERIAL.jar + +RUN echo "$SHA256_SUM /var/lib/minecraft/paper.jar" | sha256sum -c - || exit 1 RUN apk add --no-cache \ openssl @@ -27,9 +17,6 @@ RUN apk add --no-cache \ RUN apk add --no-cache --repository=http://dl-cdn.alpinelinux.org/alpine/edge/testing \ openjdk16-jre-headless -RUN addgroup minecraft -g 2222 -RUN adduser -u 2222 -h /var/lib/minecraft -D -G minecraft minecraft - RUN mkdir -p /etc/services.d/minecraft/ ADD /rootfs /