forked from audiohacked/docker-direwolf20_110
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathDockerfile
28 lines (23 loc) · 915 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
# Copyright 2015-2017 Sean Nelson <audiohacked@gmail.com>
FROM openjdk:8-jre-alpine
MAINTAINER William Lees <willwill56@gmail.com>
ENV BASE_URL="http://ftb.cursecdn.com/FTB2/modpacks/FTBPresentsDirewolf20112" \
MODPACK_VERSION="2_4_0" \
SERVER_FILE="FTBPresentsDirewolf20112Server.zip" \
SERVER_PORT=25565
WORKDIR /minecraft
USER root
COPY CheckEula.sh /minecraft/
RUN adduser -D minecraft && \
apk --no-cache add wget && \
chown -R minecraft:minecraft /minecraft
USER minecraft
RUN mkdir -p /minecraft/world && \
wget ${BASE_URL}/${MODPACK_VERSION}/${SERVER_FILE} && \
unzip ${SERVER_FILE} && \
chmod u+x FTBInstall.sh ServerStart.sh CheckEula.sh && \
sed -i '2i /bin/sh /minecraft/CheckEula.sh' /minecraft/ServerStart.sh && \
/minecraft/FTBInstall.sh
EXPOSE ${SERVER_PORT}
VOLUME ["/minecraft/world", "/minecraft/backups"]
CMD ["/bin/sh", "/minecraft/ServerStart.sh"]