# 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"]