v1alpha2

package
v0.2.2 Latest Latest
Warning

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

Go to latest
Published: May 21, 2024 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Overview

Package v1alpha2 contains API Schema definitions for the v1alpha2 API group. +k8s:deepcopy-gen=package +k8s:conversion-gen=github.com/kyverno/chainsaw/pkg/apis/v1alpha1 +kubebuilder:object:generate=true +groupName=chainsaw.kyverno.io

Index

Constants

View Source
const GroupName = "chainsaw.kyverno.io"

GroupName specifies the group name used to register the objects.

Variables

View Source
var (
	// localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes.
	SchemeBuilder runtime.SchemeBuilder

	// Depreciated: use Install instead
	AddToScheme = localSchemeBuilder.AddToScheme
	Install     = localSchemeBuilder.AddToScheme
)
View Source
var GroupVersion = v1.GroupVersion{Group: GroupName, Version: "v1alpha2"}

GroupVersion specifies the group and the version used to register the objects.

View Source
var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1alpha2"}

SchemeGroupVersion is group version used to register these objects Deprecated: use GroupVersion instead.

Functions

func Convert_v1alpha1_ConfigurationSpec_To_v1alpha2_ConfigurationSpec

func Convert_v1alpha1_ConfigurationSpec_To_v1alpha2_ConfigurationSpec(in *v1alpha1.ConfigurationSpec, out *ConfigurationSpec, _ conversion.Scope) error

func Convert_v1alpha1_Configuration_To_v1alpha2_Configuration

func Convert_v1alpha1_Configuration_To_v1alpha2_Configuration(in *v1alpha1.Configuration, out *Configuration, s conversion.Scope) error

Convert_v1alpha1_Configuration_To_v1alpha2_Configuration is an autogenerated conversion function.

func Convert_v1alpha2_ConfigurationSpec_To_v1alpha1_ConfigurationSpec

func Convert_v1alpha2_ConfigurationSpec_To_v1alpha1_ConfigurationSpec(in *ConfigurationSpec, out *v1alpha1.ConfigurationSpec, _ conversion.Scope) error

func Convert_v1alpha2_Configuration_To_v1alpha1_Configuration

func Convert_v1alpha2_Configuration_To_v1alpha1_Configuration(in *Configuration, out *v1alpha1.Configuration, s conversion.Scope) error

Convert_v1alpha2_Configuration_To_v1alpha1_Configuration is an autogenerated conversion function.

func RegisterConversions

func RegisterConversions(s *runtime.Scheme) error

RegisterConversions adds conversion functions to the given scheme. Public to allow building arbitrary schemes.

func Resource

func Resource(resource string) schema.GroupResource

Resource takes an unqualified resource and returns a Group qualified GroupResource

Types

type Any

type Any = v1alpha1.Any

type Catch

type Catch = v1alpha1.Catch

type Cleanup

type Cleanup struct {
	// If set, do not delete the resources after running a test.
	// +optional
	SkipDelete bool `json:"skipDelete,omitempty"`

	// DelayBeforeCleanup adds a delay between the time a test ends and the time cleanup starts.
	// +optional
	DelayBeforeCleanup *metav1.Duration `json:"delayBeforeCleanup,omitempty"`
}

Cleanup contains the cleanup configuration.

func (*Cleanup) DeepCopy

func (in *Cleanup) DeepCopy() *Cleanup

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

func (*Cleanup) DeepCopyInto

func (in *Cleanup) DeepCopyInto(out *Cleanup)

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

type Cluster

type Cluster = v1alpha1.Cluster

type Configuration

type Configuration struct {
	metav1.TypeMeta `json:",inline"`

	// Standard object's metadata.
	// +optional
	metav1.ObjectMeta `json:"metadata,omitempty"`

	// Configuration spec.
	Spec ConfigurationSpec `json:"spec"`
}

Configuration is the resource that contains the configuration used to run tests.

func (*Configuration) DeepCopy

func (in *Configuration) DeepCopy() *Configuration

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

func (*Configuration) DeepCopyInto

func (in *Configuration) DeepCopyInto(out *Configuration)

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

func (*Configuration) DeepCopyObject

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

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

type ConfigurationSpec

type ConfigurationSpec struct {
	// Catch defines what the tests steps will execute when an error happens.
	// This will be combined with catch handlers defined at the test and step levels.
	// +optional
	Catch []Catch `json:"catch,omitempty"`

	// Cleanup contains cleanup configuration.
	// +optional
	Cleanup *Cleanup `json:"cleanup,omitempty"`

	// Clusters holds a registry to clusters to support multi-cluster tests.
	// +optional
	Clusters map[string]Cluster `json:"clusters,omitempty"`

	// Discovery contains tests discovery configuration.
	// +optional
	Discovery *Discovery `json:"discovery,omitempty"`

	// Execution contains tests execution configuration.
	// +optional
	Execution *Execution `json:"execution,omitempty"`

	// Namespace contains properties for the namespace to use for tests.
	// +optional
	Namespace *Namespace `json:"namespace,omitempty"`

	// Report contains properties for the report.
	// +optional
	Report *Report `json:"report,omitempty"`

	// Templating contains the templating config.
	// +optional
	Templating *Templating `json:"templating,omitempty"`

	// Global timeouts configuration. Applies to all tests/test steps if not overridden.
	// +optional
	Timeouts Timeouts `json:"timeouts"`
}

ConfigurationSpec contains the configuration used to run tests. +k8s:conversion-gen=false

func (*ConfigurationSpec) DeepCopy

func (in *ConfigurationSpec) DeepCopy() *ConfigurationSpec

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

func (*ConfigurationSpec) DeepCopyInto

func (in *ConfigurationSpec) DeepCopyInto(out *ConfigurationSpec)

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

type Discovery

type Discovery struct {
	// ExcludeTestRegex is used to exclude tests based on a regular expression.
	// +optional
	ExcludeTestRegex string `json:"excludeTestRegex,omitempty"`

	// IncludeTestRegex is used to include tests based on a regular expression.
	// +optional
	IncludeTestRegex string `json:"includeTestRegex,omitempty"`

	// TestFile is the name of the file containing the test to run.
	// If no extension is provided, chainsaw will try with .yaml first and .yml if needed.
	// +kubebuilder:default:="chainsaw-test"
	// +optional
	TestFile string `json:"testFile,omitempty"`

	// FullName makes use of the full test case folder path instead of the folder name.
	// +optional
	FullName bool `json:"fullName,omitempty"`
}

Discovery contains the tests discovery configuration.

func (*Discovery) DeepCopy

func (in *Discovery) DeepCopy() *Discovery

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

func (*Discovery) DeepCopyInto

func (in *Discovery) DeepCopyInto(out *Discovery)

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

type Execution

type Execution struct {
	// FailFast determines whether the test should stop upon encountering the first failure.
	// +optional
	FailFast bool `json:"failFast,omitempty"`

	// The maximum number of tests to run at once.
	// +kubebuilder:validation:Format:=int
	// +kubebuilder:validation:Minimum:=1
	// +optional
	Parallel *int `json:"parallel,omitempty"`

	// RepeatCount indicates how many times the tests should be executed.
	// +kubebuilder:validation:Format:=int
	// +kubebuilder:validation:Minimum:=1
	// +optional
	RepeatCount *int `json:"repeatCount,omitempty"`

	// ForceTerminationGracePeriod forces the termination grace period on pods, statefulsets, daemonsets and deployments.
	// +optional
	ForceTerminationGracePeriod *metav1.Duration `json:"forceTerminationGracePeriod,omitempty"`
}

Execution contains the runner configuration.

func (*Execution) DeepCopy

func (in *Execution) DeepCopy() *Execution

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

func (*Execution) DeepCopyInto

func (in *Execution) DeepCopyInto(out *Execution)

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

type Namespace

type Namespace struct {
	// Name defines the namespace to use for tests.
	// If not specified, every test will execute in a random ephemeral namespace
	// unless the namespace is overridden in a the test spec.
	// +optional
	Name string `json:"name,omitempty"`

	// Template defines a template to create the test namespace.
	// +optional
	Template *Any `json:"template,omitempty"`
}

Namespace contains info about the namespace used for testing.

func (*Namespace) DeepCopy

func (in *Namespace) DeepCopy() *Namespace

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

func (*Namespace) DeepCopyInto

func (in *Namespace) DeepCopyInto(out *Namespace)

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

type Report

type Report struct {
	// ReportFormat determines test report format (JSON|XML).
	// +optional
	// +kubebuilder:validation:Enum:=JSON;XML
	// +kubebuilder:default:="JSON"
	Format ReportFormatType `json:"format,omitempty"`

	// ReportPath defines the path.
	// +optional
	Path string `json:"path,omitempty"`

	// ReportName defines the name of report to create. It defaults to "chainsaw-report".
	// +optional
	// +kubebuilder:default:="chainsaw-report"
	Name string `json:"name,omitempty"`
}

Report contains info about the report.

func (*Report) DeepCopy

func (in *Report) DeepCopy() *Report

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

func (*Report) DeepCopyInto

func (in *Report) DeepCopyInto(out *Report)

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

type ReportFormatType

type ReportFormatType string
const (
	JSONFormat ReportFormatType = "JSON"
	XMLFormat  ReportFormatType = "XML"
)

type Templating

type Templating struct {
	// Enabled determines whether resources should be considered for templating.
	// +optional
	Enabled *bool `json:"enabled,omitempty"`
}

Templating contains the templating configuration.

func (*Templating) DeepCopy

func (in *Templating) DeepCopy() *Templating

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

func (*Templating) DeepCopyInto

func (in *Templating) DeepCopyInto(out *Templating)

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

type Timeouts

type Timeouts = v1alpha1.Timeouts

Jump to

Keyboard shortcuts

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