mirror of
https://github.com/slackhq/nebula.git
synced 2026-11-16 00:06:52 +01:00
Extract the ssh debug commands into a transport neutral commands package (#1958)
Migrate commands from ssh into a transport neutral package - add golden tests validating that output remains unchanged - move commands to commands.go Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
1 parent
cda3710d5a
commit
b426843f88
21 files changed
+2038
-978
No files matched your search
@@ -11,6 +11,7 @@ import (
|
||||
"syscall"
|
||||
|
||||
"github.com/slackhq/nebula/cert"
|
||||
"github.com/slackhq/nebula/commands"
|
||||
"github.com/slackhq/nebula/header"
|
||||
"github.com/slackhq/nebula/overlay"
|
||||
)
|
||||
@@ -47,6 +48,7 @@ type Control struct {
|
||||
|
||||
f *Interface
|
||||
l *slog.Logger
|
||||
commands *commands.Registry
|
||||
ctx context.Context
|
||||
cancel context.CancelFunc
|
||||
sshStart func()
|
||||
@@ -372,6 +374,10 @@ func (c *Control) CloseAllTunnels(excludeLighthouses bool) (closed int) {
|
||||
return
|
||||
}
|
||||
|
||||
func (c *Control) Commands() *commands.Registry {
|
||||
return c.commands
|
||||
}
|
||||
|
||||
func (c *Control) Device() overlay.Device {
|
||||
return c.f.inside
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user