# Dockerfile for testing pyPhotoAlbum installation on Debian FROM debian:bookworm # Avoid interactive prompts ENV DEBIAN_FRONTEND=noninteractive # Install system dependencies (same as install-debian.sh) RUN apt-get update && apt-get install -y \ sudo \ curl \ python3 \ python3-venv \ python3-pip \ libgl1-mesa-dev \ libglu1-mesa-dev \ libxcb-xinerama0 \ libxcb-cursor0 \ libxkbcommon0 \ libdbus-1-3 \ libegl1 \ libfontconfig1 \ libfreetype6 \ libx11-6 \ libx11-xcb1 \ libxcb1 \ libxcb-glx0 \ libxcb-icccm4 \ libxcb-image0 \ libxcb-keysyms1 \ libxcb-randr0 \ libxcb-render0 \ libxcb-render-util0 \ libxcb-shape0 \ libxcb-shm0 \ libxcb-sync1 \ libxcb-xfixes0 \ libxcb-xkb1 \ libxkbcommon-x11-0 \ libglib2.0-0 \ libgtk-3-0 \ && rm -rf /var/lib/apt/lists/* # Create a non-root user for testing RUN useradd -m -s /bin/bash testuser && \ echo "testuser ALL=(ALL) NOPASSWD:ALL" >> /etc/sudoers # Copy project files WORKDIR /home/testuser/pyPhotoAlbum COPY . . # Fix ownership RUN chown -R testuser:testuser /home/testuser/pyPhotoAlbum # Switch to test user USER testuser # Create venv and install RUN python3 -m venv venv && \ ./venv/bin/pip install --upgrade pip && \ ./venv/bin/pip install -e . # Default command - run the app CMD ["./launch-pyphotoalbum.sh"]