refactor: code refactor and improved context and error handling

This commit is contained in:
yusing
2025-05-24 10:02:24 +08:00
parent 1f1ae38e4d
commit 5b7c392297
31 changed files with 116 additions and 98 deletions

View File

@@ -190,7 +190,7 @@ func NewClient(host string) (*SharedClient, error) {
c.dial = client.Dialer()
}
if c.addr == "" {
c.addr = c.Client.DaemonHost()
c.addr = c.DaemonHost()
}
defer log.Debug().Str("host", host).Msg("docker client initialized")