diff --git a/Dockerfile b/Dockerfile index 81b2fe0..dc703c7 100644 --- a/Dockerfile +++ b/Dockerfile @@ -3,12 +3,12 @@ FROM alpine:latest AS build # Args ARG MINECRAFT_VERSION="1.16.5" -ARG FORGE_VERSION="36.1.13" +ARG FORGE_VERSION="36.2.26" # The actual setup work COPY start-server.sh /minecraft/start-server.sh WORKDIR /minecraft -RUN apk add curl openjdk8-jre &&\ +RUN apk add curl openjdk11-jre &&\ curl -L "https://files.minecraftforge.net/maven/net/minecraftforge/forge/${MINECRAFT_VERSION}-${FORGE_VERSION}/forge-${MINECRAFT_VERSION}-${FORGE_VERSION}-installer.jar" -o installer.jar &&\ java -jar installer.jar --installServer &&\ echo "eula=true" > eula.txt &&\ @@ -16,7 +16,7 @@ RUN apk add curl openjdk8-jre &&\ ln -s "forge-${MINECRAFT_VERSION}-${FORGE_VERSION}.jar" server.jar # The second stage is the actual container -FROM openjdk:8 +FROM openjdk:11 RUN apt-get update && apt-get install rsync screen -y WORKDIR /minecraft COPY --from=build /minecraft . diff --git a/build.sh b/build.sh index 3548604..33e3b2f 100755 --- a/build.sh +++ b/build.sh @@ -5,14 +5,14 @@ # MC version list declare -a mcversions=( - "1.12.2" "1.16.5" + "1.18.2" ) # Forge version dictionary (we only support one version per) declare -A forgeversions=( - ["1.12.2"]="14.23.5.2855" - ["1.16.5"]="36.1.13" + ["1.16.5"]="36.2.35" + ["1.18.2"]="40.1.20" ) # Build images diff --git a/start-server.sh b/start-server.sh index af6a7ce..db1244f 100755 --- a/start-server.sh +++ b/start-server.sh @@ -42,6 +42,9 @@ args="-jar server.jar nogui" # Debugging info java -version echo "Invoking java with args: $args" +echo +echo "To see the server console, execute this command in the container:" +echo " screen -r minecraft" # Start 'er up cleanup() {