forked from dirtboll/winebox64
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathDockerfile
67 lines (55 loc) · 1.71 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
FROM debian:bookworm-slim
ARG DEBIAN_FRONTEND="noninteractive"
ARG TARGETPLATFORM
# To suppress the Wine debug messages
ENV WINEDEBUG=-all
# To suppress Box86's info banner to avoid winetricks to crash
ENV BOX86_NOBANNER=1
# Install additional tools
RUN apt-get update \
&& apt-get install --yes --no-install-recommends wget curl ca-certificates gnupg
# `cabextract` is needed by winetricks to install most libraries
# `xvfb` is needed in wine to spawn display window because some Windows program can't run without it (using `xvfb-run`)
# If you are sure you don't need it, feel free to remove
RUN apt install --yes cabextract xvfb
# Install box86 and box64
COPY install-box.sh /
RUN bash /install-box.sh \
&& rm /install-box.sh
# Install wine, wine64, and winetricks
COPY install-wine.sh /
RUN bash /install-wine.sh \
&& rm /install-wine.sh
# Install box wrapper for wine
COPY wrap-wine.sh /
RUN bash /wrap-wine.sh \
&& rm /wrap-wine.sh
# Clean up
RUN apt-get -y autoremove \
&& apt-get clean autoclean \
&& rm -rf /tmp/* /var/tmp/* /var/lib/apt/lists
# Add user and group
RUN groupadd group \
&& useradd -m -g group user \
&& usermod -a -G audio user \
&& usermod -a -G video user \
&& chsh -s /bin/bash user \
&& echo 'User Created'
# Initialise wine
RUN mv /root/wine /home/user/ \
&& chown -R user:group /home/user/ \
&& su user -c 'wine wineboot' \
\
# wintricks
&& su user -c 'winetricks -q msls31' \
&& su user -c 'winetricks -q ole32' \
&& su user -c 'winetricks -q riched20' \
&& su user -c 'winetricks -q riched30' \
&& su user -c 'winetricks -q win7' \
\
# Clean
&& rm -fr /home/user/{.cache,tmp}/* \
&& rm -fr /tmp/* \
&& echo 'Wine Initialized'
ENTRYPOINT ["bash", "-c"]
CMD ["bash"]