Skip to content

Commit fc09e55

Browse files
author
Cade Schlaefli
committed
fix: add support for anyuid to Dockerfile
1 parent 7c72578 commit fc09e55

1 file changed

Lines changed: 7 additions & 1 deletion

File tree

‎Dockerfile‎

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -195,6 +195,7 @@ RUN addgroup -g $GID sourcebot && \
195195
adduser -D -u $UID -h /app -S sourcebot && \
196196
adduser sourcebot postgres && \
197197
adduser sourcebot redis && \
198+
chown -R sourcebot /app && \
198199
adduser sourcebot node && \
199200
mkdir /var/log/sourcebot && \
200201
chown sourcebot /var/log/sourcebot
@@ -244,7 +245,12 @@ RUN mkdir -p /run/postgresql && \
244245
chown -R postgres:postgres /run/postgresql && \
245246
chmod 775 /run/postgresql
246247

247-
RUN chown -R sourcebot:sourcebot /data
248+
# Make app directory accessible to both root and sourcebot user
249+
RUN chown -R sourcebot /app \
250+
&& chgrp 0 /app \
251+
&& chmod -R g=u /app
252+
# Make data directory accessible to both root and sourcebot user
253+
RUN chown -R sourcebot /data
248254

249255
COPY supervisord.conf /etc/supervisor/conf.d/supervisord.conf
250256
COPY prefix-output.sh ./prefix-output.sh

0 commit comments

Comments
 (0)