安装与配置

安装与配置

本文档介绍如何安装和配置 NanxuDocs。

环境要求

  • Node.js 18+
  • Go 1.20+
  • Docker(可选)

安装步骤

1. 克隆项目

git clone https://github.com/your-repo/nanxu.git
cd nanxu

2. 安装前端依赖

cd frontend
npm install

3. 启动后端

cd backend
go run main.go

4. 启动前端

cd frontend
npm run dev

配置说明

配置项说明默认值
BACKEND_URL后端服务地址http://localhost:8080
PORT前端端口3000

常见问题

提示:如果遇到端口冲突,可以通过环境变量修改端口。

PORT=4000 npm run dev

评论

(0)
登录后即可发表评论,去登录
加载评论中...
最后更新:2026/10/13