Documentation ¶
Overview ¶
Package common contains utilities shared between the opnictl commands and the CLI logic that is not tied to any specific command.
Index ¶
Constants ¶
View Source
const ( DefaultOpniNamespace = "opni" DefaultOpniDemoName = "opni-demo" DefaultOpniDemoNamespace = "opni-demo" DefaultOpniDemoMinioAccessKey = "minioadmin" DefaultOpniDemoMinioSecretKey = "minioadmin" DefaultOpniDemoMinioVersion = "8.0.10" DefaultOpniDemoNatsVersion = "2.2.1" DefaultOpniDemoNatsPassword = "password" DefaultOpniDemoNatsReplicas = 3 DefaultOpniDemoNatsMaxPayload = 10485760 DefaultOpniDemoNvidiaVersion = "1.0.0-beta6" DefaultOpniDemoElasticUser = "admin" DefaultOpniDemoElasticPassword = "admin" DefaultOpniDemoNulogServiceCPURequest = "1" DefaultOpniDemoQuickstart = false )
Variables ¶
View Source
var ( TimeoutFlagValue time.Duration NamespaceFlagValue string ContextOverrideFlagValue string ExplicitPathFlagValue string K8sClient client.Client RestConfig *rest.Config APIConfig *api.Config )
View Source
var Log *zap.SugaredLogger
Log is a shared logger that can be used in all opnictl commands.
Functions ¶
func CreateDefaultDemoNamespace ¶ added in v0.2.0
CreateDefaultNamespace creates the default opni demo namespace if it does not already exist.
func CreateDefaultNamespace ¶ added in v0.2.0
CreateDefaultNamespace creates the default opni namespace if it does not already exist.
func LoadDefaultClientConfig ¶
func LoadDefaultClientConfig()
func MaybeContextOverride ¶
func MaybeContextOverride() []cliutil.ClientOption
MaybeContextOverride will return 0 or 1 ClientOptions, depending on if the user provided a specific kubectl context or not.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.