-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbase.Dockerfile
42 lines (35 loc) · 1.16 KB
/
base.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
FROM debian:stable-slim
LABEL maintainer="[email protected]"
ENV STEAMCMDDIR /home/steam/steamcmd
# Install, update & upgrade packages
# Create user for the server
# This also creates the home directory we later need
# Clean TMP, apt-get cache and other stuff to make the image smaller
# Create Directory for SteamCMD
# Download SteamCMD
# Extract and delete archive
RUN set -x \
&& apt-get update \
&& apt-get install -y --no-install-recommends --no-install-suggests \
lib32stdc++6 \
lib32gcc1 \
wget \
ca-certificates \
&& useradd -m steam \
&& su steam -c \
"mkdir -p ${STEAMCMDDIR} \
&& cd ${STEAMCMDDIR} \
&& wget -qO- 'https://steamcdn-a.akamaihd.net/client/installer/steamcmd_linux.tar.gz' | tar zxf -" \
&& apt-get remove --purge -y wget \
&& apt-get clean autoclean \
&& apt-get autoremove -y \
&& rm -rf /var/lib/{apt,dpkg,cache,log}/
# Create insurgency directory
RUN mkdir -p /opt/insurgency
RUN chown steam -R /opt/insurgency
# Add startup script
COPY --chown=steam downloadGame.sh /app/downloadGame.sh
RUN su steam -c \
"/app/downloadGame.sh"
WORKDIR /opt/insurgency
USER steam