From bbce5b29281a4647aeeecb2153121616a25514d0 Mon Sep 17 00:00:00 2001 From: Vishal Jain Date: Wed, 18 Jun 2025 12:23:40 +0100 Subject: [PATCH] Fix CLAUDE.md copy during Docker build Copy CLAUDE.md directly to final location instead of using /tmp intermediate step. This ensures the COPY fails loudly if there's an issue and simplifies the build process. --- Dockerfile | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/Dockerfile b/Dockerfile index f2a7ec6..cfd0b2d 100644 --- a/Dockerfile +++ b/Dockerfile @@ -50,19 +50,18 @@ RUN chmod +x /app/startup.sh # This enables one-time setup - no need for .env in project directories COPY .env /app/.env -# Copy CLAUDE.md template to user's .claude directory -COPY templates/.claude/CLAUDE.md /tmp/CLAUDE.md +# Copy CLAUDE.md template directly to final location +COPY templates/.claude/CLAUDE.md /home/claude-user/.claude/CLAUDE.md # Copy Claude authentication files from host # Note: These must exist - host must have authenticated Claude Code first COPY .claude.json /tmp/.claude.json COPY .claude /tmp/.claude -# Move auth files and CLAUDE.md template to proper location before switching user +# Move auth files to proper location before switching user RUN cp /tmp/.claude.json /home/claude-user/.claude.json && \ cp -r /tmp/.claude/* /home/claude-user/.claude/ && \ - cp /tmp/CLAUDE.md /home/claude-user/.claude/CLAUDE.md && \ - rm -rf /tmp/.claude* /tmp/CLAUDE.md + rm -rf /tmp/.claude* # Set proper ownership for everything RUN chown -R claude-user:claude-user /app /home/claude-user