# syntax=docker/dockerfile:1.7 # Bakes ui/dist at image build time so `docker compose up` never runs # `npm ci` against the public registry (US-048 AC3: second up works offline). FROM node:24-alpine AS build WORKDIR /src # prebuild runs openapi-typescript against ../docs/openapi.yaml, so it must # sit at /../docs/openapi.yaml (re-included in .dockerignore). COPY docs/openapi.yaml docs/openapi.yaml # Dependency layer first: a UI-only change reuses the npm ci layer. COPY ui/package.json ui/package-lock.json ui/ RUN cd ui && npm ci COPY ui/ ui/ RUN cd ui && npm run build FROM nginxinc/nginx-unprivileged:1.27-alpine COPY --from=build /src/ui/dist /usr/share/nginx/html # Serves compose only; Helm (W25-03) overrides default.conf via ConfigMap. COPY nginx.conf /etc/nginx/conf.d/default.conf EXPOSE 8080