quite / Dockerfile
slimshadow's picture
Update Dockerfile
f9632f1 verified
raw
history blame contribute delete
897 Bytes
# Use an Ubuntu base image
FROM ubuntu:latest
# Install necessary packages
RUN apt-get update && \
apt-get install -y qutebrowser x11vnc xvfb && \
apt-get clean && \
rm -rf /var/lib/apt/lists/*
# Add a user with a unique UID
RUN useradd -m -u 65506 user
USER user
# Set the working directory
WORKDIR /home/user
# Set environment variables for X11 and other necessary settings
ENV DISPLAY=:1
ENV XDG_RUNTIME_DIR=/tmp/runtime-user
ENV QT_XCB_FORCE_SOFTWARE_OPENGL=1
# Create necessary directories with appropriate permissions
RUN mkdir -p /tmp/.X11-unix && chmod 1777 /tmp/.X11-unix
RUN mkdir -p /tmp/runtime-user && chmod 700 /tmp/runtime-user
# Start the X virtual framebuffer and VNC server, then run qutebrowser
CMD ["sh", "-c", "Xvfb :1 -screen 0 1024x768x16 & x11vnc -display :1 -nopw -listen localhost -xkb -forever & qutebrowser --backend webengine http://localhost:7860"]