# Dedicated PR #10 acceptance layer. Reuses the production runtime image so the # tested Python/bwrap/ffmpeg/fonts/Redis stack is the real deployment stack. # It inherits the production ENTRYPOINT (tini + private outer namespace). FROM manimcat-pr10-runtime:latest USER root # The runtime image intentionally ships only the node binary. Add npm for the # test-only layer, then install Linux dev dependencies from the lockfile. COPY --from=node:22-bookworm-slim /usr/local/lib/node_modules/npm /usr/local/lib/node_modules/npm RUN ln -sf /usr/local/lib/node_modules/npm/bin/npm-cli.js /usr/local/bin/npm \ && ln -sf /usr/local/lib/node_modules/npm/bin/npx-cli.js /usr/local/bin/npx WORKDIR /app COPY package.json package-lock.json ./ COPY tsconfig.json ./ COPY config ./config COPY src ./src COPY data ./data COPY scripts ./scripts # NODE_ENV=development keeps dev dependencies; the production runtime layer's # platform-specific node_modules are replaced by this Linux install. ENV NODE_ENV=development RUN npm ci --include=dev --no-audit --no-fund \ && npm run build:backend RUN chown -R node:node /app ENV MANIMGX_PYTHON=/opt/venv/bin/python \ MATPLOTLIB_PYTHON=/opt/venv/bin/python \ PATH=/opt/venv/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin USER node WORKDIR /app