-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
29 lines (24 loc) · 871 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
29
# Copyright 2015 Sean Nelson <[email protected]>
FROM openjdk:alpine
MAINTAINER Sean Nelson <[email protected]>
ENV BASE_URL="http://ftb.cursecdn.com/FTB2/modpacks/FTBDeparted"
ENV FTB_VERSION="1_4_0"
ENV SERVER_FILE="FTBDepartedServer.zip"
ENV SERVER_PORT 25565
WORKDIR /minecraft
USER root
COPY CheckEula.sh /minecraft/
RUN adduser -D minecraft && \
mkdir -p /minecraft/world && \
apk --no-cache add curl wget && \
curl -SLO ${BASE_URL}/${FTB_VERSION}/${SERVER_FILE} && \
unzip ${SERVER_FILE} && \
chmod u+x FTBInstall.sh ServerStart.sh CheckEula.sh && \
rm eula.txt && \
sed -i '2i /bin/sh /minecraft/CheckEula.sh' /minecraft/ServerStart.sh && \
chown -R minecraft:minecraft /minecraft
USER minecraft
RUN /minecraft/FTBInstall.sh
EXPOSE ${SERVER_PORT}
VOLUME ["/minecraft/world"]
CMD ["/bin/sh", "/minecraft/ServerStart.sh"]