[client] Add embeddable library (#3239)

This commit is contained in:
Viktor Liu
2025-02-20 13:22:03 +01:00
committed by GitHub
parent 39986b0e97
commit 631ef4ed28
22 changed files with 648 additions and 51 deletions

View File

@ -8,9 +8,11 @@ import (
log "github.com/sirupsen/logrus"
)
const EnvUseNetstackMode = "NB_USE_NETSTACK_MODE"
// IsEnabled todo: move these function to cmd layer
func IsEnabled() bool {
return os.Getenv("NB_USE_NETSTACK_MODE") == "true"
return os.Getenv(EnvUseNetstackMode) == "true"
}
func ListenAddr() string {