fix(docker): move data dir chown after COPY to fix EACCES permission error
This commit is contained in:
parent
5fc77fbf8c
commit
9c757ff7d2
1 changed files with 3 additions and 3 deletions
|
|
@ -18,14 +18,14 @@ ENV PORT=20128
|
||||||
ENV HOSTNAME=0.0.0.0
|
ENV HOSTNAME=0.0.0.0
|
||||||
ENV NEXT_TELEMETRY_DISABLED=1
|
ENV NEXT_TELEMETRY_DISABLED=1
|
||||||
|
|
||||||
# Runtime writable location for localDb when DATA_DIR is configured to /app/data
|
|
||||||
RUN mkdir -p /app/data && chown node:node /app/data
|
|
||||||
|
|
||||||
COPY --from=builder /app/public ./public
|
COPY --from=builder /app/public ./public
|
||||||
COPY --from=builder /app/.next/static ./.next/static
|
COPY --from=builder /app/.next/static ./.next/static
|
||||||
COPY --from=builder /app/.next/standalone ./
|
COPY --from=builder /app/.next/standalone ./
|
||||||
COPY --from=builder /app/open-sse ./open-sse
|
COPY --from=builder /app/open-sse ./open-sse
|
||||||
|
|
||||||
|
# Runtime writable location for localDb — must be AFTER COPY to avoid permission overwrite
|
||||||
|
RUN mkdir -p /app/data && chown node:node /app/data
|
||||||
|
|
||||||
USER node
|
USER node
|
||||||
|
|
||||||
EXPOSE 20128
|
EXPOSE 20128
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue