resources

package
v0.0.208 Latest Latest
Warning

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

Go to latest
Published: Dec 13, 2022 License: Apache-2.0 Imports: 8 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

View Source
var RegoCAUtils = `` /* 3180-byte string literal not displayed */
View Source
var RegoDesignators = `` /* 974-byte string literal not displayed */
View Source
var RegoKubernetesApiClient = `` /* 4414-byte string literal not displayed */

Functions

func LoadRegoFiles

func LoadRegoFiles(dir string) map[string]string

LoadRegoDependenciesFromDir loads the policies list from *.rego file in given directory

func LoadRegoModules

func LoadRegoModules() map[string]string

LoadRegoModules loads the policies from variables

func TOStorage

func TOStorage(postureControlInputs map[string][]string) (storage.Store, error)

Types

type RegoDependenciesData

type RegoDependenciesData struct {
	ClusterName string `json:"clusterName"`

	// Configurable control data inputs
	PostureControlInputs map[string][]string `json:"postureControlInputs"`

	// Not Configurable control data inputs (such as cloud provider)
	DataControlInputs map[string]string `json:"dataControlInputs"`

	K8sConfig RegoK8sConfig `json:"k8sconfig"`
}

func NewRegoDependenciesData

func NewRegoDependenciesData(k8sConfig *rest.Config, clusterName string) *RegoDependenciesData

func NewRegoDependenciesDataMock

func NewRegoDependenciesDataMock() *RegoDependenciesData

func (*RegoDependenciesData) GetFilteredPostureControlInputs

func (data *RegoDependenciesData) GetFilteredPostureControlInputs(settings []string) map[string][]string

func (*RegoDependenciesData) TOStorage added in v0.0.204

func (data *RegoDependenciesData) TOStorage() (storage.Store, error)

TOStorage - converts rego data inputs to a storage.Store object.

type RegoK8sConfig

type RegoK8sConfig struct {
	Token         string `json:"token"`
	IP            string `json:"ip"`
	Host          string `json:"host"`
	Port          string `json:"port"`
	CrtFile       string `json:"crtfile"`
	ClientCrtFile string `json:"clientcrtfile"`
	ClientKeyFile string `json:"clientkeyfile"`
}

func NewRegoK8sConfig

func NewRegoK8sConfig(k8sConfig *rest.Config) *RegoK8sConfig

Jump to

Keyboard shortcuts

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