Skip to content

Commit 9736ec4

Browse files
committed
change default uid/pid to 1000
1 parent 2c86896 commit 9736ec4

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

Dockerfile

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -49,8 +49,8 @@ ENV PYTHONUNBUFFERED=1 \
4949
PORT=8080 \
5050
DATABASE_PATH=/app/data/scriberr.db \
5151
UPLOAD_DIR=/app/data/uploads \
52-
PUID=10001 \
53-
PGID=10001
52+
PUID=1000 \
53+
PGID=1000
5454

5555
WORKDIR /app
5656

@@ -67,8 +67,8 @@ RUN curl -LsSf https://astral.sh/uv/install.sh | sh \
6767
&& uv --version
6868

6969
# Create default user (will be modified at runtime if needed)
70-
RUN groupadd -g 10001 appuser \
71-
&& useradd -m -u 10001 -g 10001 appuser \
70+
RUN groupadd -g 1000 appuser \
71+
&& useradd -m -u 1000 -g 1000 appuser \
7272
&& mkdir -p /app/data/uploads /app/data/transcripts \
7373
&& chown -R appuser:appuser /app
7474

docker-entrypoint.sh

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22
set -e
33

44
# Default values
5-
PUID=${PUID:-10001}
6-
PGID=${PGID:-10001}
5+
PUID=${PUID:-1000}
6+
PGID=${PGID:-1000}
77

88
echo "=== Scriberr Container Setup ==="
99
echo "Requested UID: $PUID, GID: $PGID"
@@ -14,7 +14,7 @@ setup_user() {
1414
local target_gid=$2
1515

1616
# Check if we need to modify the user
17-
if [ "$target_uid" != "10001" ] || [ "$target_gid" != "10001" ]; then
17+
if [ "$target_uid" != "1000" ] || [ "$target_gid" != "1000" ]; then
1818
echo "Setting up custom user with UID=$target_uid, GID=$target_gid..."
1919

2020
# Check if group already exists with different GID
@@ -36,7 +36,7 @@ setup_user() {
3636
# Update ownership of app directory
3737
chown -R "$target_uid:$target_gid" /app 2>/dev/null || true
3838
else
39-
echo "Using default user (UID=10001, GID=10001)"
39+
echo "Using default user (UID=1000, GID=1000)"
4040
fi
4141
}
4242

0 commit comments

Comments
 (0)