Three-stage Dockerfile: frontend-build (Node 20), api (Python 3.12 + uvicorn), web (nginx 1.27). nginx.conf proxies /api and /ws to the API service with WebSocket upgrade support. Includes backend/requirements.txt with all Python deps, frontend scaffolding (Vite + React + TypeScript + Tailwind), and placeholder alembic files for Docker COPY compatibility.
20 lines
387 B
TypeScript
20 lines
387 B
TypeScript
import { defineConfig } from "vite";
|
|
import react from "@vitejs/plugin-react";
|
|
|
|
export default defineConfig({
|
|
plugins: [react()],
|
|
build: {
|
|
outDir: "dist",
|
|
},
|
|
server: {
|
|
port: 5173,
|
|
proxy: {
|
|
"/api": "http://localhost:8000",
|
|
"/ws": {
|
|
target: "ws://localhost:8000",
|
|
ws: true,
|
|
},
|
|
"/health": "http://localhost:8000",
|
|
},
|
|
},
|
|
});
|