gravitl / netmaker

Netmaker makes networks with WireGuard. Netmaker automates fast, secure, and distributed virtual networks.
https://netmaker.io
Other
9.4k stars 547 forks source link

Error running "netclient pull" #277

Closed edifus closed 3 years ago

edifus commented 3 years ago

Current Behavior

❱ sudo /etc/netclient/netclient pull
2021/09/13 18:27:33 No network selected. Running Pull for all networks.
trouble decoding file
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x9e2755]

goroutine 1 [running]:
github.com/gravitl/netmaker/netclient/functions.Pull(0xc000341719, 0x3, 0x1, 0x0, 0x0, 0x0)
        /home/ubuntu/netmaker/netclient/functions/checkin.go:157 +0x55
github.com/gravitl/netmaker/netclient/command.Pull(0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
        /home/ubuntu/netmaker/netclient/command/commands.go:104 +0x1b8
main.main.func5(0xc000281640, 0x1d, 0x38)
        /home/ubuntu/netmaker/netclient/main.go:283 +0x11b
github.com/urfave/cli/v2.(*Command).Run(0xc0001d67e0, 0xc000280b80, 0x0, 0x0)
        /home/ubuntu/go/pkg/mod/github.com/urfave/cli/v2@v2.3.0/command.go:163 +0x4dd
github.com/urfave/cli/v2.(*App).RunContext(0xc0003501a0, 0xcc04b0, 0xc0000240c0, 0xc000020040, 0x2, 0x2, 0x0, 0x0)
        /home/ubuntu/go/pkg/mod/github.com/urfave/cli/v2@v2.3.0/app.go:313 +0x810
github.com/urfave/cli/v2.(*App).Run(...)
        /home/ubuntu/go/pkg/mod/github.com/urfave/cli/v2@v2.3.0/app.go:224
main.main()
        /home/ubuntu/netmaker/netclient/main.go:337 +0x235b

Expected Behavior

Command runs successfully

Steps to Reproduce

afeiszli commented 3 years ago

fixed in 0.8