cliutil

package
v0.11.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 15, 2023 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func JoinKeyValuePairs

func JoinKeyValuePairs(pairs map[string]string) []string

func LoadConfigObjectsOrDie

func LoadConfigObjectsOrDie(
	configLocation string,
	lg logger.ExtendedSugaredLogger,
) meta.ObjectList

func ParseKeyValuePairs

func ParseKeyValuePairs(pairs []string) (map[string]string, error)

Parses strings of the form "key=value" into a map[string]string.

func RenderAccessMatrix

func RenderAccessMatrix(am AccessMatrix) string

func RenderBootstrapToken

func RenderBootstrapToken(token *corev1.BootstrapToken) string

func RenderBootstrapTokenList

func RenderBootstrapTokenList(list *corev1.BootstrapTokenList) string

func RenderCapabilityList added in v0.6.0

func RenderCapabilityList(list *managementv1.CapabilityList) string

func RenderCertInfoChain

func RenderCertInfoChain(chain []*corev1.CertInfo) string

func RenderClusterDetails added in v0.8.0

func RenderClusterDetails(cluster *corev1.Cluster) string

func RenderClusterList

func RenderClusterList(list *corev1.ClusterList, status []*corev1.HealthStatus) string

func RenderClusterListWithStats added in v0.6.0

func RenderClusterListWithStats(list *corev1.ClusterList, status []*corev1.HealthStatus, stats *cortexadmin.UserIDStatsList) string

func RenderCortexClusterStatus added in v0.6.0

func RenderCortexClusterStatus(status *cortexadmin.CortexStatus) string

func RenderCortexRules added in v0.8.2

func RenderCortexRules(resp *cortexadmin.ListRulesResponse) string

func RenderDefaultNodeConfig added in v0.9.2

func RenderDefaultNodeConfig(defaultConfig *node.MetricsCapabilitySpec) string

func RenderDiscoveryEntries added in v0.8.2

func RenderDiscoveryEntries(entries []*remoteread.DiscoveryEntry) string

func RenderMetricSamples added in v0.6.0

func RenderMetricSamples(samples []*model.Sample) string

func RenderMetricsNodeConfigs added in v0.9.2

func RenderMetricsNodeConfigs(nodes []MetricsNodeConfigInfo, defaultConfig *node.MetricsCapabilitySpec) string

func RenderRole

func RenderRole(role *corev1.Role) string

func RenderRoleBinding

func RenderRoleBinding(binding *corev1.RoleBinding) string

func RenderRoleBindingList

func RenderRoleBindingList(list *corev1.RoleBindingList) string

func RenderRoleList

func RenderRoleList(list *corev1.RoleList) string

func RenderTargetList added in v0.8.2

func RenderTargetList(list *remoteread.TargetList) string

Types

type AccessMatrix

type AccessMatrix struct {
	// List of users (in the order they will appear in the table)
	Users []string
	// Set of known clusters (rules referencing nonexistent clusters are marked)
	KnownClusters map[string]struct{}
	// Map of tenant IDs to a set of users that have access to the tenant
	ClustersToUsers map[string]map[string]struct{}
}

type MetricsNodeConfigInfo added in v0.9.2

type MetricsNodeConfigInfo struct {
	Id            string
	HasCapability bool
	Spec          *node.MetricsCapabilitySpec
	IsDefault     bool
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL