拆分服务器地址配置为独立字段,支持CDN优选IP故障切换,新增重置数据库按钮
- model: ServerURL → Protocol/Host/ServerIPs/Port/Path 五个字段 - db: 自动迁移旧 server_url 列到新表结构 - ui: 配置窗口改为横向分组布局,保存失败时不再关闭窗口 - transport: 支持 TLS SNI + Host 头覆盖以连接 CDN 边缘节点 - session: CDN IP 列表连接失败自动切换到下一个 - 新增重置数据库按钮,一键清空所有配置
This commit is contained in:
+4
-2
@@ -5,8 +5,8 @@
|
||||
// Protocol: newline-delimited JSON. Each message is one JSON object
|
||||
// followed by '\n'.
|
||||
//
|
||||
// GUI → daemon: Request (start, stop, shutdown, stats)
|
||||
// daemon → GUI: Event (state, stats, error)
|
||||
// GUI → daemon: Request (start, stop, shutdown, stats)
|
||||
// daemon → GUI: Event (state, stats, error)
|
||||
package ipc
|
||||
|
||||
import (
|
||||
@@ -49,6 +49,8 @@ type Request struct {
|
||||
// package (which needs root-only TUN) into the GUI.
|
||||
type ClientConfig struct {
|
||||
ServerURL string `json:"server_url"`
|
||||
SNIHost string `json:"sni_host"` // TLS SNI hostname for CDN
|
||||
ServerIPs []string `json:"server_ips"` // CDN edge IP list for failover
|
||||
Username string `json:"username"`
|
||||
Password string `json:"password"`
|
||||
Token string `json:"token"`
|
||||
|
||||
Reference in New Issue
Block a user