mirror of
https://github.com/ENSL/ensl_hlds.git
synced 2024-12-13 14:01:25 +00:00
Merge pull request #1 from brcaswell/docker-desktop-2.2.0.3-patch
PR docker-desktop-2.2.0.3-patch to master
This commit is contained in:
commit
9545566528
4 changed files with 76 additions and 51 deletions
79
Dockerfile
79
Dockerfile
|
@ -1,17 +1,27 @@
|
||||||
FROM ubuntu
|
FROM ubuntu AS Ubuntu_SteamCMD
|
||||||
|
|
||||||
|
# Get Package Dependencies, Accept ToS with Steam Dependency, clear appt cache
|
||||||
RUN dpkg --add-architecture i386 && \
|
RUN dpkg --add-architecture i386 && \
|
||||||
apt-get update && \
|
apt-get update && \
|
||||||
apt-get -y install wget lib32gcc1 lib32stdc++6 libcurl3:i386 unzip liblz4-tool gcc-multilib g++-multilib
|
apt-get -y install wget \
|
||||||
|
lib32gcc1 \
|
||||||
# Accept ToS
|
lib32stdc++6 \
|
||||||
RUN printf "\n2\n"|apt-get install -y steamcmd
|
libstdc++6:i386 \
|
||||||
|
libcurl3:i386 \
|
||||||
|
unzip \
|
||||||
|
liblz4-tool \
|
||||||
|
gcc-multilib \
|
||||||
|
g++-multilib && \
|
||||||
|
printf "\n2\n"|apt-get install -y steamcmd && \
|
||||||
|
rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
RUN useradd -m steam
|
RUN useradd -m steam
|
||||||
|
|
||||||
USER steam
|
USER steam
|
||||||
WORKDIR /home/steam
|
WORKDIR /home/steam
|
||||||
|
|
||||||
|
FROM Ubuntu_SteamCMD AS SteamCMD_HLDS
|
||||||
|
|
||||||
RUN mkdir -p /home/steam/hlds/steamapps/
|
RUN mkdir -p /home/steam/hlds/steamapps/
|
||||||
|
|
||||||
# Run app validate several times workaround HLDS bug
|
# Run app validate several times workaround HLDS bug
|
||||||
|
@ -21,55 +31,54 @@ RUN /usr/games/steamcmd +login anonymous +force_install_dir /home/steam/hlds +ap
|
||||||
COPY --chown=steam files/*.acf /home/steam/hlds/steamapps/
|
COPY --chown=steam files/*.acf /home/steam/hlds/steamapps/
|
||||||
|
|
||||||
# HLDS bug workaround. Geez.
|
# HLDS bug workaround. Geez.
|
||||||
RUN printf "quit\nquit\n"|/usr/games/steamcmd +login anonymous +force_install_dir /home/steam/hlds +app_set_config 90 mod valve +app_update 90 validate ||true
|
RUN printf "quit\nquit\n"|/usr/games/steamcmd +login anonymous +force_install_dir /home/steam/hlds +app_set_config 90 mod valve +app_update 90 validate ||true && \
|
||||||
RUN printf "quit\nquit\n"|/usr/games/steamcmd +login anonymous +force_install_dir /home/steam/hlds +app_set_config 90 mod valve +app_update 90 validate ||true
|
printf "quit\nquit\n"|/usr/games/steamcmd +login anonymous +force_install_dir /home/steam/hlds +app_set_config 90 mod valve +app_update 90 validate ||true && \
|
||||||
RUN printf "quit\nquit\nquit\nquit\nquit\n" |/usr/games/steamcmd +login anonymous +force_install_dir /home/steam/hlds +app_set_config 90 mod valve +app_update 90 validate ||true
|
printf "quit\nquit\nquit\nquit\nquit\n" |/usr/games/steamcmd +login anonymous +force_install_dir /home/steam/hlds +app_set_config 90 mod valve +app_update 90 validate ||true
|
||||||
|
|
||||||
# HLDS bug workaround. Yay.
|
# HLDS bug workaround. Yay.
|
||||||
RUN mkdir -p ~/.steam/sdk32 && ln -s ~/.steam/steamcmd/linux32/steamclient.so ~/.steam/sdk32/steamclient.so
|
RUN mkdir -p ~/.steam/sdk32 && ln -s ~/.steam/steamcmd/linux32/steamclient.so ~/.steam/sdk32/steamclient.so
|
||||||
|
|
||||||
|
COPY scripts/*.sh /home/steam/hlds/
|
||||||
|
|
||||||
|
FROM SteamCMD_HLDS AS HLDS_NS
|
||||||
|
|
||||||
WORKDIR /home/steam/hlds
|
WORKDIR /home/steam/hlds
|
||||||
|
COPY --chown=steam files/ns.sha /home/steam/hlds
|
||||||
|
|
||||||
# NS bug workaround. Since NS links to a GCC which is not included in the steam-provided libstdc++:i386
|
# NS bug workaround. Since NS links to a GCC which is not included in the steam-provided libstdc++:i386
|
||||||
RUN mv libstdc++* /home/steam/
|
RUN mv /home/steam/hlds/libstdc++* /home/steam/ && \
|
||||||
|
# Install NS
|
||||||
|
wget 'https://github.com/ENSL/NS/releases/download/v3.2.2/ns_v322_full.zip' && \
|
||||||
|
unzip ns_v322_full.zip && \
|
||||||
|
cp /home/steam/hlds/ns/liblist.gam /home/steam/hlds/ns/liblist.bak
|
||||||
|
|
||||||
# Install NS
|
FROM HLDS_NS AS HLDS_ENSL
|
||||||
RUN wget 'https://github.com/ENSL/NS/releases/download/v3.2.2/ns_v322_full.zip'
|
|
||||||
COPY --chown=steam files/ns.sha /home/steam/hlds
|
|
||||||
# RUN sha256sum -c ns.sha
|
|
||||||
RUN unzip ns_v322_full.zip
|
|
||||||
|
|
||||||
WORKDIR /home/steam/hlds/ns
|
WORKDIR /home/steam/hlds/ns
|
||||||
|
|
||||||
# NS workarounds
|
|
||||||
RUN echo 70 > steam_appid.txt
|
|
||||||
# RUN mv dlls/ns_i386.so dlls/ns.so || echo
|
|
||||||
|
|
||||||
# ENSL package
|
# ENSL package
|
||||||
RUN cp liblist.gam liblist.bak
|
RUN wget https://github.com/ENSL/ensl-plugin/releases/download/1.4-extra/ENSL_SrvPkg-1.4-extra.zip -O srv.zip && \
|
||||||
# RUN wget https://github.com/ENSL/ensl-plugin/releases/download/v1.4/ensl_srvpkg-v1.4.zip -O srv.zip
|
unzip -o srv.zip && \
|
||||||
RUN wget https://github.com/ENSL/ensl-plugin/releases/download/1.4-extra/ENSL_SrvPkg-1.4-extra.zip -O srv.zip
|
# Use seperate server.cfg because autoexec.cfg is unreliable
|
||||||
RUN unzip -o srv.zip
|
touch /home/steam/hlds/ns/server.cfg
|
||||||
|
|
||||||
# Use seperate server.cfg because autoexec.cfg is unreliable
|
|
||||||
RUN touch /home/steam/hlds/ns/server.cfg
|
|
||||||
|
|
||||||
# Copy own configs including bans
|
# Copy own configs including bans
|
||||||
ADD overlay /home/steam/hlds/ns/
|
ADD overlay /home/steam/hlds/ns/
|
||||||
COPY scripts/*.sh /home/steam/hlds/
|
|
||||||
|
|
||||||
USER root
|
#USER root
|
||||||
RUN chown -R steam /home/steam/hlds
|
#RUN chown -R steam /home/steam/hlds
|
||||||
RUN apt-get install -y libstdc++6:i386
|
#USER steam
|
||||||
USER steam
|
|
||||||
|
|
||||||
WORKDIR /home/steam/hlds
|
WORKDIR /home/steam/hlds
|
||||||
|
|
||||||
# VAC, HLDS, RCON, HLTV
|
# VAC Service
|
||||||
EXPOSE 26900
|
EXPOSE 26900 \
|
||||||
EXPOSE 27016/udp
|
# HLDS
|
||||||
EXPOSE 27016
|
27016 \
|
||||||
EXPOSE 27020
|
# HLDS RCON
|
||||||
|
27016/udp \
|
||||||
|
# HLTV
|
||||||
|
27020
|
||||||
|
|
||||||
# ENTRYPOINT ["/bin/bash"]
|
# ENTRYPOINT ["/bin/bash"]
|
||||||
ENTRYPOINT ["/home/steam/hlds/entry.sh"]
|
ENTRYPOINT ["/home/steam/hlds/entry.sh"]
|
||||||
|
|
|
@ -1,25 +1,39 @@
|
||||||
version: "2"
|
version: "3.0"
|
||||||
|
|
||||||
services:
|
services:
|
||||||
hlds:
|
hlds:
|
||||||
image: ensl/ensl_hlds:latest
|
image: ensl/ensl_hlds:latest
|
||||||
volumes:
|
volumes:
|
||||||
- "./logs:/home/steam/hlds/ns/logs"
|
- "./logs:/home/steam/hlds/ns/logs"
|
||||||
network_mode: "host"
|
network_mode: "ensl_hlds_default"
|
||||||
|
ports:
|
||||||
|
- 26900:26900
|
||||||
|
- 27016:27016/udp
|
||||||
|
- 27016:27016
|
||||||
environment:
|
environment:
|
||||||
- HLDS=1
|
- HLDS=1
|
||||||
|
|
||||||
hltv:
|
hltv:
|
||||||
image: ensl/ensl_hlds:latest
|
image: ensl/ensl_hlds:latest
|
||||||
volumes:
|
volumes:
|
||||||
- "./demos:/home/steam/hlds/ns/demos"
|
- "./demos:/home/steam/hlds/ns/demos"
|
||||||
network_mode: "host"
|
network_mode: "ensl_hlds_default"
|
||||||
|
depends_on:
|
||||||
|
- hlds
|
||||||
|
ports:
|
||||||
|
- 27020:27020
|
||||||
environment:
|
environment:
|
||||||
- HLTV=1
|
- HLTV=1
|
||||||
|
|
||||||
cleaner:
|
cleaner:
|
||||||
image: ensl/ensl_hlds:latest
|
image: ensl/ensl_hlds:latest
|
||||||
volumes:
|
volumes:
|
||||||
- "./demos:/home/steam/hlds/ns/demos"
|
- "./demos:/home/steam/hlds/ns/demos"
|
||||||
- "./logs:/home/steam/hlds/ns/logs"
|
- "./logs:/home/steam/hlds/ns/logs"
|
||||||
|
network_mode: "ensl_hlds_default"
|
||||||
|
depends_on:
|
||||||
|
- hlds
|
||||||
|
- hltv
|
||||||
environment:
|
environment:
|
||||||
- HLDS_ROTATE=1
|
- HLDS_ROTATE=1
|
||||||
- HLTV_ROTATE=1
|
- HLTV_ROTATE=1
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
e1f58f3c671b4c4a6735f4a36cb65da88e6bfc5337a3cb837bfa400d73733896 ns_dedicated_server_v32.zip
|
75561CBE594E5006A8D662DC4C97BB54DA5811FF692692DC6AA1B8EE1212D3E0 ns_v322_full.zip
|
||||||
|
|
|
@ -17,13 +17,15 @@ if [[ "$HLTV_ROTATE" = "1" ]]; then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ "$HLTV" = "1" ]]; then
|
if [[ "$HLTV" = "1" ]]; then
|
||||||
echo "Starting HLTV"
|
echo "Starting HLTV localhost:27016"
|
||||||
export LD_LIBRARY_PATH=.
|
export LD_LIBRARY_PATH=.
|
||||||
./hltv +serverpassword europe +connect localhost:27015 +record demos/gathers >> /home/steam/hlds/ns/demos/hltv-`date +%F-%h:%m`.log
|
./hltv +serverpassword europe +connect localhost:27016 +record demos/gathers >> /home/steam/hlds/ns/demos/hltv-`date +%F-%h:%m`.log
|
||||||
|
echo "Started"
|
||||||
elif [[ "$HLDS" = "1" ]]; then
|
elif [[ "$HLDS" = "1" ]]; then
|
||||||
echo "Starting HLDS"
|
echo "Starting HLDS -port 27016"
|
||||||
export LD_LIBRARY_PATH=.
|
export LD_LIBRARY_PATH=.
|
||||||
./hlds_run -game ns +maxplayers 32 +log on +map ns_veil +exec ns/server.cfg -pingboost 3 +sys_ticrate 1000
|
./hlds_run -game ns +maxplayers 32 +log on +map ns_veil +exec ns/server.cfg -port 27016 -pingboost 3 +sys_ticrate 1000
|
||||||
|
echo "Started"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
bash
|
bash
|
||||||
|
|
Loading…
Reference in a new issue