This repository has been archived by the owner on Mar 4, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
90 lines (78 loc) · 2.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
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
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
FROM archlinux:multilib-devel
# Install prerequisites
RUN pacman --noconfirm -Syu
RUN pacman --noconfirm -S \
wine \
winetricks \
wine-gecko \
wine-mono \
xorg-server-xvfb \
samba \
lib32-gnutls \
gnutls \
lib32-libxcomposite \
libxcomposite \
unzip \
curl
# Custom Environment Variables
ENV PUID=99 \
PGID=100 \
TZ=UTC \
MULTITHREADING=false \
PORT= \
PUBLIC_PORT= \
PUBLIC_IP= \
SERVER_NAME= \
SERVER_DESCRIPTION= \
SERVER_PASSWORD= \
ADMIN_PASSWORD= \
UPDATE_ON_BOOT=true \
WINETRICKS_ON_BOOT=true \
RCON_ENABLED=true \
BACKUP_ENABLED=true \
OLD_BACKUP_DAYS=30 \
DELETE_OLD_BACKUPS=false \
COMMUNITY=
# Install Supercronic
# Latest releases available at https://github.com/aptible/supercronic/releases
ENV SUPERCRONIC_URL=https://github.com/aptible/supercronic/releases/download/v0.2.29/supercronic-linux-amd64 \
SUPERCRONIC=supercronic-linux-amd64 \
SUPERCRONIC_SHA1SUM=cd48d45c4b10f3f0bfdd3a57d054cd05ac96812b
RUN curl -fsSLO "$SUPERCRONIC_URL" \
&& echo "${SUPERCRONIC_SHA1SUM} ${SUPERCRONIC}" | sha1sum -c - \
&& chmod +x "$SUPERCRONIC" \
&& mv "$SUPERCRONIC" "/usr/local/bin/${SUPERCRONIC}" \
&& ln -s "/usr/local/bin/${SUPERCRONIC}" /usr/local/bin/supercronic
# Install Tini
ARG TINI_VERSION=0.19.0
ADD https://github.com/krallin/tini/releases/download/v${TINI_VERSION}/tini /tini
RUN chmod +x /tini
# Install Gosu
ADD https://github.com/tianon/gosu/releases/download/1.9/gosu-amd64 /gosu
RUN chmod +x /gosu
# Setup a Wine prefix
ENV WINEPREFIX=/app/.wine
ENV WINEARCH=win64
# Change Winetricks cache directory
ENV XDG_CACHE_HOME=/app/.cache
# Configure locale for unicode
RUN echo "en_US.UTF-8 UTF-8" >> /etc/locale.gen
ENV LANG=en_US.UTF-8
RUN locale-gen
# Setup Environment
RUN mkdir -p /config
COPY start.sh /
COPY entrypoint.sh /
COPY cronlist /config
COPY backup.sh /config
EXPOSE 8211/udp
EXPOSE 25575
EXPOSE 27015
VOLUME /app
VOLUME /backup
ENV DISPLAY :99
# Setup User/Group
RUN groupadd --gid $PGID pal && \
useradd --uid $PUID --gid $PGID -M pal
# Run the application
ENTRYPOINT ["/tini","/entrypoint.sh"]