- Debian-based api image (bookworm-slim), docker/debian mirrors, prisma binaryTargets for openssl 3.0 - nginx: admin SPA under /admin, TLS via acme.sh (ZeroSSL) + auto-renewal cron, http->https redirect - prisma: add origin_goods.delisted migration, sync missing schema (good_image/tag_font_color/good_tags), fix users.createdAt Timestamptz - api: CORS wildcard reflection, helmet CORP cross-origin, price backfill in persistProductDetail, categoryIcon ancestor fallback, mediaByColor per-color gallery in public goods detail - admin: /admin base path (vite + router) - import-data.mjs: udt_name casting, serial sequence advance fix
22 lines
769 B
Docker
22 lines
769 B
Docker
# InkReach Admin - Vite build served by nginx
|
|
FROM node:20-alpine AS build
|
|
WORKDIR /app
|
|
RUN corepack enable
|
|
ENV NPM_CONFIG_REGISTRY=https://registry.npmmirror.com COREPACK_NPM_REGISTRY=https://registry.npmmirror.com
|
|
|
|
ARG VITE_API_BASE=/api
|
|
ENV VITE_API_BASE=$VITE_API_BASE
|
|
|
|
COPY package.json pnpm-lock.yaml pnpm-workspace.yaml turbo.json ./
|
|
COPY apps/admin/package.json apps/admin/
|
|
RUN pnpm install --filter @inkreach/admin --frozen-lockfile
|
|
|
|
COPY apps/admin apps/admin
|
|
# vue-tsc full check is skipped: pre-existing type errors unrelated to the build output
|
|
RUN pnpm --filter @inkreach/admin exec vite build
|
|
|
|
FROM nginx:1.27-alpine
|
|
COPY --from=build /app/apps/admin/dist /usr/share/nginx/html/admin
|
|
COPY deploy/nginx/admin.conf /etc/nginx/conf.d/default.conf
|
|
EXPOSE 80
|