diff options
Diffstat (limited to 'pkg/csource')
| -rw-r--r-- | pkg/csource/common.go | 1 | ||||
| -rw-r--r-- | pkg/csource/options.go | 4 |
2 files changed, 3 insertions, 2 deletions
diff --git a/pkg/csource/common.go b/pkg/csource/common.go index 587c0f587..f4da50b85 100644 --- a/pkg/csource/common.go +++ b/pkg/csource/common.go @@ -22,6 +22,7 @@ const ( linux = "linux" freebsd = "freebsd" openbsd = "openbsd" + netbsd = "netbsd" sandboxNone = "none" sandboxSetuid = "setuid" diff --git a/pkg/csource/options.go b/pkg/csource/options.go index e63a76890..2eda3acc6 100644 --- a/pkg/csource/options.go +++ b/pkg/csource/options.go @@ -105,7 +105,7 @@ func (opts Options) checkLinuxOnly(OS string) error { if OS == linux { return nil } - if opts.EnableTun && !(OS == openbsd || OS == freebsd) { + if opts.EnableTun && !(OS == openbsd || OS == freebsd || OS == netbsd) { return fmt.Errorf("option EnableTun is not supported on %v", OS) } if opts.EnableNetDev { @@ -124,7 +124,7 @@ func (opts Options) checkLinuxOnly(OS string) error { return fmt.Errorf("EnableCloseFds is not supported on %v", OS) } if opts.Sandbox == sandboxNamespace || - (opts.Sandbox == sandboxSetuid && !(OS == openbsd || OS == freebsd)) || + (opts.Sandbox == sandboxSetuid && !(OS == openbsd || OS == freebsd || OS == netbsd)) || opts.Sandbox == sandboxAndroidUntrustedApp { return fmt.Errorf("option Sandbox=%v is not supported on %v", opts.Sandbox, OS) } |
