engine

package
v0.0.0-...-31b22f0 Latest Latest
Warning

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

Go to latest
Published: Dec 19, 2024 License: Apache-2.0 Imports: 26 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddRoutes

func AddRoutes(group *gin.RouterGroup, cluster cluster.Cluster, config APIConfiguration) error

Types

type APIConfiguration

type APIConfiguration struct {
	BuiltInCrds []string
	LocalCrds   []string
}

type EngineRequest

type EngineRequest struct {
	Policies                  string                      `json:"policies"`
	Resources                 string                      `json:"resources"`
	OldResources              string                      `json:"oldResources"`
	ClusterResources          string                      `json:"clusterResources"`
	Context                   string                      `json:"context"`
	Config                    string                      `json:"config"`
	CustomResourceDefinitions string                      `json:"customResourceDefinitions"`
	PolicyExceptions          string                      `json:"policyExceptions"`
	VAPBindings               string                      `json:"vapBindings"`
	ImageData                 map[string]models.ImageData `json:"imageData"`
}

func (*EngineRequest) LoadClusterResources

func (r *EngineRequest) LoadClusterResources(resourceLoader loader.Loader) ([]unstructured.Unstructured, error)

func (*EngineRequest) LoadConfig

func (r *EngineRequest) LoadConfig(resourceLoader loader.Loader) (*corev1.ConfigMap, error)

func (*EngineRequest) LoadOldResources

func (r *EngineRequest) LoadOldResources(resourceLoader loader.Loader) ([]unstructured.Unstructured, error)

func (*EngineRequest) LoadParameters

func (r *EngineRequest) LoadParameters() (*models.Parameters, error)

func (*EngineRequest) LoadPolicyExceptions

func (r *EngineRequest) LoadPolicyExceptions() ([]*kyvernov2.PolicyException, error)

func (*EngineRequest) LoadResources

func (r *EngineRequest) LoadResources(resourceLoader loader.Loader) ([]unstructured.Unstructured, error)

func (*EngineRequest) LoadVAPBindings

func (r *EngineRequest) LoadVAPBindings(policyLoader loader.Loader) ([]v1beta1.ValidatingAdmissionPolicyBinding, error)

func (*EngineRequest) ResourceLoader

func (r *EngineRequest) ResourceLoader(cluster cluster.Cluster, kubeVersion string, config APIConfiguration) (loader.Loader, error)

type EngineResponse

type EngineResponse struct {
	Policies  []kyvernov1.PolicyInterface `json:"policies"`
	Resources []unstructured.Unstructured `json:"resources"`
	*models.Results
}

Jump to

Keyboard shortcuts

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