| # syntax=docker/dockerfile:1.7 | |
| FROM node:24-bookworm@sha256:9f3b13503acdf9bc1e0213ccb25ebe86ac881cad17636733a1da1be1d44509df | |
| RUN corepack enable | |
| WORKDIR /app | |
| COPY package.json pnpm-lock.yaml pnpm-workspace.yaml ./ | |
| COPY ui/package.json ./ui/package.json | |
| COPY patches ./patches | |
| # This image only exercises the root qrcode-terminal dependency path. | |
| # Keep the pre-install copy set limited to the manifests needed for root | |
| # workspace resolution so unrelated extension edits do not bust the layer. | |
| RUN --mount=type=cache,id=openclaw-pnpm-store,target=/root/.local/share/pnpm/store,sharing=locked \ | |
| pnpm install --frozen-lockfile | |
| COPY . . | |
| RUN useradd --create-home --shell /bin/bash appuser \ | |
| && chown -R appuser:appuser /app | |
| USER appuser | |