huangzhenpc
282dcf05f0
merge: 合并官方 upstream/main 的 6 个功能更新
...
CI / test (push) Has been cancelled
CI / golangci-lint (push) Has been cancelled
CI / test (pull_request) Has been cancelled
CI / golangci-lint (pull_request) Has been cancelled
合并内容:
1. feat(gateway): Claude Code 系统提示词智能注入
2. fix: 修复创建账号 schedulable 默认值为 false 的 bug
3. fix(frontend): 修复跨时区日期范围筛选问题
4. feat(proxy): SOCKS5H 代理支持(统一代理配置)
5. fix(oauth): 修复 Claude Cookie 添加账号时会话混淆
6. fix(test): 修复 OAuth 账号测试刷新 token 的 bug
新增文件:
- backend/internal/pkg/proxyutil/* (SOCKS5H 支持)
- backend/internal/service/gateway_prompt_test.go (测试)
来自 upstream: Wei-Shaw/sub2api commits d9b1587..a527559
2026-01-04 18:48:05 +08:00
huangzhenpc
f2b1fc0ace
fix: 恢复所有迁移文件以修复校验和错误
...
CI / test (push) Has been cancelled
CI / golangci-lint (push) Has been cancelled
恢复了以下迁移文件到原始状态:
- 004_add_redeem_code_notes.sql
- 005_schema_parity.sql
- 006_fix_invalid_subscription_expires_at.sql
- 007_add_user_allowed_groups.sql
- 008_seed_default_group.sql
- 009_fix_usage_logs_cache_columns.sql
- 010_add_usage_logs_aggregated_indexes.sql
- 011_remove_duplicate_unique_indexes.sql
- 012_add_user_subscription_soft_delete.sql
- 013_log_orphan_allowed_groups.sql
- 014_drop_legacy_allowed_groups.sql
- 015_fix_settings_unique_constraint.sql
- 016_soft_delete_partial_unique_indexes.sql
- 018_user_attributes.sql
- 019_migrate_wechat_to_attributes.sql
- 024_add_gemini_tier_id.sql
数据库迁移文件不应在应用后修改,即使只是注释。
2026-01-04 18:21:46 +08:00
huangzhenpc
13b95049c3
fix: 恢复迁移文件到原始状态修复校验和错误
...
CI / test (push) Has been cancelled
CI / golangci-lint (push) Has been cancelled
Migration files should never be modified after being applied.
Reverted comment-only changes to fix checksum mismatch.
修复错误: migration 001_init.sql checksum mismatch
解决方案: 将迁移文件恢复到修改前的状态
2026-01-04 18:11:45 +08:00
huangzhenpc
d274c8cb14
feat: 品牌重命名 Sub2API -> TianShuAPI
...
CI / test (push) Has been cancelled
CI / golangci-lint (push) Has been cancelled
- 前端: 所有界面显示、i18n 文本、组件中的品牌名称
- 后端: 服务层、设置默认值、邮件模板、安装向导
- 数据库: 迁移脚本注释
- 保持功能完全一致,仅更改品牌名称
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com >
2026-01-04 17:50:29 +08:00
huangzhenpc
e27c1acf79
remove: 移除官方 GitHub 链接
...
CI / test (push) Has been cancelled
CI / golangci-lint (push) Has been cancelled
- 删除顶部导航 GitHub 链接
- 删除首页页脚 GitHub 链接
- 清理相关变量定义
2026-01-04 17:15:57 +08:00
huangzhenpc
f7a5cee262
feat: docker-compose.1panel.yml 支持本地构建
...
CI / test (push) Has been cancelled
CI / golangci-lint (push) Has been cancelled
- 默认从本地代码构建镜像
- 保留官方镜像选项(注释)
- 支持二次开发场景
- 统一配置文件,无需维护多个版本
2026-01-04 16:48:34 +08:00
huangzhenpc
106d8d8e57
fix: sub2api 加入 1panel-network 网络
...
CI / test (push) Has been cancelled
CI / golangci-lint (push) Has been cancelled
- 允许 sub2api 容器访问 1Panel Redis 容器
- 添加 1panel-network 为外部网络
- 保持通过容器名 1Panel-redis-S1KH 连接 Redis
2026-01-04 11:28:25 +08:00
huangzhenpc
b57334b82c
fix: 修复 docker-compose.1panel.yml 网络配置
...
CI / test (push) Has been cancelled
CI / golangci-lint (push) Has been cancelled
- 移除 network_mode: bridge
- 添加自定义网络 sub2api-network
- 修复容器间无法通过服务名通信的问题
2026-01-04 11:00:35 +08:00
huangzhenpc
e4db851b31
feat: 添加二次开发部署配置和文档
...
CI / test (push) Has been cancelled
CI / golangci-lint (push) Has been cancelled
- 添加双 Git remote 配置指南 (GIT_GUIDE.md, GIT_WORKFLOW.md)
- 添加 1Panel 环境部署配置 (docker-compose.1panel.yml, .env.1panel)
- 添加自动化部署脚本 (deploy-complete.sh, deploy-dev.sh, deploy.sh)
- 添加部署说明文档 (README_DEPLOY.md)
- 配置端口 2080 映射
- 支持连接现有 1Panel Redis (1Panel-redis-S1KH)
2026-01-04 10:25:36 +08:00