Files
memind/ops/vite.config.ts
Your Name b0f5d6a51c Extract memind_adm admin server, add local dev tooling, and remove image-generation.
Split platform admin and ops APIs into standalone admin-server.mjs with network guards; simplify billing to RMB token pricing, refactor user auth, and add rsync deploy plus local-test scripts and docs.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-17 16:39:39 -07:00

27 lines
725 B
TypeScript

import { defineConfig } from 'vite';
import react from '@vitejs/plugin-react';
// /auth (login + session status) is served by the public portal; the ops
// console API (/api/ops/v1) lives in the standalone memind_adm service.
const authProxy = process.env.OPS_API_PROXY ?? 'http://127.0.0.1:8081';
const adminProxy = process.env.OPS_ADMIN_PROXY ?? 'http://127.0.0.1:8082';
export default defineConfig({
base: '/ops/',
plugins: [react()],
server: {
host: '0.0.0.0',
port: 3002,
allowedHosts: ['127.0.0.1', 'localhost', '.localhost'],
proxy: {
'/admin-api': adminProxy,
'/api': adminProxy,
'/auth': authProxy,
},
},
build: {
outDir: 'dist',
emptyOutDir: true,
},
});