benc-uk/kubeview

/.kube/config file not found when runngin locally

CharlieMiRD opened this issue · 0 comments

When running docker run --env HOME=/home/charlie ghcr.io/benc-uk/kubeview:0.1.31 it fails with:

2021/11/30 10:01:56 ### Connecting to Kubernetes...
2021/11/30 10:01:56 ### Creating client with config file: /home/charlie/.kube/config
panic: stat /home/charlie/.kube/config: no such file or directory

goroutine 1 [running]:
main.main()
        /build/cmd/server/main.go:60 +0x6a5

The file does exist:

[charlie@localhost ~]$ ls -al /home/charlie/.kube/
total 20
drwxr-xr-x.  3 charlie charlie   33 Apr  6  2021 .
drwx--x--x. 23 charlie charlie 4096 Nov 30 10:33 ..
drwxr-x---.  4 charlie charlie   35 Apr  6  2021 cache
-rwxr-xr-x.  1 charlie charlie 9698 Nov 30 10:35 config

Line 60 is:

panic(err.Error())

Any chance it failes for another reason than the file not being present?