Skip to content

bug: nil pointer dereference in cli #8315

Closed
@fuale

Description

@fuale

terminal output:

❯ coder version
Coder v0.24.1+2c843f4 Wed Jun 14 11:52:01 UTC 2023
https://github.com/coder/coder/commit/2c843f4011430ef5bbefc76460af20393a317350

Full build of Coder, supports the  server  subcommand.

❯ coder provisionerd
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x1ff0dc9]

goroutine 1 [running]:
github.com/coder/coder/cli.(*RootCmd).Command.func6.1(0x0?)
        /home/runner/actions-runner/_work/coder/coder/cli/root.go:262 +0xc9
github.com/coder/coder/cli/clibase.(*Invocation).run(0xc000889000, 0xc000adfe00)
        /home/runner/actions-runner/_work/coder/coder/cli/clibase/cmd.go:374 +0xdf2
github.com/coder/coder/cli/clibase.(*Invocation).run(0xc000888e00, 0xc000adfe00)
        /home/runner/actions-runner/_work/coder/coder/cli/clibase/cmd.go:323 +0x9ea
github.com/coder/coder/cli/clibase.(*Invocation).Run(0xc000adfeb8?)
        /home/runner/actions-runner/_work/coder/coder/cli/clibase/cmd.go:464 +0xe5
github.com/coder/coder/cli.(*RootCmd).RunMain(0xc000996ae0?, {0xc000190f00, 0x23, 0x3c})
        /home/runner/actions-runner/_work/coder/coder/cli/root.go:131 +0x1a5
main.main()
        /home/runner/actions-runner/_work/coder/coder/enterprise/cmd/coder/main.go:11 +0x45

expected output:

❯ coder provisionerd
Usage: coder provisionerd

Manage provisioner daemons

Subcommands
    start    Run a provisioner daemon

---
Run `coder --help` for a list of global options.

I'm not enterprise user, just curios.

Metadata

Metadata

Assignees

Labels

s1Bugs that break core workflows. Only humans may set this.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions