Files
biliup-next/frontend/vite.config.mjs
2026-04-01 00:44:58 +08:00

35 lines
572 B
JavaScript

import { defineConfig } from "vite";
import react from "@vitejs/plugin-react";
const proxiedPaths = [
"/health",
"/doctor",
"/tasks",
"/settings",
"/runtime",
"/history",
"/logs",
"/modules",
"/scheduler",
"/worker",
"/stage",
];
export default defineConfig({
base: "/ui/",
plugins: [react()],
server: {
host: "0.0.0.0",
port: 5173,
proxy: Object.fromEntries(
proxiedPaths.map((path) => [
path,
{
target: "http://127.0.0.1:8787",
changeOrigin: false,
},
]),
),
},
});