aura-web/README.md

1.0 KiB
Raw Blame History

aura-web

Aura Agent Platform 前端项目React + Vite + TypeScript

rh-agent-platform/web/ 拆分独立而来。后端代码现位于平级项目 aura-server

本地开发

npm install
npm run dev          # http://localhost:5173

默认 /api 代理到 http://localhost:4001(即 aura-server 的 Go 服务)。 如需切换:

VITE_API_TARGET=http://localhost:4000 npm run dev

构建

npm run build        # 产物输出至 dist/
npm run preview      # 本地预览

发布

1、本地执行

npm run build

2、本地执行上传 dist 到服务器):

rsync -avz --delete dist/ root@156.230.62.22:/var/www/aura-web/

Docker

cp .env.example .env
docker compose up -d --build
# 浏览器访问 http://localhost:8080

目录结构

src/
├── components/   公共组件
├── pages/        路由页面
├── store/        Zustand 状态
├── api.ts        REST/SSE 客户端
└── main.tsx      入口