custompolicytemplatemodels

package
v1.4.4 Latest Latest
Warning

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

Go to latest
Published: Mar 21, 2024 License: MPL-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type K8sIoApimachineryPkgApisMetaV1GroupVersionKind

type K8sIoApimachineryPkgApisMetaV1GroupVersionKind struct {

	// group
	Group string `json:"group,omitempty"`

	// kind
	Kind string `json:"kind,omitempty"`

	// version
	Version string `json:"version,omitempty"`
}

K8sIoApimachineryPkgApisMetaV1GroupVersionKind GroupVersionKind unambiguously identifies a kind. It doesn't anonymously include GroupVersion to avoid automatic coersion. It doesn't use a GroupVersion to avoid custom marshalling

+protobuf.options.(gogoproto.goproto_stringer)=false

swagger:model k8s.io.apimachinery.pkg.apis.meta.v1.GroupVersionKind

func (*K8sIoApimachineryPkgApisMetaV1GroupVersionKind) MarshalBinary

MarshalBinary interface implementation.

func (*K8sIoApimachineryPkgApisMetaV1GroupVersionKind) UnmarshalBinary

UnmarshalBinary interface implementation.

type VmwareTanzuManageV1alpha1PolicyTemplate

type VmwareTanzuManageV1alpha1PolicyTemplate struct {

	// Full name for the policy template.
	FullName *VmwareTanzuManageV1alpha1PolicyTemplateFullName `json:"fullName,omitempty"`

	// Metadata for the policy template object.
	Meta *objectmetamodel.VmwareTanzuCoreV1alpha1ObjectMeta `json:"meta,omitempty"`

	// Spec for the policy template.
	Spec *VmwareTanzuManageV1alpha1PolicyTemplateSpec `json:"spec,omitempty"`

	// Metadata describing the type of the resource.
	Type *objectmetamodel.VmwareTanzuCoreV1alpha1ObjectType `json:"type,omitempty"`
}

VmwareTanzuManageV1alpha1PolicyTemplate A Policy Template wraps a Kubernetes resource that is a pre-requisite/dependency for creating policies. An example of a policy template is OPAGatekeeper based ConstraintTemplate.

swagger:model vmware.tanzu.manage.v1alpha1.policy.template.Template

func (*VmwareTanzuManageV1alpha1PolicyTemplate) MarshalBinary

func (m *VmwareTanzuManageV1alpha1PolicyTemplate) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation.

func (*VmwareTanzuManageV1alpha1PolicyTemplate) UnmarshalBinary

func (m *VmwareTanzuManageV1alpha1PolicyTemplate) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation.

type VmwareTanzuManageV1alpha1PolicyTemplateData

type VmwareTanzuManageV1alpha1PolicyTemplateData struct {

	// Template to create.
	Template *VmwareTanzuManageV1alpha1PolicyTemplate `json:"template,omitempty"`
}

VmwareTanzuManageV1alpha1PolicyTemplateCreateTemplateRequest Request to create a Template.

swagger:model vmware.tanzu.manage.v1alpha1.policy.template.CreateTemplateRequest

func (*VmwareTanzuManageV1alpha1PolicyTemplateData) MarshalBinary

func (m *VmwareTanzuManageV1alpha1PolicyTemplateData) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation.

func (*VmwareTanzuManageV1alpha1PolicyTemplateData) UnmarshalBinary

func (m *VmwareTanzuManageV1alpha1PolicyTemplateData) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation.

type VmwareTanzuManageV1alpha1PolicyTemplateFullName

type VmwareTanzuManageV1alpha1PolicyTemplateFullName struct {

	// Name of policy template.
	Name string `json:"name,omitempty"`

	// ID of Organization.
	OrgID string `json:"orgId,omitempty"`
}

VmwareTanzuManageV1alpha1PolicyTemplateFullName Full name of the policy template. This includes the object name along with any parents or further identifiers.

swagger:model vmware.tanzu.manage.v1alpha1.policy.template.FullName

func (*VmwareTanzuManageV1alpha1PolicyTemplateFullName) MarshalBinary

MarshalBinary interface implementation.

func (*VmwareTanzuManageV1alpha1PolicyTemplateFullName) UnmarshalBinary

UnmarshalBinary interface implementation.

type VmwareTanzuManageV1alpha1PolicyTemplatePolicyUpdateStrategy

type VmwareTanzuManageV1alpha1PolicyTemplatePolicyUpdateStrategy struct {

	// The strategy to use for policy updates.
	Type *VmwareTanzuManageV1alpha1PolicyTemplatePolicyUpdateStrategyType `json:"type,omitempty"`
}

VmwareTanzuManageV1alpha1PolicyTemplatePolicyUpdateStrategy PolicyUpdateStrategy on how to handle policies after a policy template update.

swagger:model vmware.tanzu.manage.v1alpha1.policy.template.PolicyUpdateStrategy

func (*VmwareTanzuManageV1alpha1PolicyTemplatePolicyUpdateStrategy) MarshalBinary

MarshalBinary interface implementation.

func (*VmwareTanzuManageV1alpha1PolicyTemplatePolicyUpdateStrategy) UnmarshalBinary

UnmarshalBinary interface implementation.

type VmwareTanzuManageV1alpha1PolicyTemplatePolicyUpdateStrategyType

type VmwareTanzuManageV1alpha1PolicyTemplatePolicyUpdateStrategyType string

VmwareTanzuManageV1alpha1PolicyTemplatePolicyUpdateStrategyType PolicyUpdateStrategyType defines strategies for updating policies after a policy template update.

  • POLICY_UPDATE_STRATEGY_TYPE_UNSPECIFIED: UNSPECIFIED policy update strategy (default).

Updates will not be allowed when this strategy is selected.

  • INPLACE_UPDATE: In-place policy update strategy.

Existing Template will be forcibly updated without creating a new version. There will be no changes to the policies using the template. Warning: When using this strategy, make sure that the updated template does not adversely affect the existing policies.

swagger:model vmware.tanzu.manage.v1alpha1.policy.template.PolicyUpdateStrategyType

const (

	// VmwareTanzuManageV1alpha1PolicyTemplatePolicyUpdateStrategyTypePOLICYUPDATESTRATEGYTYPEUNSPECIFIED captures enum value "POLICY_UPDATE_STRATEGY_TYPE_UNSPECIFIED".
	VmwareTanzuManageV1alpha1PolicyTemplatePolicyUpdateStrategyTypePOLICYUPDATESTRATEGYTYPEUNSPECIFIED VmwareTanzuManageV1alpha1PolicyTemplatePolicyUpdateStrategyType = "POLICY_UPDATE_STRATEGY_TYPE_UNSPECIFIED"

	// VmwareTanzuManageV1alpha1PolicyTemplatePolicyUpdateStrategyTypeINPLACEUPDATE captures enum value "INPLACE_UPDATE".
	VmwareTanzuManageV1alpha1PolicyTemplatePolicyUpdateStrategyTypeINPLACEUPDATE VmwareTanzuManageV1alpha1PolicyTemplatePolicyUpdateStrategyType = "INPLACE_UPDATE"
)

func (VmwareTanzuManageV1alpha1PolicyTemplatePolicyUpdateStrategyType) Pointer

Pointer returns a pointer to a freshly-allocated VmwareTanzuManageV1alpha1PolicyTemplatePolicyUpdateStrategyType.

type VmwareTanzuManageV1alpha1PolicyTemplateSpec

type VmwareTanzuManageV1alpha1PolicyTemplateSpec struct {

	// DataInventory is a list of Kubernetes api-resource kinds that need to be synced/replicated
	// in Gatekeeper in order to enforce policy rules on those resources.
	// Note: This is used for OPAGatekeeper based templates, and should be used if the policy
	// enforcement logic in Rego code uses cached data using "data.inventory" fields.
	DataInventory []*K8sIoApimachineryPkgApisMetaV1GroupVersionKind `json:"dataInventory"`

	// Deprecated specifies whether this version (latest version) of the policy template is deprecated.
	// Updating a policy template deprecates the previous versions. To view all versions, use Versions API.
	Deprecated bool `json:"deprecated"`

	// Object is a yaml-formatted Kubernetes resource.
	// The Kubernetes object has to be of the type defined in ObjectType ('ConstraintTemplate').
	// The object name must match the name of the wrapping policy template.
	// This will be applied on the cluster after a policy is created using this version of the template.
	// This contains the latest version of the object. For previous versions, check Versions API.
	Object string `json:"object,omitempty"`

	// ObjectType is the type of Kubernetes resource encoded in Object.
	// Currently, we only support OPAGatekeeper based 'ConstraintTemplate' object.
	ObjectType string `json:"objectType,omitempty"`

	// PolicyUpdateStrategy on how to handle policies after a policy template update.
	PolicyUpdateStrategy *VmwareTanzuManageV1alpha1PolicyTemplatePolicyUpdateStrategy `json:"policyUpdateStrategy,omitempty"`

	// TemplateType is the type of policy template.
	// Currently, we only support 'OPAGatekeeper' based policy templates.
	TemplateType string `json:"templateType,omitempty"`
}

VmwareTanzuManageV1alpha1PolicyTemplateSpec Spec of policy template.

swagger:model vmware.tanzu.manage.v1alpha1.policy.template.Spec

func (*VmwareTanzuManageV1alpha1PolicyTemplateSpec) MarshalBinary

func (m *VmwareTanzuManageV1alpha1PolicyTemplateSpec) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation.

func (*VmwareTanzuManageV1alpha1PolicyTemplateSpec) UnmarshalBinary

func (m *VmwareTanzuManageV1alpha1PolicyTemplateSpec) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation.

Jump to

Keyboard shortcuts

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