store

package
v1.11.3 Latest Latest
Warning

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

Go to latest
Published: Jan 5, 2024 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AllowApiCall

func AllowApiCall(allow bool)

func GetForeachElement

func GetForeachElement() int

func GetRegistryAccess

func GetRegistryAccess() bool

func GetRegistryClient

func GetRegistryClient() registryclient.Client

func HasPolicies

func HasPolicies() bool

func IsApiCallAllowed

func IsApiCallAllowed() bool

func IsLocal

func IsLocal() bool

IsLocal returns 'true' if the CLI is in local (clusterless) execution

func SetForEachElement

func SetForEachElement(element int)

func SetLocal

func SetLocal(m bool)

SetLocal sets local (clusterless) execution for the CLI

func SetPolicies

func SetPolicies(p ...Policy)

func SetRegistryAccess

func SetRegistryAccess(access bool)

Types

type Context

type Context struct {
	Policies []Policy `json:"policies"`
}

type Policy

type Policy struct {
	Name  string `json:"name"`
	Rules []Rule `json:"rules"`
}

func GetPolicy

func GetPolicy(policyName string) *Policy

type Rule

type Rule struct {
	Name          string                   `json:"name"`
	Values        map[string]interface{}   `json:"values"`
	ForEachValues map[string][]interface{} `json:"foreachValues"`
}

func GetPolicyRule

func GetPolicyRule(policyName string, ruleName string) *Rule

Jump to

Keyboard shortcuts

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