properties

package
v0.4.1 Latest Latest
Warning

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

Go to latest
Published: May 15, 2024 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BuildProperties

func BuildProperties(fns ...PropertiesBuilderFn) posthog.Properties

Types

type ClusterProperties

type ClusterProperties struct {
	// contains filtered or unexported fields
}

type NamespaceGetter

type NamespaceGetter interface {
	GetNamespace(ctx context.Context, name string) (*corev1.Namespace, error)
}

type NodeLister

type NodeLister interface {
	ListNodes(ctx context.Context) (*corev1.NodeList, error)
}

type PropertiesBuilderFn

type PropertiesBuilderFn func(p posthog.Properties) posthog.Properties

func ForClientUser

func ForClientUser(pg PropertyGetter, includeCluster bool) PropertiesBuilderFn

func ForOperatorUser

func ForOperatorUser(pg PropertyGetter) PropertiesBuilderFn

func FromMap

func FromMap(data map[string]any) PropertiesBuilderFn

func FromPackage

func FromPackage(pkg *v1alpha1.Package) PropertiesBuilderFn

type PropertyGetter

type PropertyGetter struct {
	NodeLister      NodeLister
	NamespaceGetter NamespaceGetter
	DiscoveryClient discovery.DiscoveryInterface
}

func (PropertyGetter) ClusterId

func (g PropertyGetter) ClusterId() string

func (PropertyGetter) ClusterProperties

func (g PropertyGetter) ClusterProperties() (p ClusterProperties)

func (PropertyGetter) Enabled

func (g PropertyGetter) Enabled() bool

Jump to

Keyboard shortcuts

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