Initial commit
The files were ported over from the old repository at https://git.zom.bi/zombi-systems/dockerfiles/-/tree/master/games/forge-modbase originally written by LOD, steffen and madmaurice.
This commit is contained in:
commit
0d7e5e2e52
2 changed files with 62 additions and 0 deletions
37
Dockerfile
Normal file
37
Dockerfile
Normal file
|
@ -0,0 +1,37 @@
|
|||
FROM openjdk:8-jre-slim
|
||||
EXPOSE 25565
|
||||
|
||||
ARG MINECRAFT=1.7.10
|
||||
ARG FORGE=10.13.4.1641
|
||||
|
||||
ENV \
|
||||
ForgeUrl1=http://files.minecraftforge.net/maven/net/minecraftforge/forge/${MINECRAFT}-${FORGE}/forge-${MINECRAFT}-${FORGE}-installer.jar \
|
||||
ForgeUrl2=http://files.minecraftforge.net/maven/net/minecraftforge/forge/${MINECRAFT}-${FORGE}-${MINECRAFT}/forge-${MINECRAFT}-${FORGE}-${MINECRAFT}-installer.jar \
|
||||
InstallerJar=forge-${MINECRAFT}-${FORGE}-installer.jar
|
||||
|
||||
ENV \
|
||||
INSTDIR=/usr/share/minecraft \
|
||||
RUNDIR=/minecraft
|
||||
|
||||
RUN useradd -U -d /minecraft -m forge
|
||||
|
||||
WORKDIR $INSTDIR
|
||||
|
||||
# Since the URL schema changed, we need to try both after another.
|
||||
# Prepare the server files and remove the installer.
|
||||
# The EULA needs to be present, so we also accept it at this point.
|
||||
# The remaining jar beginning with forge-* is the launcher (multiple names
|
||||
# possible), so we will symlink it to forge.jar for convenience.
|
||||
RUN ( wget -O ${InstallerJar} ${ForgeUrl1} || wget -O ${InstallerJar} ${ForgeUrl2} ) && \
|
||||
echo "eula=true" > eula.txt && \
|
||||
java -jar ./${InstallerJar} --installServer && rm -f ${InstallerJar} && \
|
||||
ln -s "forge-${MINECRAFT}-*.jar" forge.jar || exit 2
|
||||
|
||||
COPY entrypoint.sh /usr/bin
|
||||
|
||||
WORKDIR $RUNDIR
|
||||
|
||||
VOLUME ["/minecraft"]
|
||||
|
||||
ENTRYPOINT ["/usr/bin/entrypoint.sh"]
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue