aboutsummaryrefslogtreecommitdiff
path: root/docker/Dockerfile
diff options
context:
space:
mode:
authorStefan Boberg <[email protected]>2026-03-16 10:56:11 +0100
committerGitHub Enterprise <[email protected]>2026-03-16 10:56:11 +0100
commit8c3ba4e8c522d119df3cb48966e36c0eaa80aeb9 (patch)
treecf51b07e097904044b4bf65bc3fe0ad14134074f /docker/Dockerfile
parentMerge branch 'sb/no-network' of https://github.ol.epicgames.net/ue-foundation... (diff)
parentEnable cross compilation of Windows targets on Linux (#839) (diff)
downloadzen-sb/no-network.tar.xz
zen-sb/no-network.zip
Merge branch 'main' into sb/no-networksb/no-network
Diffstat (limited to 'docker/Dockerfile')
-rw-r--r--docker/Dockerfile55
1 files changed, 55 insertions, 0 deletions
diff --git a/docker/Dockerfile b/docker/Dockerfile
new file mode 100644
index 000000000..060042d85
--- /dev/null
+++ b/docker/Dockerfile
@@ -0,0 +1,55 @@
+# Copyright Epic Games, Inc. All Rights Reserved.
+#
+# Runtime image for zenserver compute workers.
+#
+# Build variants:
+# With Wine (for running Windows worker executables via WineProcessRunner):
+# docker build -t zenserver-compute -f docker/Dockerfile .
+#
+# Without Wine (Linux-only workers, smaller image):
+# docker build -t zenserver-compute --build-arg INSTALL_WINE=false -f docker/Dockerfile .
+#
+# The build context must contain the pre-built Linux zenserver binary at:
+# build/linux/x86_64/release/zenserver
+
+FROM ubuntu:24.04
+
+# Avoid interactive prompts during package installation
+ENV DEBIAN_FRONTEND=noninteractive
+
+# Set to "false" to skip Wine installation and produce a smaller image
+ARG INSTALL_WINE=true
+
+# Install WineHQ (only when INSTALL_WINE=true)
+# Enables i386 architecture required for Wine32 support
+RUN if [ "$INSTALL_WINE" = "true" ]; then \
+ dpkg --add-architecture i386 \
+ && apt-get update \
+ && apt-get install -y --no-install-recommends \
+ ca-certificates \
+ gnupg \
+ wget \
+ && wget -qO- https://dl.winehq.org/wine-builds/winehq.key \
+ | gpg --dearmor -o /usr/share/keyrings/winehq-archive.key \
+ && echo "deb [signed-by=/usr/share/keyrings/winehq-archive.key] https://dl.winehq.org/wine-builds/ubuntu/ noble main" \
+ > /etc/apt/sources.list.d/winehq.list \
+ && apt-get update \
+ && apt-get install -y --no-install-recommends winehq-stable \
+ && apt-get remove -y gnupg wget \
+ && apt-get autoremove -y \
+ && rm -rf /var/lib/apt/lists/* ; \
+ fi
+
+# Copy the pre-built zenserver binary
+COPY build/linux/x86_64/release/zenserver /opt/zenserver/zenserver
+RUN chmod +x /opt/zenserver/zenserver
+
+# Optional: Windows zenserver binary for Wine-based compute workers.
+# Set WIN_BINARY_DIR to a directory containing zenserver.exe to include it.
+# Defaults to docker/empty (an empty placeholder) so the COPY is a no-op.
+ARG WIN_BINARY_DIR=docker/empty
+COPY ${WIN_BINARY_DIR}/ /opt/zenserver/
+
+EXPOSE 8558
+
+ENTRYPOINT ["/opt/zenserver/zenserver"]