feat(proxy): 增加数据库和 AI 代理支持
This commit is contained in:
1 parent
1d5a2b2220
commit
79277c660f
20 files changed
+712
-19
No files matched your search
@@ -137,6 +137,9 @@ pub async fn test_connection(state: State<'_, Arc<AppState>>, config: Connection
|
||||
if config.ssh_enabled && !config.ssh_host.is_empty() {
|
||||
state.tunnels.stop_tunnel(&tunnel_id).await;
|
||||
}
|
||||
if config.proxy_enabled && !config.proxy_host.is_empty() {
|
||||
state.proxy_tunnels.stop_tunnel(&tunnel_id).await;
|
||||
}
|
||||
|
||||
result
|
||||
}
|
||||
@@ -268,5 +271,6 @@ pub async fn disconnect_db(state: State<'_, Arc<AppState>>, connection_id: Strin
|
||||
drop(conns);
|
||||
state.configs.write().await.remove(&connection_id);
|
||||
state.tunnels.stop_tunnel(&connection_id).await;
|
||||
state.proxy_tunnels.stop_tunnel(&connection_id).await;
|
||||
Ok(())
|
||||
}
|
||||
Reference in new issue
Block a user