-
Notifications
You must be signed in to change notification settings - Fork 1
/
Dockerfile
43 lines (34 loc) · 1.07 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
FROM ubuntu:14.04
MAINTAINER Rufus Linke <[email protected]>
# install steamcmd dependencies
RUN apt-get update && apt-get -y install lib32gcc1 lib32stdc++6 nano wget
# install steamcmd
RUN mkdir -p /steam/steamcmd
COPY steam_install.sh /steam/steamcmd
WORKDIR /steam/steamcmd
RUN /bin/bash ./steam_install.sh
# install half-life dedicated server
# for some reason we have to run app_update twice to be succesful, the first install fails with "app state 0x6"
RUN ./steamcmd.sh +login anonymous +force_install_dir /steam/hlds +app_update 90 validate +app_update 90 validate +quit
# fixes/workarounds
RUN mkdir -p ~/.steam
RUN ln -s /steam/steamcmd/linux32 ~/.steam/sdk32
# expose ports
# VAC
EXPOSE 26900/udp
# Game data
EXPOSE 27015/udp
# RCON
EXPOSE 27015
# HLTV
EXPOSE 27020/udp
# for nano to work
ENV TERM xterm
WORKDIR /steam/hlds
# create some sensible default configuration
COPY addons_maps.tar.gz /steam/hlds
COPY config.tar.gz /steam/hlds
COPY config_install.sh /steam/hlds
RUN /bin/bash ./config_install.sh
# run half-life dedicated server
CMD ["./hlds_run", "-game", "valve"]