Documentation ¶
Overview ¶
Package gcptarget is a constraint framework target for config-validator to use for integrating with the opa constraint framework.
Index ¶
- Constants
- Variables
- type GCPTarget
- func (g *GCPTarget) GetName() string
- func (g *GCPTarget) HandleReview(obj interface{}) (bool, interface{}, error)
- func (g *GCPTarget) HandleViolation(result *types.Result) error
- func (g *GCPTarget) MatchSchema() apiextensions.JSONSchemaProps
- func (g *GCPTarget) ProcessData(obj interface{}) (bool, []string, interface{}, error)
- func (h *GCPTarget) ToMatcher(constraint *unstructured.Unstructured) (constraints.Matcher, error)
- func (g *GCPTarget) ValidateConstraint(constraint *unstructured.Unstructured) error
Constants ¶
View Source
const Name = "validation.gcp.forsetisecurity.org"
Name is the target name for GCPTarget
Variables ¶
View Source
var ErrInvalidAncestryPath = fmt.Errorf("unexpected type of ancestry path in review object")
View Source
var ErrInvalidReview = fmt.Errorf("unexpected type of review, expect map[string]interface{}")
Functions ¶
This section is empty.
Types ¶
type GCPTarget ¶
type GCPTarget struct { }
GCPTarget is the constraint framework target for CAI asset data
func (*GCPTarget) HandleReview ¶
HandleReview implements handler.TargetHandler
func (*GCPTarget) HandleViolation ¶
HandleViolation implements handler.TargetHandler
func (*GCPTarget) MatchSchema ¶
func (g *GCPTarget) MatchSchema() apiextensions.JSONSchemaProps
MatchSchema implements client.MatchSchemaProvider
func (*GCPTarget) ProcessData ¶
ProcessData implements handler.TargetHandler
func (*GCPTarget) ToMatcher ¶
func (h *GCPTarget) ToMatcher(constraint *unstructured.Unstructured) (constraints.Matcher, error)
ToMatcher converts .spec.match in mutators to Matcher.
func (*GCPTarget) ValidateConstraint ¶
func (g *GCPTarget) ValidateConstraint(constraint *unstructured.Unstructured) error
ValidateConstraint implements handler.TargetHandler
Click to show internal directories.
Click to hide internal directories.