client

package
v0.0.8 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	// Namespace is the namespace where the client watches for policies.
	Namespace string

	// ClientSet is the k8s clientset
	ClientSet v1alpha1.OpaV1Alpha1Interface

	// Queue is the channel where messages are passed back to the client
	Queue chan v1alpha1.OpaMessage
}

Client holds the information for the cmsnr client.

func NewClient

func NewClient(config *rest.Config, namespace string) (*Client, error)

NewClient returns a new client

func (*Client) WatchResources

func (c *Client) WatchResources()

Watch resources watches for new OPA resources. If they are found, they are passed to the event handler functions that send them as a message to the client.

Jump to

Keyboard shortcuts

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