This commit is contained in:
Siddharth Ganesan
2026-04-04 13:06:45 -07:00
parent feb1c88d2f
commit 8c09e19293
3 changed files with 10 additions and 3 deletions

View File

@@ -91,7 +91,12 @@ const nextConfig: NextConfig = {
],
outputFileTracingIncludes: {
'/api/tools/stagehand/*': ['./node_modules/ws/**/*'],
'/*': ['./node_modules/sharp/**/*', './node_modules/@img/**/*', './dist/pptx-worker.cjs'],
'/*': [
'./node_modules/sharp/**/*',
'./node_modules/@img/**/*',
'./dist/pptx-worker.cjs',
'./dist/doc-worker.cjs',
],
},
experimental: {
optimizeCss: true,

View File

@@ -12,8 +12,9 @@
"dev:webpack": "next dev --webpack",
"dev:sockets": "bun run socket/index.ts",
"dev:full": "bunx concurrently -n \"App,Realtime\" -c \"cyan,magenta\" \"bun run dev\" \"bun run dev:sockets\"",
"build": "bun run build:pptx-worker && next build",
"build": "bun run build:pptx-worker && bun run build:doc-worker && next build",
"build:pptx-worker": "bun build ./lib/execution/pptx-worker.cjs --target=node --format=cjs --outfile ./dist/pptx-worker.cjs",
"build:doc-worker": "bun build ./lib/execution/doc-worker.cjs --target=node --format=cjs --outfile ./dist/doc-worker.cjs",
"start": "next start",
"prepare": "cd ../.. && bun husky",
"test": "vitest run",

View File

@@ -116,8 +116,9 @@ COPY --from=deps --chown=nextjs:nodejs /app/node_modules/isolated-vm ./node_modu
# Copy the isolated-vm worker script
COPY --from=builder --chown=nextjs:nodejs /app/apps/sim/lib/execution/isolated-vm-worker.cjs ./apps/sim/lib/execution/isolated-vm-worker.cjs
# Copy the bundled PPTX worker artifact
# Copy the bundled worker artifacts
COPY --from=builder --chown=nextjs:nodejs /app/apps/sim/dist/pptx-worker.cjs ./apps/sim/dist/pptx-worker.cjs
COPY --from=builder --chown=nextjs:nodejs /app/apps/sim/dist/doc-worker.cjs ./apps/sim/dist/doc-worker.cjs
# Guardrails setup with pip caching
COPY --from=builder --chown=nextjs:nodejs /app/apps/sim/lib/guardrails/requirements.txt ./apps/sim/lib/guardrails/requirements.txt