优化访问路径,使用index.html作为默认页面

- 将 linear-workflow.html 重命名为 index.html
- 更新所有配置文件和文档中的引用
- 现在可以直接访问 http://127.0.0.1:5175/
- 添加端口占用检查和自动处理功能
- 简化用户访问体验
This commit is contained in:
KQL
2025-08-24 14:20:37 +08:00
parent e8fd104bf7
commit 6af4efbabc
7 changed files with 54 additions and 23 deletions

View File

@@ -24,7 +24,7 @@ cd agent
quick-start.bat
```
项目将自动在 `http://127.0.0.1:5175` 启动,并打开 `linear-workflow.html` 页面
项目将自动在 `http://127.0.0.1:5175/` 启动
---
@@ -73,9 +73,9 @@ npm run serve
### 5. 访问应用
在浏览器中访问:`http://127.0.0.1:5175/linear-workflow.html`
在浏览器中访问:`http://127.0.0.1:5175/`
或者如果使用 `npm run dev`,浏览器会自动打开
使用 `npm run dev` 会自动打开浏览器
---
@@ -95,12 +95,12 @@ cd agent
python -m SimpleHTTPServer 5175
```
访问:`http://127.0.0.1:5175/linear-workflow.html`
访问:`http://127.0.0.1:5175/`
### 使用 Live Server (VS Code)
1. 在 VS Code 中安装 Live Server 扩展
2. 右键点击 `linear-workflow.html`
2. 右键点击 `index.html`
3. 选择 "Open with Live Server"
4. 修改端口为 5175可选
@@ -132,7 +132,7 @@ docker run -p 5175:5175 ai-agent-workflow
```json
{
"scripts": {
"dev": "npx http-server -p 你的端口 -a 127.0.0.1 -o /linear-workflow.html",
"dev": "npx http-server -p 你的端口 -a 127.0.0.1 -o",
"serve": "npx http-server -p 你的端口 -a 127.0.0.1"
}
}
@@ -144,7 +144,7 @@ docker run -p 5175:5175 ai-agent-workflow
```json
{
"scripts": {
"dev": "npx http-server -p 5175 -a 0.0.0.0 -o /linear-workflow.html",
"dev": "npx http-server -p 5175 -a 0.0.0.0 -o",
"serve": "npx http-server -p 5175 -a 0.0.0.0"
}
}
@@ -218,7 +218,7 @@ server {
server_name 127.0.0.1;
root /path/to/agent;
index linear-workflow.html;
index index.html;
location / {
try_files $uri $uri/ =404;