v1alpha1

package
v0.7.1 Latest Latest
Warning

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

Go to latest
Published: Oct 29, 2021 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package v1alpha1 is the v1alpha1 version of the API. +groupName=chaos.szlabs.com

Index

Constants

View Source
const (
	PodTerminatorKind       = "PodTerminator"
	PodTerminatorName       = "podterminator"
	PodTerminatorNamePlural = "podterminators"
	PodTerminatorScope      = apiextensionsv1.ClusterScoped
)

PodTerminator constants

Variables

View Source
var (
	SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes)
	AddToScheme   = SchemeBuilder.AddToScheme
)
View Source
var PodTerminatorShortNames = []string{"pt", "ptc", "pto"}

PodTerminatorShortNames is used to register resource short names

View Source
var SchemeGroupVersion = schema.GroupVersion{Group: podterminatoroperatorchaos.GroupName, Version: version}

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

func VersionKind

func VersionKind(kind string) schema.GroupVersionKind

VersionKind takes an unqualified kind and returns back a Group qualified GroupVersionKind

Types

type PodTerminator

type PodTerminator struct {
	metav1.TypeMeta `json:",inline"`
	// Standard object's metadata.
	// More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata
	// +optional
	metav1.ObjectMeta `json:"metadata,omitempty"`

	// Specification of the ddesired behaviour of the pod terminator.
	// More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status
	// +optional
	Spec PodTerminatorSpec `json:"spec,omitempty"`
}

PodTerminator represents a pod terminator.

func (*PodTerminator) DeepCopy

func (in *PodTerminator) DeepCopy() *PodTerminator

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

func (*PodTerminator) DeepCopyInto

func (in *PodTerminator) DeepCopyInto(out *PodTerminator)

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

func (*PodTerminator) DeepCopyObject

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

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

type PodTerminatorList

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

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

PodTerminatorList is a list of PodTerminator resources

func (*PodTerminatorList) DeepCopy

func (in *PodTerminatorList) DeepCopy() *PodTerminatorList

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

func (*PodTerminatorList) DeepCopyInto

func (in *PodTerminatorList) DeepCopyInto(out *PodTerminatorList)

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

func (*PodTerminatorList) DeepCopyObject

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

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

type PodTerminatorSpec

type PodTerminatorSpec struct {
	// Selector is how the target will be selected.
	Selector map[string]string `json:"selector,omitempty"`
	// PeriodSeconds is how often (in seconds) to perform the attack.
	PeriodSeconds int32 `json:"periodSeconds,omitempty"`
	// TerminationPercent is the percent of pods that will be killed randomly.
	TerminationPercent int32 `json:"terminationPercent,omitempty"`
	// MinimumInstances is the number of minimum instances that need to be alive.
	// +optional
	MinimumInstances int32 `json:"minimumInstances,omitempty"`
	// DryRun will set the killing in dryrun mode or not.
	// +optional
	DryRun bool `json:"dryRun,omitempty"`
}

PodTerminatorSpec is the spec for a PodTerminator resource.

func (*PodTerminatorSpec) DeepCopy

func (in *PodTerminatorSpec) DeepCopy() *PodTerminatorSpec

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

func (*PodTerminatorSpec) DeepCopyInto

func (in *PodTerminatorSpec) DeepCopyInto(out *PodTerminatorSpec)

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