Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ DB_NAME=claude_code_hub

# 应用配置
APP_PORT=23000
APP_URL= # 应用访问地址(留空自动检测,生产环境建议显式配置)
# 示例:https://your-domain.com 或 http://192.168.1.100:23000

# Cookie 安全策略
# 功能说明:控制是否强制 HTTPS Cookie(设置 cookie 的 secure 属性)
Expand Down
23 changes: 23 additions & 0 deletions CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -320,6 +320,9 @@ ENABLE_CODEX_INSTRUCTIONS_INJECTION=false # 是否强制替换 Codex 请求的

# 应用配置
APP_PORT=23000 # 应用端口
APP_URL= # 应用访问地址(留空自动检测,生产环境建议显式配置)
# 示例:https://your-domain.com 或 http://192.168.1.100:23000
# 用于 OpenAPI 文档的 server URL 配置
NODE_ENV=production # 环境模式
TZ=Asia/Shanghai # 时区设置
LOG_LEVEL=info # 日志级别
Expand Down Expand Up @@ -360,6 +363,26 @@ ENABLE_SECURE_COOKIES=0 # 正确:也可以用 0
- 必须设置 `ENABLE_SECURE_COOKIES=false` 才能正常使用
- 或者配置 HTTPS 反向代理(推荐)

#### OpenAPI 文档地址配置

OpenAPI 文档(`/api/actions/scalar` 和 `/api/actions/docs`)中的 server URL 配置:

**配置方式**:

- **生产环境(推荐)**:显式设置 `APP_URL` 环境变量

```bash
APP_URL=https://your-domain.com # HTTPS 域名
APP_URL=http://192.168.1.100:23000 # HTTP IP + 端口
```

- **开发环境**:留空即可,自动使用 `http://localhost:13500`

**效果**:

- 配置后,OpenAPI 文档中的 "Try it out" 功能会自动使用正确的地址
- 避免生产环境显示 `http://localhost`,导致 API 测试失败

## 开发注意事项

### 1. Redis 依赖和降级策略
Expand Down
11 changes: 11 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
[![Container Image](https://img.shields.io/badge/ghcr.io-ding113%2Fclaude--code--hub-181717?logo=github)](https://github.com/ding113/claude-code-hub/pkgs/container/claude-code-hub)
[![License](https://img.shields.io/github/license/ding113/claude-code-hub)](LICENSE)
[![GitHub Stars](https://img.shields.io/github/stars/ding113/claude-code-hub)](https://github.com/ding113/claude-code-hub/stargazers)
[![Telegram](https://img.shields.io/badge/Telegram-@ygxz__group-26A5E4?logo=telegram)](https://t.me/ygxz_group)

[功能特性](#-功能特性) •
[快速部署](#-快速部署) •
Expand All @@ -21,6 +22,16 @@
> 本项目基于 [zsio/claude-code-hub](https://github.com/zsio/claude-code-hub) 二次开发而来。
> 感谢原作者 [@zsio](https://github.com/zsio) 的开源贡献!

> **💬 加入交流群**
>
> 欢迎加入 Telegram 交流群讨论项目使用、功能建议和技术问题:
>
> <div align="center">
>
> **📱 [点击加入 @ygxz_group](https://t.me/ygxz_group)**
>
> </div>

---

## ✨ 功能特性
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.2.23
0.2.25
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

📦 版本号更新

版本从 0.2.23 升级到 0.2.25,符合语义化版本规范(Patch 版本递增表示 bug 修复)。

Loading