Documentation ¶
Index ¶
Constants ¶
const ( DefaultFederatedGroup = "types.kubefed.io" DefaultFederatedVersion = "v1beta1" )
Default values for the federated group and version used by the enable and disable subcommands of `kubefedctl`.
Variables ¶
This section is empty.
Functions ¶
func CurrentContext ¶ added in v0.3.0
func CurrentContext(config clientcmd.ClientConfig) (string, error)
CurrentContext retrieves the current context from the provided config.
func GetScopeFromKubeFedConfig ¶ added in v0.3.0
Types ¶
type CommonEnableOptions ¶
CommonEnableOptions holds the common configuration required by the enable and disable subcommands of `kubefedctl`.
func (*CommonEnableOptions) CommonSubcommandBind ¶
func (o *CommonEnableOptions) CommonSubcommandBind(flags *pflag.FlagSet, federatedGroupUsage, targetVersionUsage string)
CommonSubcommandBind adds the common subcommand flags to the flagset passed in.
func (*CommonEnableOptions) SetName ¶
func (o *CommonEnableOptions) SetName(args []string) error
SetName sets the name from the args passed in for the required positional argument.
type CommonJoinOptions ¶
CommonJoinOptions holds the common configuration required by the join and unjoin subcommands of `kubefedctl`.
func (*CommonJoinOptions) CommonSubcommandBind ¶
func (o *CommonJoinOptions) CommonSubcommandBind(flags *pflag.FlagSet)
CommonSubcommandBind adds the common subcommand flags to the flagset passed in.
func (*CommonJoinOptions) SetName ¶
func (o *CommonJoinOptions) SetName(args []string) error
SetName sets the name from the args passed in for the required positional argument.
type GlobalSubcommandOptions ¶
type GlobalSubcommandOptions struct { HostClusterContext string KubeFedNamespace string Kubeconfig string DryRun bool }
GlobalSubcommandOptions holds the configuration required by the subcommands of `kubefedctl`.
func (*GlobalSubcommandOptions) GlobalSubcommandBind ¶
func (o *GlobalSubcommandOptions) GlobalSubcommandBind(flags *pflag.FlagSet)
GlobalSubcommandBind adds the global subcommand flags to the flagset passed in.
func (*GlobalSubcommandOptions) SetHostClusterContextFromConfig ¶ added in v0.3.0
func (o *GlobalSubcommandOptions) SetHostClusterContextFromConfig(config clientcmd.ClientConfig) error
SetHostClusterContextFromConfig sets the host cluster context to the name of the the config context if a value was not provided.