You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fix: Docker file permissions for non-root user (#17)
Container tests were failing with 'Permission denied' errors when trying
to read configuration files (.env, models.json) and application files.
Root cause: Files were copied as root user before switching to 'node' user,
resulting in the node user lacking read permissions.
Solution: Added explicit ownership and permission setting before USER switch:
- chown -R node:node /app - Set node as owner of all files
- chmod -R u+rw,go+r /app - Grant read/write to user, read to others
- chmod +x /app/src/server.js - Make server.js executable
This ensures consistent behavior across different Docker versions and
build environments.
All 303 tests now passing.
0 commit comments