-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile.zomboid
45 lines (33 loc) · 1.16 KB
/
Dockerfile.zomboid
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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
FROM debian:bookworm
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y --no-install-recommends \
software-properties-common \
wget \
gnupg \
ca-certificates \
lib32gcc-s1 \
jq \
curl
RUN echo "deb http://deb.debian.org/debian/ bookworm non-free" >> /etc/apt/sources.list && \
dpkg --add-architecture i386 && \
apt-get update -y
RUN echo "steam steam/license note" | debconf-set-selections && \
echo "steam steam/question select I AGREE" | debconf-set-selections
RUN apt-get install -y steamcmd
RUN mkdir -p /opt/pzserver /root/Zomboid/backups/startup \
/root/Zomboid/backups/version /root/Zomboid/db /root/Zomboid/Server && \
chmod -R 755 /root/Zomboid
COPY main.sh /root/main.sh
RUN chmod +x /root/main.sh
RUN chmod -R 777 /root/Zomboid/Server
RUN echo "// update_zomboid.txt\n\
@ShutdownOnFailedCommand 1\n\
@NoPromptForPassword 1\n\
force_install_dir /opt/pzserver/\n\
login anonymous\n\
app_update 380870 validate\n\
quit" > /root/update_zomboid.txt
RUN export PATH=$PATH:/usr/games && \
steamcmd +runscript /root/update_zomboid.txt
EXPOSE 16261/udp 16262/udp
ENTRYPOINT ["/root/main.sh"]