Documentation
¶
Index ¶
Constants ¶
View Source
const HostName = "host"
Variables ¶
View Source
var ( ConfigFileFlag string Verbose bool )
View Source
var ClusterTypes = []ClusterType{Host, Member}
Functions ¶
Types ¶
type ClusterAccessDefinition ¶
type ClusterAccessDefinition struct { ClusterDefinition `yaml:",inline"` Token string `yaml:"token"` }
func LoadClusterAccessDefinition ¶
func LoadClusterAccessDefinition(term ioutils.Terminal, clusterName string) (ClusterAccessDefinition, error)
LoadClusterAccessDefinition loads ClusterAccessDefinition object from the config file and checks that all required parameters are set
type ClusterAccessDefinitions ¶
type ClusterAccessDefinitions map[string]ClusterAccessDefinition
type ClusterConfig ¶
type ClusterConfig struct { ClusterAccessDefinition AllClusterNames []string ClusterName string Token string OperatorNamespace string // namespace where either the host-operator or the member-operator is deployed (depends on the cluster context) }
ClusterConfig contains all parameters of a cluster loaded from KsctlConfig plus all cluster names defined in the KsctlConfig
func LoadClusterConfig ¶
func LoadClusterConfig(term ioutils.Terminal, clusterName string) (ClusterConfig, error)
LoadClusterConfig loads ClusterConfig object from the config file and checks that all required parameters are set as well as the token for the given name
func (ClusterConfig) GetNamespaceParam ¶
func (c ClusterConfig) GetNamespaceParam() string
GetNamespaceParam returns the `--namespace=` param along with its actual value
func (ClusterConfig) GetServerParam ¶
func (c ClusterConfig) GetServerParam() string
GetServerParam returns the `--server=` param along with its actual value
type ClusterDefinition ¶
type ClusterDefinition struct { ClusterType ClusterType `yaml:"clusterType"` ServerAPI string `yaml:"serverAPI"` ServerName string `yaml:"serverName"` }
type ClusterNamespaces ¶
type ClusterType ¶
type ClusterType string
var Host ClusterType = "host"
var Member ClusterType = "member"
func (ClusterType) AsSuffix ¶
func (cluster ClusterType) AsSuffix(prefix string) string
func (ClusterType) String ¶
func (cluster ClusterType) String() string
func (ClusterType) TheOtherType ¶
func (cluster ClusterType) TheOtherType() ClusterType
type KsctlConfig ¶
type KsctlConfig struct { ClusterAccessDefinitions `yaml:",inline"` Name string `yaml:"name"` }
Click to show internal directories.
Click to hide internal directories.