mirror of
https://github.com/jesseduffield/lazydocker.git
synced 2026-07-25 08:31:03 +00:00
Gracefully check for docker config
It's fine if the file doesn't exist
This commit is contained in:
parent
cce9d40f43
commit
e860416ee4
1 changed files with 1 additions and 5 deletions
|
|
@ -338,11 +338,7 @@ func determineDockerHost() (string, error) {
|
||||||
|
|
||||||
currentContext := os.Getenv("DOCKER_CONTEXT")
|
currentContext := os.Getenv("DOCKER_CONTEXT")
|
||||||
if currentContext == "" {
|
if currentContext == "" {
|
||||||
dockerConfigDir := cliconfig.Dir()
|
cf, err := cliconfig.Load(cliconfig.Dir())
|
||||||
if _, err := os.Stat(dockerConfigDir); err != nil {
|
|
||||||
return "", err
|
|
||||||
}
|
|
||||||
cf, err := cliconfig.Load(dockerConfigDir)
|
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return "", err
|
return "", err
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue