Fix harness crash: move server.js into standalone app dir
All checks were successful
CI / lint-and-test (push) Successful in 29s
Deploy Production / deploy (push) Successful in 1m29s
CI / build (push) Successful in 1m49s

server.js requires 'next', which the standalone output places at
apps/harness/node_modules/next. Running server.js from the repo root
meant Node couldn't resolve it. Move server.js and pty-server.js into
apps/harness/ so module resolution finds the standalone node_modules.
This commit is contained in:
Julia McGhee
2026-03-21 21:33:49 +00:00
parent 53b9cd826a
commit 4b517958aa

View File

@@ -63,10 +63,10 @@ COPY --from=builder /app/apps/harness/dist/mcp-server.mjs ./apps/harness/dist/mc
# PTY server dependencies + custom server
COPY --from=builder /app/node_modules/.pnpm/node-pty*/node_modules/node-pty ./node_modules/node-pty
COPY --from=builder /app/node_modules/.pnpm/ws*/node_modules/ws ./node_modules/ws
COPY apps/harness/server.js ./server.js
COPY apps/harness/pty-server.js ./pty-server.js
COPY apps/harness/server.js ./apps/harness/server.js
COPY apps/harness/pty-server.js ./apps/harness/pty-server.js
USER nextjs
EXPOSE 3100
ENV PORT=3100
CMD ["node", "server.js"]
CMD ["node", "apps/harness/server.js"]