-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathDockerfile
More file actions
53 lines (39 loc) · 1.31 KB
/
Dockerfile
File metadata and controls
53 lines (39 loc) · 1.31 KB
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
FROM eclipse-temurin:25-jre AS runner
USER root
LABEL maintainer=Aquerr
# Intall SteamCMD
RUN apt-get -y update \
&& apt-get -y install lib32gcc-s1 \
&& apt-get -y install curl \
&& mkdir /steamcmd \
&& cd /steamcmd \
&& curl -sqL "https://steamcdn-a.akamaihd.net/client/installer/steamcmd_linux.tar.gz" | tar zxvf -
# Intall ASWG
RUN groupadd --gid 1001 aswg \
&& useradd --home-dir /home/aswg --create-home --uid 1001 --gid 1001 aswg \
&& mkdir /aswg \
&& mkdir /aswg/config \
&& mkdir /aswg/data \
&& mkdir /aswg/arma-server/ \
&& mkdir /aswg/arma-server/mods \
&& chown aswg:aswg -R /aswg \
&& chown aswg:aswg -R /steamcmd
WORKDIR /aswg
COPY ./target/arma-server-web-gui-*.jar /aswg/aswg.jar
COPY entrypoint.sh /entrypoint.sh
RUN chmod +x /entrypoint.sh
# ASWG Properties
ENV ASWG_STEAMCMD_PATH="/steamcmd/steamcmd.sh"
ENV ASWG_MODSDIRECTORYPATH="./mods"
ENV ASWG_SERVERDIRECTORYPATH="./arma-server"
ENV ASWG_CONFIG_DIR="./config"
ENV LANG="en_US.UTF-8"
ENV LANGUAGE="en_US:en"
ENV LC_ALL="en_US.UTF-8"
HEALTHCHECK --interval=2m --timeout=5s --retries=3 \
CMD curl -f http://localhost:8085/api/v1/actuator/health || exit 1
VOLUME ["/aswg/arma-server", "/aswg/data", "/aswg/config"]
EXPOSE 8085/tcp
EXPOSE 2302-2306/udp
USER aswg:aswg
ENTRYPOINT ["sh", "/entrypoint.sh"]