XuqmGroup-Web/Dockerfile
XuqmGroup dadedbc4df feat: add VitePress docs-site with full SDK integration guides
- Add docs-site workspace (VitePress 1.5.0) with Android/iOS/RN/Vue3/HarmonyOS/Server docs
- Update Dockerfile to build and serve docs under /docs/
- Add /docs/ location block to Nginx config
- Add docs-site to yarn workspaces

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-24 15:35:24 +08:00

30 行
922 B
Docker

FROM node:22-alpine AS build
WORKDIR /workspace
COPY package.json ./package.json
COPY yarn.lock ./yarn.lock
COPY tenant-platform ./tenant-platform
COPY ops-platform ./ops-platform
COPY docs-site ./docs-site
RUN yarn install --frozen-lockfile
ARG TENANT_APP_BASE=/
ARG OPS_APP_BASE=/ops/
ARG TENANT_API_BASE_URL=/api
ARG OPS_API_BASE_URL=/api
RUN cd tenant-platform && \
VITE_APP_BASE=${TENANT_APP_BASE} VITE_API_BASE_URL=${TENANT_API_BASE_URL} yarn build
RUN cd ops-platform && \
VITE_APP_BASE=${OPS_APP_BASE} VITE_API_BASE_URL=${OPS_API_BASE_URL} yarn build
RUN cd docs-site && yarn build
FROM nginx:1.27-alpine
COPY nginx/default.conf /etc/nginx/conf.d/default.conf
COPY --from=build /workspace/tenant-platform/dist /usr/share/nginx/html/tenant
COPY --from=build /workspace/ops-platform/dist /usr/share/nginx/html/ops
COPY --from=build /workspace/docs-site/docs/.vitepress/dist /usr/share/nginx/html/docs