-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathlinux.Dockerfile
54 lines (38 loc) · 1.7 KB
/
linux.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
# escape=`
FROM lacledeslan/steamcmd:linux as cssource-builder
# Copy cached build files (if any)
COPY /build-cache /output
# Download Counter-Strike: Source
RUN /app/steamcmd.sh +force_install_dir /output +login anonymous +app_update 232330 validate +quit;
COPY ./dist/linux/ll-tests /output/ll-tests
#=======================================================================
FROM debian:bookworm-slim
ARG BUILDNODE=unspecified
ARG SOURCE_COMMIT=unspecified
HEALTHCHECK NONE
RUN dpkg --add-architecture i386 &&`
apt-get update && apt-get install -y `
ca-certificates lib32gcc-s1 libncurses5:i386 libsdl2-2.0-0:i386 libstdc++6 libstdc++6:i386 locales locales-all tmux &&`
apt-get clean &&`
rm -rf /tmp/* /var/lib/apt/lists/* /var/tmp/*;
ENV LANG=en_US.UTF-8 LANGUAGE=en_US.UTF-8 LC_ALL=en_US.UTF-8
LABEL com.lacledeslan.build-node=$BUILDNODE `
org.label-schema.schema-version="1.0" `
org.label-schema.url="https://github.com/LacledesLAN/README.1ST" `
org.label-schema.vcs-ref=$SOURCE_COMMIT `
org.label-schema.vendor="Laclede's LAN" `
org.label-schema.description="Counter-Strike Source Dedicated Server" `
org.label-schema.vcs-url="https://github.com/LacledesLAN/gamesvr-cssource"
# Set up Enviornment
RUN useradd --home /app --gid root --system CSSource &&`
mkdir --parents /app &&`
chown CSSource:root -R /app;
COPY --chown=CSSource:root --from=cssource-builder /output /app
RUN chmod +x /app/ll-tests/*.sh &&`
echo $'\n\nLinking steamclient.so to prevent srcds_run errors' &&`
mkdir --parents /app/.steam/sdk32 &&`
ln -s /app/bin/steamclient.so /app/.steam/sdk32/steamclient.so
USER CSSource
WORKDIR /app
CMD ["/bin/bash"]
ONBUILD USER root