-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathDockerfile-x86_64
More file actions
52 lines (41 loc) · 1.76 KB
/
Dockerfile-x86_64
File metadata and controls
52 lines (41 loc) · 1.76 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
FROM bitnami/dotnet-sdk:6 AS builder
COPY SAPISpeechServer/ /project
WORKDIR /project
RUN DOTNET_CLI_TELEMETRY_OPTOUT=1 \
dotnet publish --runtime win-x86 -c Release -o /app
###############################################
MAINTAINER Davide Depau <davide@depau.eu>
FROM scottyhardy/docker-wine:stable-8.0.2
EXPOSE 5000
ARG TINI_VERSION=v0.19.0
ADD https://github.com/krallin/tini/releases/download/${TINI_VERSION}/tini /tini
RUN chmod +x /tini && \
export DEBIAN_FRONTEND=noninteractive && \
apt-get update && \
apt-get install -y x11-utils
ENV WINEARCH=win32 \
XVFB_SCREEN=0 \
XVFB_RESOLUTION="320x240x8" \
DISPLAY=":95"
RUN useradd -m -d /home/wineuser -s /bin/bash --uid 1000 wineuser && \
mkdir /tmp/.X11-unix && \
chmod 1777 /tmp/.X11-unix && \
# Avoid abusing archive.org's bandwidth for speechsdk
sed -e 's|https://web.archive.org/web/20110805062427/||g' \
-e 's|https://web.archive.org/web/2000/https://web.archive.org/web/20110805062427/||g' \
-e 's|520aa5d1a72dc6f41dc9b8b88603228ffd5d5d6f696224fc237ec4828fe7f6e0|826ba6df0d38d29560250dc697a0cb53cd57817db1b39c575ee0f31ba78386ba|g' \
-i $(which winetricks) && \
# Make sure the next Dockerfile RUN statement uses bash \
mv /bin/sh /bin/sh.old && \
ln -s /bin/bash /bin/sh
USER wineuser
COPY scripts/auto_xvfb.sh /usr/bin/auto_xvfb
COPY scripts/docker_entrypoint.sh /usr/bin/entrypoint
RUN --mount=type=cache,uid=1000,target=/home/wineuser/.cache \
source auto_xvfb && \
winetricks unattended win10 nocrashdialog dotnet6 speechsdk && \
winetricks win10 && \
rm -rf /tmp/winetricks*
COPY --from=builder /app/ /app/
ENTRYPOINT ["/tini", "--", "/usr/bin/entrypoint", "wine", "/app/SAPISpeechServer.exe"]
CMD ["--urls", "http://0.0.0.0:5000"]