/
VVRONGG
/
backside
Обзор
Документация
Войти
/
VVRONGG
/
backside
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
1
CI/CD
Аналитика
Безопасность
master
admin/Dockerfile
21 строка
816 B
VVrongg
add kubec deploy
24 май 2026, 20:16
24 май 2026, 20:16
db9ffee
Код
Авторство
О чём код?
# --- build stage ------------------------------------------------------------- FROM node:20-alpine AS build WORKDIR /app COPY package.json package-lock.json ./ RUN npm ci COPY . . # Same-origin API: BASE becomes '' after the trailing slash is stripped (see api.ts), # so the SPA calls /auth/login, /objectives/... at the domain root regardless of the # /admin path it is served from. `vite build` also sets base=/admin/ (vite.config.ts). ARG VITE_API_BASE=/ ENV VITE_API_BASE=$VITE_API_BASE RUN npm run build # --- runtime stage ----------------------------------------------------------- FROM nginx:1.27-alpine COPY nginx.conf /etc/nginx/conf.d/default.conf # Built assets reference /admin/... (Vite base), so serve them from a matching subdir. COPY --from=build /app/dist /usr/share/nginx/html/admin EXPOSE 80