v1beta1

package
v0.9.5 Latest Latest
Warning

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

Go to latest
Published: Dec 15, 2020 License: Apache-2.0 Imports: 6 Imported by: 0

README

Image Policy CRD (CustomResourceDefinition)

Regenerate the CRD files with code-generator

You ONLY need to do this if you are a developer AND you are changing the design of the CRD Policies, otherwise you DO NOT need to do this.

We use some scripts from the k8s.io/code-generator repository to generate the clientset, informers, listers and deep-copy functions.

Prerequisites

Clone the code-generator repo compatible with apis used

make code-generator
Generate the CRDs
make regenerate

Documentation

Overview

Package v1beta1 is the v1beta1 version of the API. +groupName=securityenforcement.admission.cloud.ibm.com

Index

Constants

This section is empty.

Variables

View Source
var (
	// SchemeBuilder .
	SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes)
	// AddToScheme .
	AddToScheme = SchemeBuilder.AddToScheme
)
View Source
var (
	// TruePointer - pointer to a boolwan value of true
	TruePointer = boolPointer(true)
	// FalsePointer - pointer to a boolwan value of false
	FalsePointer = boolPointer(false)
)
View Source
var SchemeGroupVersion = schema.GroupVersion{Group: securityenforcement.GroupName, Version: "v1beta1"}

SchemeGroupVersion is group version used to register these objects

Functions

func Kind

func Kind(kind string) schema.GroupKind

Kind takes an unqualified kind and returns back a Group qualified GroupKind

func Resource

func Resource(resource string) schema.GroupResource

Resource takes an unqualified resource and returns a Group qualified GroupResource

Types

type ClusterImagePolicy

type ClusterImagePolicy struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec PolicySpec `json:"spec"`
}

ClusterImagePolicy is a specification for a ClusterImagePolicy resource

func (*ClusterImagePolicy) DeepCopy

func (in *ClusterImagePolicy) DeepCopy() *ClusterImagePolicy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterImagePolicy.

func (*ClusterImagePolicy) DeepCopyInto

func (in *ClusterImagePolicy) DeepCopyInto(out *ClusterImagePolicy)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ClusterImagePolicy) DeepCopyObject

func (in *ClusterImagePolicy) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type ClusterImagePolicyList

type ClusterImagePolicyList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata"`

	Items []ClusterImagePolicy `json:"items"`
}

ClusterImagePolicyList is a list of ClusterImagePolicy resources

func (*ClusterImagePolicyList) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterImagePolicyList.

func (*ClusterImagePolicyList) DeepCopyInto

func (in *ClusterImagePolicyList) DeepCopyInto(out *ClusterImagePolicyList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ClusterImagePolicyList) DeepCopyObject

func (in *ClusterImagePolicyList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (ClusterImagePolicyList) FindClusterImagePolicy

func (apl ClusterImagePolicyList) FindClusterImagePolicy(image string) *Policy

FindClusterImagePolicy - Given an ClusterImagePolicyList, find the repository whose name most closely matches the image name, and returns its policy. If there are no matches, return a nil value.

type ICCRVA

type ICCRVA struct {
	Enabled *bool  `json:"enabled,omitempty"`
	Account string `json:"account,omitempty"`
}

ICCRVA IBM Cloud Container Registry Vulnerability Advisor policy

func (*ICCRVA) DeepCopy

func (in *ICCRVA) DeepCopy() *ICCRVA

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ICCRVA.

func (*ICCRVA) DeepCopyInto

func (in *ICCRVA) DeepCopyInto(out *ICCRVA)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type IdentityRequirement

type IdentityRequirement struct {
	Type             string `json:"type"`
	DockerReference  string `json:"dockerReference,omitEmpty"`
	DockerRepository string `json:"dockerRepository,omitEmpty"`
	Prefix           string `json:"prefix,omitEmpty"`
	SignedPrefix     string `json:"signedPrefix,omitEmpty"`
}

IdentityRequirement .

func (*IdentityRequirement) DeepCopy

func (in *IdentityRequirement) DeepCopy() *IdentityRequirement

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IdentityRequirement.

func (*IdentityRequirement) DeepCopyInto

func (in *IdentityRequirement) DeepCopyInto(out *IdentityRequirement)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ImagePolicy

type ImagePolicy struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec PolicySpec `json:"spec"`
}

ImagePolicy is a specification for a ImagePolicy resource

func (*ImagePolicy) DeepCopy

func (in *ImagePolicy) DeepCopy() *ImagePolicy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ImagePolicy.

func (*ImagePolicy) DeepCopyInto

func (in *ImagePolicy) DeepCopyInto(out *ImagePolicy)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ImagePolicy) DeepCopyObject

func (in *ImagePolicy) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type ImagePolicyList

type ImagePolicyList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata"`

	Items []ImagePolicy `json:"items"`
}

ImagePolicyList is a list of ImagePolicy resources

func (*ImagePolicyList) DeepCopy

func (in *ImagePolicyList) DeepCopy() *ImagePolicyList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ImagePolicyList.

func (*ImagePolicyList) DeepCopyInto

func (in *ImagePolicyList) DeepCopyInto(out *ImagePolicyList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ImagePolicyList) DeepCopyObject

func (in *ImagePolicyList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (ImagePolicyList) FindImagePolicy

func (apl ImagePolicyList) FindImagePolicy(image string) *Policy

FindImagePolicy - Given an ImagePolicyList, find the repository whose name most closely matches the image name, and returns its policy. If there are no matches, return a nil value.

type Policy

type Policy struct {
	Trust         Trust         `json:"trust,omitempty"`
	Simple        Simple        `json:"simple,omitempty"`
	Vulnerability Vulnerability `json:"vulnerability,omitempty"`
}

Policy .

func (*Policy) DeepCopy

func (in *Policy) DeepCopy() *Policy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Policy.

func (*Policy) DeepCopyInto

func (in *Policy) DeepCopyInto(out *Policy)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type PolicySpec

type PolicySpec struct {
	Repositories []Repository `json:"repositories"`
}

PolicySpec is the spec for a ImagePolicy or ClusterImagePolicy resource

func (*PolicySpec) DeepCopy

func (in *PolicySpec) DeepCopy() *PolicySpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PolicySpec.

func (*PolicySpec) DeepCopyInto

func (in *PolicySpec) DeepCopyInto(out *PolicySpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Repository

type Repository struct {
	Name   string `json:"name,omitempty"` // Name may contain a * to signify one or more characters
	Policy Policy `json:"policy,omitempty"`
}

Repository .

func (*Repository) DeepCopy

func (in *Repository) DeepCopy() *Repository

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Repository.

func (*Repository) DeepCopyInto

func (in *Repository) DeepCopyInto(out *Repository)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Signer

type Signer struct {
	Name string `json:"name"`
}

Signer .

func (*Signer) DeepCopy

func (in *Signer) DeepCopy() *Signer

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Signer.

func (*Signer) DeepCopyInto

func (in *Signer) DeepCopyInto(out *Signer)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Simple

type Simple struct {
	Requirements []SimpleRequirement `json:"requirements"`
	StoreURL     string              `json:"storeURL,omitEmpty"`
	StoreSecret  string              `json:"storeSecret,omitEmpty"`
}

Simple .

func (*Simple) DeepCopy

func (in *Simple) DeepCopy() *Simple

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Simple.

func (*Simple) DeepCopyInto

func (in *Simple) DeepCopyInto(out *Simple)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type SimpleRequirement

type SimpleRequirement struct {
	Type           string              `json:"type"`
	KeySecret      string              `json:"keySecret,omitEmpty"`
	SignedIdentity IdentityRequirement `json:"signedIdentity,omitEmpty"`
}

SimpleRequirement .

func (*SimpleRequirement) DeepCopy

func (in *SimpleRequirement) DeepCopy() *SimpleRequirement

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SimpleRequirement.

func (*SimpleRequirement) DeepCopyInto

func (in *SimpleRequirement) DeepCopyInto(out *SimpleRequirement)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Trust

type Trust struct {
	Enabled       *bool    `json:"enabled,omitempty"`
	SignerSecrets []Signer `json:"signerSecrets,omitempty"`
	TrustServer   string   `json:"trustServer,omitempty"`
}

Trust .

func (*Trust) DeepCopy

func (in *Trust) DeepCopy() *Trust

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Trust.

func (*Trust) DeepCopyInto

func (in *Trust) DeepCopyInto(out *Trust)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Vulnerability

type Vulnerability struct {
	ICCRVA ICCRVA `json:"ICCRVA,omitempty"`
}

Vulnerability policy

func (*Vulnerability) DeepCopy

func (in *Vulnerability) DeepCopy() *Vulnerability

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Vulnerability.

func (*Vulnerability) DeepCopyInto

func (in *Vulnerability) DeepCopyInto(out *Vulnerability)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

Jump to

Keyboard shortcuts

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