-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
73 lines (57 loc) · 2 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
61
62
63
64
65
66
67
68
69
70
71
72
73
FROM debian:stable-slim AS download_hlds_windows
LABEL creator="Sergey Shorokhov <[email protected]>"
# Install required packages
RUN set -x \
&& apt-get update \
&& apt-get install -y --install-recommends \
curl \
libarchive-tools \
&& rm -rf /var/lib/apt/lists/*
# Download and install DepotDownloader
ARG DepotDownloader_URL="https://github.com/SteamRE/DepotDownloader/releases/download/DepotDownloader_2.7.2/DepotDownloader-linux-x64.zip"
RUN curl -sSL ${DepotDownloader_URL} | bsdtar -xvf - -C /usr/local/bin/ \
&& chmod +x /usr/local/bin/DepotDownloader
ENV APPDIR=/opt/hlds
WORKDIR ${APPDIR}
ARG APPID=90
ARG APPBRANCH=steam_legacy
ARG OS=windows
ARG MOD=cstrike
RUN DepotDownloader -os ${OS} -dir ${APPDIR} -app ${APPID} -beta ${APPBRANCH} -depot 1
RUN DepotDownloader -os ${OS} -dir ${APPDIR} -app ${APPID} -beta ${APPBRANCH} -depot 5
RUN DepotDownloader -os ${OS} -dir ${APPDIR} -app ${APPID} -beta ${APPBRANCH} -depot 11
RUN DepotDownloader -os ${OS} -dir ${APPDIR} -app ${APPID} -beta ${APPBRANCH} -depot 1004
SHELL ["/bin/bash", "-c"]
# Fix first run crash and STEAM Validation rejected issue
RUN cp ${APPDIR}/${MOD}/steam_appid.txt ${APPDIR} \
&& touch ${APPDIR}/${MOD}/{banned,listip}.cfg
# Remove unnecessary files
RUN rm -rf linux64 .DepotDownloader utils/ \
&& find . \
\( \
-name '*.so' -o \
-name '*64.dll' -o \
-name '*.dylib' \
\) -exec rm -rf {} \;
# Remove *.bsp
# RUN find . -name '*.bsp' \
# \( \
# -not -name 'rehlds_*' \
# -not -name 'regamedll_*' \
# -not -name 'de_dust2*' \
# -not -name 'crossfire*' \
# \) \
# -delete
FROM debian:stable-slim AS test_runner
RUN dpkg --add-architecture i386 \
&& apt-get update \
&& apt-get install -y \
wine32 \
rsync \
&& rm -rf /var/lib/apt/lists/*
ENV WINEDEBUG=-all
ENV WINEDLLOVERRIDES=mshtml=
COPY --from=download_hlds_windows /opt/hlds /opt/HLDS
WORKDIR /opt/HLDS
# Add test depend files
COPY --chmod=755 testdemos_files .