Skip to content

Commit e2f5685

Browse files
Copilotsantib
andauthored
Fix Heroku deployment (#1272)
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: santib <6373536+santib@users.noreply.github.com>
1 parent f1c3701 commit e2f5685

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

Dockerfile

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -79,12 +79,15 @@ USER "$USERNAME"
7979
WORKDIR "$APP_HOME"
8080

8181
# Copy everything from the builder image
82-
COPY --link --chown="$USERNAME:$USERNAME" --chmod=700 . .
83-
COPY --from=builder --chown="$USERNAME:$USERNAME" --chmod=700 "$APP_HOME/public/" "$APP_HOME/public/"
84-
COPY --from=builder --chown="$USERNAME:$USERNAME" --chmod=700 "$APP_HOME/tmp/" "$APP_HOME/tmp/"
85-
COPY --from=builder --chown="$USERNAME:$USERNAME" --chmod=700 "$APP_HOME/vendor/" "$APP_HOME/vendor/"
82+
COPY --chown="$USERNAME:$USERNAME" . .
83+
COPY --from=builder --chown="$USERNAME:$USERNAME" "$APP_HOME/public/" "$APP_HOME/public/"
84+
COPY --from=builder --chown="$USERNAME:$USERNAME" "$APP_HOME/tmp/" "$APP_HOME/tmp/"
85+
COPY --from=builder --chown="$USERNAME:$USERNAME" "$APP_HOME/vendor/" "$APP_HOME/vendor/"
8686

87+
# Set permissions (700 for security) and create symlink
88+
# Note: Permissions set via RUN instead of COPY --chmod for Heroku compatibility
8789
USER root
90+
RUN chmod -R 700 "$APP_HOME"
8891
RUN ln -s /usr/lib/*-linux-gnu/libjemalloc.so.2 /usr/lib/libjemalloc.so.2
8992
USER "$USERNAME"
9093

0 commit comments

Comments
 (0)