mirror of
https://github.com/lordmathis/llamactl.git
synced 2025-11-05 16:44:22 +00:00
Prevent remote instances from using local proxy in GetProxy method
This commit is contained in:
@@ -171,6 +171,11 @@ func (i *Process) GetProxy() (*httputil.ReverseProxy, error) {
|
|||||||
return nil, fmt.Errorf("instance %s has no options set", i.Name)
|
return nil, fmt.Errorf("instance %s has no options set", i.Name)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Remote instances should not use local proxy - they are handled by RemoteInstanceProxy
|
||||||
|
if len(i.options.Nodes) > 0 {
|
||||||
|
return nil, fmt.Errorf("instance %s is a remote instance and should not use local proxy", i.Name)
|
||||||
|
}
|
||||||
|
|
||||||
var host string
|
var host string
|
||||||
var port int
|
var port int
|
||||||
switch i.options.BackendType {
|
switch i.options.BackendType {
|
||||||
|
|||||||
Reference in New Issue
Block a user