# UrBackup server + libguestfs, so the web UI can mount image backups and restore
# single files out of them. The stock image ships without guestmount, and the server
# logs "Image mounting disabled: TEST FAILED: guestmount is missing".
#
# libguestfs boots a tiny helper VM (supermin appliance) to read the VHDZ, which needs
# a kernel in /boot plus /dev/kvm and /dev/fuse at runtime (see docker-compose.yml).
# Built by .gitea/workflows/build-urbackup-server.yml → registry.ginnoir.com.
ARG URBACKUP_TAG=2.5.x
FROM uroni/urbackup-server:${URBACKUP_TAG}

RUN apt-get update \
 && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
      libguestfs-tools linux-image-amd64 supermin qemu-system-x86 \
 && rm -rf /var/lib/apt/lists/*

# Use the direct (qemu) backend; there is no libvirt in the container.
ENV LIBGUESTFS_BACKEND=direct
