-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
50 lines (38 loc) · 1.34 KB
/
Dockerfile
File metadata and controls
50 lines (38 loc) · 1.34 KB
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
# Set the base image
FROM ubuntu:24.04
# Set environment variables
ENV USER root
ENV HOME /root
# Set working directory
WORKDIR $HOME
# Insert Steam prompt answers
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
RUN echo steam steam/question select "I AGREE" | debconf-set-selections \
&& echo steam steam/license note '' | debconf-set-selections
# Update the repository and install SteamCMD
ARG DEBIAN_FRONTEND=noninteractive
RUN dpkg --add-architecture i386 \
&& apt-get update -y \
&& apt-get install -y --no-install-recommends ca-certificates locales steamcmd curl unzip \
&& rm -rf /var/lib/apt/lists/*
# Add unicode support
RUN locale-gen en_US.UTF-8
ENV LANG 'en_US.UTF-8'
ENV LANGUAGE 'en_US:en'
# Create symlink for executable
RUN ln -s /usr/games/steamcmd /usr/bin/steamcmd
# Update SteamCMD and verify latest version
RUN steamcmd +quit
# Fix missing directories and libraries
RUN mkdir -p $HOME/.steam \
&& ln -s $HOME/.local/share/Steam/steamcmd/linux32 $HOME/.steam/sdk32 \
&& ln -s $HOME/.local/share/Steam/steamcmd/linux64 $HOME/.steam/sdk64 \
&& ln -s $HOME/.steam/sdk32/steamclient.so $HOME/.steam/sdk32/steamservice.so \
&& ln -s $HOME/.steam/sdk64/steamclient.so $HOME/.steam/sdk64/steamservice.so
COPY start.sh /app/start.sh
WORKDIR /data
EXPOSE 28015/udp
EXPOSE 28016/tcp
EXPOSE 28082/tcp
ENTRYPOINT ["/bin/bash"]
CMD ["/app/start.sh"]