mirror of
https://github.com/yusing/godoxy.git
synced 2026-04-23 17:28:53 +02:00
fix agent hot-reload issue and added list agents endpoint
This commit is contained in:
@@ -4,7 +4,6 @@ import (
|
||||
"errors"
|
||||
"fmt"
|
||||
"net/http"
|
||||
"runtime/debug"
|
||||
"sync"
|
||||
|
||||
"github.com/docker/cli/cli/connhelper"
|
||||
@@ -88,7 +87,7 @@ func ConnectClient(host string) (*SharedClient, error) {
|
||||
if agent.IsDockerHostAgent(host) {
|
||||
cfg, ok := config.GetInstance().GetAgent(host)
|
||||
if !ok {
|
||||
return nil, fmt.Errorf("agent %q not found\n%s", host, debug.Stack())
|
||||
panic(fmt.Errorf("agent %q not found", host))
|
||||
}
|
||||
opt = []client.Opt{
|
||||
client.WithHost(agent.DockerHost),
|
||||
|
||||
Reference in New Issue
Block a user