Documentation ¶
Index ¶
- Constants
- func Context(okClientProvider oktetoClientProvider) *cobra.Command
- func CreateCMD() *cobra.Command
- func Delete(okCtxs []string) error
- func DeleteCMD() *cobra.Command
- func List() *cobra.Command
- func LoadContextFromPath(ctx context.Context, namespace, k8sContext, path string, ...) error
- func LoadManifestWithContext(ctx context.Context, opts ManifestOptions, fs afero.Fs) (*model.Manifest, error)
- func LoadStackWithContext(ctx context.Context, name, namespace string, stackPaths []string, fs afero.Fs) (*model.Stack, error)
- func Show() *cobra.Command
- func UpdateKubeconfigCMD(okClientProvider oktetoClientProvider) *cobra.Command
- func Use() *cobra.Command
- func UseNamespace() *cobra.Command
- type Command
- type KubeconfigCMD
- type ManifestOptions
- type Options
- type SelectItem
Constants ¶
View Source
const (
// OktetoUseStaticKubetokenEnvVar is used to opt in to use static kubetoken
OktetoUseStaticKubetokenEnvVar = "OKTETO_USE_STATIC_KUBETOKEN"
)
Variables ¶
This section is empty.
Functions ¶
func LoadContextFromPath ¶
func LoadContextFromPath(ctx context.Context, namespace, k8sContext, path string, defaultCtxOpts Options) error
LoadContextFromPath initializes the okteto context taking into account command flags and manifest namespace/context fields
func LoadManifestWithContext ¶
func LoadManifestWithContext(ctx context.Context, opts ManifestOptions, fs afero.Fs) (*model.Manifest, error)
LoadManifestWithContext loads context and then loads a manifest
func LoadStackWithContext ¶
func UpdateKubeconfigCMD ¶
UpdateKubeconfigCMD all contexts managed by okteto
func UseNamespace ¶
UseNamespace changes your current context namespace.
Types ¶
type Command ¶
type Command struct { K8sClientProvider okteto.K8sClientProvider LoginController login.Interface OktetoClientProvider oktetoClientProvider OktetoContextWriter okteto.ContextConfigWriterInterface // contains filtered or unexported fields }
Command has the dependencies to run a ctxCommand
func NewContextCommand ¶
func NewContextCommand(ctxCmdOption ...ctxCmdOption) *Command
NewContextCommand creates a new Command
func (*Command) RunStateless ¶
func (c *Command) RunStateless(ctx context.Context, ctxOptions *Options) (*okteto.ContextStateless, error)
RunStateless is the fn to use until the refactoring of the context command itself if you want to make use of an injected context instead of using the global context variable.
type KubeconfigCMD ¶
type KubeconfigCMD struct {
// contains filtered or unexported fields
}
type ManifestOptions ¶
type Options ¶
type Options struct { Token string Context string Namespace string Builder string OnlyOkteto bool Show bool Save bool SetCurrentNs bool IsCtxCommand bool CheckNamespaceAccess bool IsOkteto bool InsecureSkipTlsVerify bool InferredToken bool // contains filtered or unexported fields }
func (*Options) InitFromContext ¶
func (o *Options) InitFromContext()
func (*Options) InitFromEnvVars ¶
func (o *Options) InitFromEnvVars()
type SelectItem ¶
Click to show internal directories.
Click to hide internal directories.