첫 커밋: 로컬 프로젝트 업로드
This commit is contained in:
43
baron-sso/adminfront/vite.config.ts
Normal file
43
baron-sso/adminfront/vite.config.ts
Normal file
@@ -0,0 +1,43 @@
|
||||
import react from "@vitejs/plugin-react";
|
||||
import path from "path";
|
||||
import { defineConfig } from "vite";
|
||||
|
||||
const buildOutDir =
|
||||
process.env.ADMINFRONT_BUILD_OUT_DIR ?? "/tmp/baron-sso-adminfront-dist";
|
||||
|
||||
export default defineConfig({
|
||||
plugins: [react()],
|
||||
resolve: {
|
||||
alias: {
|
||||
"lucide-react": path.resolve(process.cwd(), "node_modules/lucide-react"),
|
||||
react: path.resolve(process.cwd(), "node_modules/react"),
|
||||
"react-dom": path.resolve(process.cwd(), "node_modules/react-dom"),
|
||||
},
|
||||
dedupe: ["react", "react-dom", "react-router-dom"],
|
||||
},
|
||||
cacheDir:
|
||||
process.env.ADMINFRONT_VITE_CACHE_DIR ??
|
||||
"/tmp/baron-sso-adminfront-vite-cache",
|
||||
envPrefix: ["VITE_", "USERFRONT_", "ORGFRONT_"],
|
||||
build: {
|
||||
outDir: buildOutDir,
|
||||
},
|
||||
server: {
|
||||
host: "127.0.0.1",
|
||||
proxy: {
|
||||
"/api": {
|
||||
target: process.env.API_PROXY_TARGET || "http://localhost:3000",
|
||||
changeOrigin: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
preview: {
|
||||
host: "127.0.0.1",
|
||||
proxy: {
|
||||
"/api": {
|
||||
target: process.env.API_PROXY_TARGET || "http://localhost:3000",
|
||||
changeOrigin: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
Reference in New Issue
Block a user