jenkins-x / jx

Jenkins X provides automated CI+CD for Kubernetes with Preview Environments on Pull Requests using Cloud Native pipelines from Tekton
https://jenkins-x.io/
Apache License 2.0
4.58k stars 788 forks source link

panic (SIGSEGV) when creating quickstart #2853

Closed markawm closed 5 years ago

markawm commented 5 years ago

Summary

When running jx create quickstart interactively, I'm getting:

[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x2bedf67]

goroutine 1 [running]:
github.com/jenkins-x/jx/pkg/jx/cmd.(*ImportOptions).CreateNewRemoteRepository(0xc000780000, 0x0, 0x0)
    /Users/markwm/dev/jx/jx/pkg/jx/cmd/import.go:641 +0x657
github.com/jenkins-x/jx/pkg/jx/cmd.(*ImportOptions).Run(0xc000780000, 0xc000ce6e40, 0x3d)
    /Users/markwm/dev/jx/jx/pkg/jx/cmd/import.go:390 +0x7b0
github.com/jenkins-x/jx/pkg/jx/cmd.(*CreateProjectOptions).ImportCreatedProject(0xc000780000, 0xc000f7a7c0, 0x1f, 0x1, 0x1)
    /Users/markwm/dev/jx/jx/pkg/jx/cmd/create.go:116 +0x65
github.com/jenkins-x/jx/pkg/jx/cmd.(*CreateQuickstartOptions).Run(0xc000780000, 0x0, 0x0)
    /Users/markwm/dev/jx/jx/pkg/jx/cmd/create_quickstart.go:235 +0x822
github.com/jenkins-x/jx/pkg/jx/cmd.NewCmdCreateQuickstart.func1(0xc00077ac80, 0x5c4bc80, 0x0, 0x0)
    /Users/markwm/dev/jx/jx/pkg/jx/cmd/create_quickstart.go:88 +0x72
github.com/spf13/cobra.(*Command).execute(0xc00077ac80, 0x5c4bc80, 0x0, 0x0, 0xc00077ac80, 0x5c4bc80)
    /Users/markwm/go/pkg/mod/github.com/spf13/cobra@v0.0.3/command.go:766 +0x2cc
github.com/spf13/cobra.(*Command).ExecuteC(0xc00093af00, 0x0, 0x0, 0x0)
    /Users/markwm/go/pkg/mod/github.com/spf13/cobra@v0.0.3/command.go:852 +0x2fd
github.com/spf13/cobra.(*Command).Execute(0xc00093af00, 0xc0007be8c0, 0x3d13320)
    /Users/markwm/go/pkg/mod/github.com/spf13/cobra@v0.0.3/command.go:800 +0x2b
github.com/jenkins-x/jx/cmd/jx/app.Run(0xc0009fbf88, 0xc0000b2058)
    /Users/markwm/dev/jx/jx/cmd/jx/app/jx.go:17 +0xed
main.main()
    /Users/markwm/dev/jx/jx/cmd/jx/jx.go:11 +0x22```

...interestingly this _didn't_ happen when I tried it in batch mode! `jx create quickstart --batch-mode --git-username=markawm --org=markawm --pack=golang-http --filter=golang-http --project-name=mwm-test-8`

### Steps to reproduce the behavior

Run `jx create quickstart` interactively - most options I've tried so far seem to work...

### Expected behavior

No panic.

### Actual behavior

panic.

### Jx version

The output of `jx version` is:

NAME VERSION jx 1.3.802 jenkins x platform 0.0.3306 Kubernetes cluster v1.10.11-gke.1 kubectl v1.13.2 helm client v2.11.0+g2e55dbe helm server v2.11.0+g2e55dbe git git version 2.20.1 Operating System Mac OS X 10.14.2 build 18C54



### Jenkins type

<!--
Select which Jenkins installation type are you using. 
-->
- [ ] Classic Jenkins
- [ ] Serverless Jenkins

### Kubernetes cluster

<!--
What kind of Kubernetes cluster are you using & how did you create it?
-->

### Operating system / Environment

<!--
In which environment are you running the jx CLI?
-->
rawlingsj commented 5 years ago

Ah yeah - I saw that this morning and fixed with https://github.com/jenkins-x/jx/commit/f2329caf707c427a299657008abb45f2cde0f3d8