Azure / draft-classic

A tool for developers to create cloud-native applications on Kubernetes.
https://draft.sh
MIT License
3.92k stars 397 forks source link

"draft up" throwing up error #854

Closed rangapv closed 5 years ago

rangapv commented 5 years ago

I am getting the following error when I try the "draft up"

ubuntu@ip-172-0-94-89:~/t54/draft/examples/example-php$ draft up
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x20 pc=0x4ca527]

goroutine 1 [running]:
fmt.Fprintf(0x0, 0x0, 0x183911c, 0x27, 0xc42091b770, 0x1, 0x1, 0xc420280b60, 0xc42000c5b0, 0xc42091b850)
        /usr/local/go/src/fmt/print.go:182 +0x77
github.com/Azure/draft/vendor/github.com/docker/cli/cli/config.LoadDefaultConfigFile(0x0, 0x0, 0x1762f00)
        /go/src/github.com/Azure/draft/vendor/github.com/docker/cli/cli/config/config.go:114 +0xc7
github.com/Azure/draft/vendor/github.com/docker/cli/cli/command.(*DockerCli).Initialize(0xc420368180, 0xc4201d2ac0, 0x181d18c, 0x13)
        /go/src/github.com/Azure/draft/vendor/github.com/docker/cli/cli/command/cli.go:150 +0x4d
main.(*upCmd).run(0xc42020caf0, 0x1811de4, 0xb, 0x0, 0x0)
        /go/src/github.com/Azure/draft/cmd/draft/up.go:201 +0x485
main.newUpCmd.func2(0xc4204a3200, 0x24c5ad0, 0x0, 0x0, 0x0, 0x0)
        /go/src/github.com/Azure/draft/cmd/draft/up.go:111 +0x101
github.com/Azure/draft/vendor/github.com/spf13/cobra.(*Command).execute(0xc4204a3200, 0x24c5ad0, 0x0, 0x0, 0xc4204a3200, 0x24c5ad0)
        /go/src/github.com/Azure/draft/vendor/github.com/spf13/cobra/command.go:698 +0x47a
github.com/Azure/draft/vendor/github.com/spf13/cobra.(*Command).ExecuteC(0xc4204bf200, 0xc42000c010, 0xc4204bf200, 0xc4207fbf70)
        /go/src/github.com/Azure/draft/vendor/github.com/spf13/cobra/command.go:783 +0x30e
github.com/Azure/draft/vendor/github.com/spf13/cobra.(*Command).Execute(0xc4204bf200, 0x0, 0x0)
        /go/src/github.com/Azure/draft/vendor/github.com/spf13/cobra/command.go:736 +0x2b
main.main()
        /go/src/github.com/Azure/draft/cmd/draft/draft.go:178 +0x2d

System Details:

ubuntu@ip-172-0-94-89:~$ helm version
Client: &version.Version{SemVer:"v2.9.1", GitCommit:"20adb27c7c5868466912eebdf6664e7390ebe710", GitTreeState:"clean"}
Server: &version.Version{SemVer:"v2.9.1", GitCommit:"20adb27c7c5868466912eebdf6664e7390ebe710", GitTreeState:"clean"}

ubuntu@ip-172-0-94-89:~$ draft version
&version.Version{SemVer:"v0.14.1", GitCommit:"fdc29c553a45600ac4f795f3485d4bb9a80c7862", GitTreeState:"clean"}

ubuntu@ip-172-0-94-89:~$ kubectl version
Client Version: version.Info{Major:"1", Minor:"11", GitVersion:"v1.11.1", GitCommit:"b1b29978270dc22fecc592ac55d903350454310a", GitTreeState:"clean", BuildDate:"2018-07-17T18:53:20Z", GoVersion:"go1.10.3", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"11", GitVersion:"v1.11.1", GitCommit:"b1b29978270dc22fecc592ac55d903350454310a", GitTreeState:"clean", BuildDate:"2018-07-17T18:43:26Z", GoVersion:"go1.10.3", Compiler:"gc", Platform:"linux/amd64"}

on ubuntu 16.04.

Regards Ranga

bacongobbler commented 5 years ago

Looks like it's trying to load config that's unavailable on the system. Did you try draft init before calling draft up? IIRC we fixed this in 0.15.0, so I'd try that as well.

rangapv commented 5 years ago

Yes i tried to do sudo draft up , it works, Looks like the docker permission issue..for now it seems to work with sudo. Please close the issue I will fix docker permissions at my end. Thanks, Appreciate for the quick response Regards Ranga