Fix: EACCES on Docker bind mount

What happened

Running docker run -v $(pwd)/data:/app/data myimage gave:

PermissionError: [Errno 13] Permission denied: '/app/data/output.csv'

Root cause

UID/GID mismatch — host user (UID 1000) ≠ container user (UID 0 or different).

Fixes (safest → most invasive)

Fix 1 — SELinux label (Fedora/RHEL only)

docker run -v $(pwd)/data:/app/data:Z myimage

Fix 2 — Match UIDs

RUN useradd -u 1000 appuser
USER appuser

Fix 3 — chmod on host

chmod -R 777 ./data   # quick test only, not production

Fix 1 worked in 30 seconds. Ship Fix 2 in the Dockerfile long-term.