Note
🚧 Beta Software - This CLI is currently in beta stage and is not yet ready for production use. Features may change as we continue development and gather feedback. Please report any issues you encounter!
The KubeLB CLI provides tools to manage KubeLB load balancers and create secure tunnels to expose local services through the KubeLB infrastructure(Requires KubeLB Enterprise Edition).
For more information, please refer to the KubeLB CLI documentation.
- Go 1.24.5+
make buildThis will create the binary in ./bin/kubelb.
make installThis will install the binary to your Go bin directory.
The KubeLB CLI supports multiple ways to configure kubeconfig and tenant settings, with the following precedence (highest to lowest):
--kubeconfigflag: Explicitly specify kubeconfig pathKUBECONFIGenvironment variable: Standard Kubernetes environment variable
--tenant, -tflag: Explicitly specify tenant nameTENANT_NAMEenvironment variable: Set tenant via environment variable- Error if neither provided: Tenant is required for most commands (error message includes both flag and environment variable options)
# Using flags
kubelb loadbalancer list --tenant mycompany --kubeconfig ./kubeconfig
# Using environment variables
export TENANT_NAME=mycompany
export KUBECONFIG=./kubeconfig
kubelb loadbalancer list
# Mixed (flags override environment variables)
export TENANT_NAME=from-env
kubelb loadbalancer list --tenant from-flag # Uses "from-flag"
# Tenant namespace examples
kubelb loadbalancer list --tenant mycompany # Uses namespace: tenant-mycompany
kubelb loadbalancer list --tenant tenant-mycompany # Uses namespace: tenant-mycompany (no double prefix)--kubeconfig: Path to kubeconfig file--tenant, -t: Tenant name (creates namespacetenant-{name}, or uses as-is if already prefixed)--timeout: Timeout for operations (e.g., 30s, 5m)
For more information, please refer to the CLI Reference.

