watcher

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Sep 8, 2023 License: GPL-3.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrWatcheChannelClosed = errors.New("watcher channel has close")

Functions

This section is empty.

Types

type K8sWatcher

type K8sWatcher struct {
	Namespace  string
	CfmName    string
	MasterURL  string
	KubeConfig string
	// contains filtered or unexported fields
}

func NewK8sWatcher

func NewK8sWatcher(ns string, cfmName string, masterUrl string, kubeconfig string) (*K8sWatcher, error)

func (*K8sWatcher) GetConfigMap

func (c *K8sWatcher) GetConfigMap(ctx context.Context) (map[string]*config.InjectionConfig, error)

func (*K8sWatcher) WatchConfigMap

func (c *K8sWatcher) WatchConfigMap(ctx context.Context, notify chan<- interface{}) error

func (*K8sWatcher) WatchNamespace

func (c *K8sWatcher) WatchNamespace(ctx context.Context, webhookEnabledLabel map[string]string, ch chan<- NamespaceEvent) error

type NamespaceEvent

type NamespaceEvent struct {
	Namespace string
	Type      watch.EventType
}

Jump to

Keyboard shortcuts

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