-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
60 lines (48 loc) · 1.59 KB
/
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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
FROM sonroyaalmerol/steamcmd-arm64:root AS build_stage
LABEL maintainer="[email protected]"
LABEL description="A Dockerised version of the Left 4 Dead dedicated server for ARM64 (using box86)"
RUN dpkg --add-architecture amd64 \
&& dpkg --add-architecture i386 \
&& apt-get update \
&& apt-get install -y --no-install-recommends --no-install-suggests \
net-tools \
lib32gcc-s1:amd64 \
lib32stdc++6 \
lib32z1 \
libcurl3-gnutls:i386 \
libcurl4-gnutls-dev:i386 \
libcurl4:i386 \
libgcc1 \
libncurses5:i386 \
libsdl1.2debian \
libtinfo5 \
&& wget http://archive.ubuntu.com/ubuntu/pool/main/o/openssl/libssl1.1_1.1.1f-1ubuntu2_i386.deb \
&& dpkg -i libssl1.1_1.1.1f-1ubuntu2_i386.deb \
&& rm libssl1.1_1.1.1f-1ubuntu2_i386.deb \
&& rm -rf /var/lib/apt/lists/*
ENV HOMEDIR="/home/steam" \
STEAMAPPID="222840" \
STEAMAPPDIR="/home/steam/l4d-server"
COPY etc/entry.sh ${HOMEDIR}/entry.sh
WORKDIR ${STEAMAPPDIR}
RUN chmod +x "${HOMEDIR}/entry.sh" \
&& chown -R "${USER}":"${USER}" "${HOMEDIR}/entry.sh" ${STEAMAPPDIR}
FROM build_stage AS bookworm-root
ENV L4D_ARGS="" \
L4D_CLIENTPORT="27005" \
L4D_IP="" \
L4D_LAN="0" \
L4D_MAP="c1m1_hotel" \
L4D_MAXPLAYERS="12" \
L4D_PORT="27015" \
L4D_SOURCETVPORT="27020" \
L4D_TICKRATE=""
EXPOSE ${L4D_CLIENTPORT}/udp \
${L4D_PORT}/tcp \
${L4D_PORT}/udp \
${L4D_SOURCETVPORT}/udp
USER ${USER}
WORKDIR ${HOMEDIR}
HEALTHCHECK --interval=30s --timeout=10s --start-period=60s --retries=3 \
CMD netstat -l | grep "${L4D_PORT}.*LISTEN"
CMD ["bash", "entry.sh"]