Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Watcher ¶
type Watcher struct { Client clientV1.TargetsCRDInterface // contains filtered or unexported fields }
A Watcher checks kubernetes custom resources ("Target") on a periodic basis for new URLs to monitor
func NewWithClient ¶
func NewWithClient(register, unregister chan monitor.SiteSpec, namespace string, client clientV1.TargetsCRDInterface) *Watcher
NewWithClient creates a Watcher for the specified API client. When Watcher finds a created/removed URL, it sends the URL to the register/unregister channel respectively. If the namespace is specified, Watcher will only scan that namespace. Otherwise, all namespaces are scanned. Note that this needs RBAC setup to ensure the client can access those resources.
Click to show internal directories.
Click to hide internal directories.