From fa7a243e95c140d82dc1c1df9a5fc6868320146e Mon Sep 17 00:00:00 2001 From: JOY Date: Sat, 19 Sep 2026 02:46:59 +0700 Subject: [PATCH] fix(docker): let the node user create the turbo cache dir The USER node switch (PR #74) crash-looped production on boot: WORKDIR creates /calcom as root-owned, so turbo could not create /calcom/.turbo and 'yarn start' (turbo run start) exited with 'Permission denied'. Pre-create the directory for the node user. Production was rolled back to the previous image while this builds. --- Dockerfile | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Dockerfile b/Dockerfile index 672a3ae9960..163d8e6bd3a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -105,6 +105,10 @@ RUN apt-get update && apt-get install -y --no-install-recommends netcat-openbsd # the tree lets the runtime write its caches (Next ISR, prisma engines) without # adding a duplicate copy-up layer that a separate chown -R would create. COPY --from=builder-two --chown=node:node /calcom ./ +# WORKDIR created /calcom itself as root-owned, so the node user cannot create +# turbo's runtime cache dir there - `yarn start` (turbo run start) died with +# "failed to create directory /calcom/.turbo" and crash-looped the container. +RUN mkdir -p /calcom/.turbo && chown node:node /calcom/.turbo ARG NEXT_PUBLIC_WEBAPP_URL=https://cal.crove.com ENV NEXT_PUBLIC_WEBAPP_URL=$NEXT_PUBLIC_WEBAPP_URL \ BUILT_NEXT_PUBLIC_WEBAPP_URL=$NEXT_PUBLIC_WEBAPP_URL