Skip to content

Commit 7e20f84

Browse files
committed
fix(docker): set migrations dir permissions to 755 on COPY
Docker COPY preserves build-host file permissions. On hosts with a restrictive umask (e.g. 0027), the migrations directory is copied as 750 root:root, making it unreadable by the openshell user at runtime and causing the server to crash with a permission denied error on startup. Using --chmod=755 ensures the directory is always world-readable regardless of the build host umask. Signed-off-by: Evan Lezar <elezar@nvidia.com>
1 parent 4878b9b commit 7e20f84

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

deploy/docker/Dockerfile.images

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ WORKDIR /app
168168
COPY --from=gateway-builder /build/out/openshell-server /usr/local/bin/
169169

170170
RUN mkdir -p /build/crates/openshell-server
171-
COPY crates/openshell-server/migrations /build/crates/openshell-server/migrations
171+
COPY --chmod=755 crates/openshell-server/migrations /build/crates/openshell-server/migrations
172172

173173
USER openshell
174174
EXPOSE 8080

0 commit comments

Comments
 (0)