fix: change appuser to uid:gid 1000:1000 for security

- Use standard user uid:gid 1000:1000 instead of 100:101 (postfix:crontab)
- Add user override in docker-compose.yml to ensure consistent uid:gid
- Prevents .env files from having system service account permissions
- Addresses critical security concern in issue #109
This commit is contained in:
courtmanr@gmail.com
2025-06-01 21:40:04 +01:00
parent c17ca8747d
commit 69f0009d2d
2 changed files with 3 additions and 2 deletions
+2 -2
View File
@@ -28,8 +28,8 @@ FROM node:18-alpine
WORKDIR /usr/src/app
# Create a non-root user and group
RUN addgroup -S appgroup && adduser -S appuser -G appgroup
# Create a non-root user and group with uid:gid 1000:1000 (standard user)
RUN addgroup -g 1000 appgroup && adduser -u 1000 -G appgroup -s /bin/sh -D appuser
# Copy necessary files from builder stage
# Copy node_modules first (can be large)
+1
View File
@@ -7,6 +7,7 @@ services:
# image: rcourtman/pulse:latest # Use the pre-built image from Docker Hub
container_name: pulse
restart: unless-stopped
user: "1000:1000" # Run as standard user, not system service accounts
ports:
# Map container port 7655 to host port 7655
# You can change the host port (left side) if 7655 is already in use on your host