From ff0573703fe426c44f3d33bbfe9ed3960324479a Mon Sep 17 00:00:00 2001 From: Julia McGhee Date: Sat, 21 Mar 2026 20:35:09 +0000 Subject: [PATCH] Fix harness Dockerfile standalone paths for monorepo workspace build Next.js standalone output nests server.js under apps/harness/ when built from a pnpm workspace. Preserve the directory structure and update CMD to point to the correct server.js path. --- apps/harness/Dockerfile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/apps/harness/Dockerfile b/apps/harness/Dockerfile index 87d6a00..03b4d05 100644 --- a/apps/harness/Dockerfile +++ b/apps/harness/Dockerfile @@ -37,10 +37,10 @@ RUN adduser --system --uid 1001 nextjs # Workspace directory for git worktrees (ephemeral) RUN mkdir -p /data/harness && chown nextjs:nodejs /data/harness -COPY --from=builder /app/apps/harness/public ./public +COPY --from=builder /app/apps/harness/public ./apps/harness/public COPY --from=builder --chown=nextjs:nodejs /app/apps/harness/.next/standalone ./ -COPY --from=builder --chown=nextjs:nodejs /app/apps/harness/.next/static ./.next/static +COPY --from=builder --chown=nextjs:nodejs /app/apps/harness/.next/static ./apps/harness/.next/static USER nextjs EXPOSE 3100 ENV PORT=3100 -CMD ["node", "server.js"] +CMD ["node", "apps/harness/server.js"]