Documentation ¶
Overview ¶
Package v1alpha1 contains API Schema definitions for the conventions v1alpha1 API group +kubebuilder:object:generate=true
Package v1alpha1 contains API Schema definitions for the conventions v1alpha1 API group +kubebuilder:object:generate=true +groupName=conventions.carto.run
Index ¶
- Constants
- Variables
- func ValidateClientConfig(clientConfig admissionregistrationv1.WebhookClientConfig) validation.FieldErrors
- type ClusterPodConvention
- func (in *ClusterPodConvention) DeepCopy() *ClusterPodConvention
- func (in *ClusterPodConvention) DeepCopyInto(out *ClusterPodConvention)
- func (in *ClusterPodConvention) DeepCopyObject() runtime.Object
- func (r *ClusterPodConvention) Default()
- func (r *ClusterPodConvention) Validate() validation.FieldErrors
- func (r *ClusterPodConvention) ValidateCreate() error
- func (c *ClusterPodConvention) ValidateDelete() error
- func (c *ClusterPodConvention) ValidateUpdate(old runtime.Object) error
- type ClusterPodConventionList
- type ClusterPodConventionSpec
- type ClusterPodConventionWebhook
- type ClusterPodConventionWebhookCertificate
- type ObjectMeta
- func (m *ObjectMeta) AsObjectMeta() metav1.ObjectMeta
- func (in *ObjectMeta) DeepCopy() *ObjectMeta
- func (in *ObjectMeta) DeepCopyInto(out *ObjectMeta)
- func (m *ObjectMeta) GetAnnotations() map[string]string
- func (m *ObjectMeta) GetCreationTimestamp() metav1.Time
- func (m *ObjectMeta) GetDeletionGracePeriodSeconds() *int64
- func (m *ObjectMeta) GetDeletionTimestamp() *metav1.Time
- func (m *ObjectMeta) GetFinalizers() []string
- func (m *ObjectMeta) GetGenerateName() string
- func (m *ObjectMeta) GetGeneration() int64
- func (m *ObjectMeta) GetLabels() map[string]string
- func (m *ObjectMeta) GetManagedFields() []metav1.ManagedFieldsEntry
- func (m *ObjectMeta) GetName() string
- func (m *ObjectMeta) GetNamespace() string
- func (m *ObjectMeta) GetOwnerReferences() []metav1.OwnerReference
- func (m *ObjectMeta) GetResourceVersion() string
- func (m *ObjectMeta) GetSelfLink() string
- func (m *ObjectMeta) GetUID() types.UID
- func (m *ObjectMeta) GetZZZ_DeprecatedClusterName() string
- func (m *ObjectMeta) SetAnnotations(annotations map[string]string)
- func (m *ObjectMeta) SetCreationTimestamp(timestamp metav1.Time)
- func (m *ObjectMeta) SetDeletionGracePeriodSeconds(*int64)
- func (m *ObjectMeta) SetDeletionTimestamp(timestamp *metav1.Time)
- func (m *ObjectMeta) SetFinalizers(finalizers []string)
- func (m *ObjectMeta) SetGenerateName(name string)
- func (m *ObjectMeta) SetGeneration(generation int64)
- func (m *ObjectMeta) SetLabels(labels map[string]string)
- func (m *ObjectMeta) SetManagedFields(managedFields []metav1.ManagedFieldsEntry)
- func (m *ObjectMeta) SetName(name string)
- func (m *ObjectMeta) SetNamespace(namespace string)
- func (m *ObjectMeta) SetOwnerReferences([]metav1.OwnerReference)
- func (m *ObjectMeta) SetResourceVersion(version string)
- func (m *ObjectMeta) SetSelfLink(selfLink string)
- func (m *ObjectMeta) SetUID(uid types.UID)
- func (m *ObjectMeta) SetZZZ_DeprecatedClusterName(clusterName string)
- type PodIntent
- func (in *PodIntent) DeepCopy() *PodIntent
- func (in *PodIntent) DeepCopyInto(out *PodIntent)
- func (in *PodIntent) DeepCopyObject() runtime.Object
- func (r *PodIntent) Default()
- func (s *PodIntent) GetConditionSet() apis.ConditionSet
- func (s *PodIntent) GetConditionsAccessor() apis.ConditionsAccessor
- func (r *PodIntent) Validate() validation.FieldErrors
- func (r *PodIntent) ValidateCreate() error
- func (r *PodIntent) ValidateDelete() error
- func (r *PodIntent) ValidateUpdate(old runtime.Object) error
- type PodIntentList
- type PodIntentSpec
- type PodIntentStatus
- type PodTemplateSpec
- type PriorityLevel
- type SelectorTargetSource
Constants ¶
const ( PodIntentConditionReady = apis.ConditionReady PodIntentConditionConventionsApplied = "ConventionsApplied" )
const (
AppliedConventionsAnnotationKey = "conventions.carto.run/applied-conventions"
)
Variables ¶
var ( // GroupVersion is group version used to register these objects GroupVersion = schema.GroupVersion{Group: "conventions.carto.run", Version: "v1alpha1"} // SchemeBuilder is used to add go types to the GroupVersionKind scheme SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion} // AddToScheme adds the types in this group-version to the given scheme. AddToScheme = SchemeBuilder.AddToScheme )
Functions ¶
func ValidateClientConfig ¶
func ValidateClientConfig(clientConfig admissionregistrationv1.WebhookClientConfig) validation.FieldErrors
Types ¶
type ClusterPodConvention ¶
type ClusterPodConvention struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec ClusterPodConventionSpec `json:"spec"` }
func (*ClusterPodConvention) DeepCopy ¶
func (in *ClusterPodConvention) DeepCopy() *ClusterPodConvention
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterPodConvention.
func (*ClusterPodConvention) DeepCopyInto ¶
func (in *ClusterPodConvention) DeepCopyInto(out *ClusterPodConvention)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ClusterPodConvention) DeepCopyObject ¶
func (in *ClusterPodConvention) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*ClusterPodConvention) Default ¶
func (r *ClusterPodConvention) Default()
Default implements webhook.Defaulter so a webhook will be registered for the type
func (*ClusterPodConvention) Validate ¶
func (r *ClusterPodConvention) Validate() validation.FieldErrors
func (*ClusterPodConvention) ValidateCreate ¶
func (r *ClusterPodConvention) ValidateCreate() error
ValidateCreate implements webhook.Validator so a webhook will be registered for the type
func (*ClusterPodConvention) ValidateDelete ¶
func (c *ClusterPodConvention) ValidateDelete() error
ValidateDelete implements webhook.Validator so a webhook will be registered for the type
func (*ClusterPodConvention) ValidateUpdate ¶
func (c *ClusterPodConvention) ValidateUpdate(old runtime.Object) error
ValidateUpdate implements webhook.Validator so a webhook will be registered for the type
type ClusterPodConventionList ¶
type ClusterPodConventionList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []ClusterPodConvention `json:"items"` }
func (*ClusterPodConventionList) DeepCopy ¶
func (in *ClusterPodConventionList) DeepCopy() *ClusterPodConventionList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterPodConventionList.
func (*ClusterPodConventionList) DeepCopyInto ¶
func (in *ClusterPodConventionList) DeepCopyInto(out *ClusterPodConventionList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ClusterPodConventionList) DeepCopyObject ¶
func (in *ClusterPodConventionList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type ClusterPodConventionSpec ¶
type ClusterPodConventionSpec struct { // Label selector for workloads. // It must match the workload's pod template's labels. Selectors []metav1.LabelSelector `json:"selectors,omitempty"` // +optional SelectorTarget SelectorTargetSource `json:"selectorTarget"` Priority PriorityLevel `json:"priority,omitempty"` Webhook *ClusterPodConventionWebhook `json:"webhook,omitempty"` }
func (*ClusterPodConventionSpec) DeepCopy ¶
func (in *ClusterPodConventionSpec) DeepCopy() *ClusterPodConventionSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterPodConventionSpec.
func (*ClusterPodConventionSpec) DeepCopyInto ¶
func (in *ClusterPodConventionSpec) DeepCopyInto(out *ClusterPodConventionSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ClusterPodConventionSpec) Default ¶
func (s *ClusterPodConventionSpec) Default()
func (*ClusterPodConventionSpec) Validate ¶
func (s *ClusterPodConventionSpec) Validate() validation.FieldErrors
type ClusterPodConventionWebhook ¶
type ClusterPodConventionWebhook struct { // ClientConfig defines how to communicate with the convention. ClientConfig admissionregistrationv1.WebhookClientConfig `json:"clientConfig"` // Certificate references a cert-manager Certificate resource whose CA should be trusted. Certificate *ClusterPodConventionWebhookCertificate `json:"certificate,omitempty"` }
func (*ClusterPodConventionWebhook) DeepCopy ¶
func (in *ClusterPodConventionWebhook) DeepCopy() *ClusterPodConventionWebhook
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterPodConventionWebhook.
func (*ClusterPodConventionWebhook) DeepCopyInto ¶
func (in *ClusterPodConventionWebhook) DeepCopyInto(out *ClusterPodConventionWebhook)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ClusterPodConventionWebhook) Default ¶
func (s *ClusterPodConventionWebhook) Default()
func (*ClusterPodConventionWebhook) Validate ¶
func (s *ClusterPodConventionWebhook) Validate() validation.FieldErrors
type ClusterPodConventionWebhookCertificate ¶ added in v0.1.0
type ClusterPodConventionWebhookCertificate struct { Namespace string `json:"namespace"` Name string `json:"name"` }
func (*ClusterPodConventionWebhookCertificate) DeepCopy ¶ added in v0.1.0
func (in *ClusterPodConventionWebhookCertificate) DeepCopy() *ClusterPodConventionWebhookCertificate
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterPodConventionWebhookCertificate.
func (*ClusterPodConventionWebhookCertificate) DeepCopyInto ¶ added in v0.1.0
func (in *ClusterPodConventionWebhookCertificate) DeepCopyInto(out *ClusterPodConventionWebhookCertificate)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ClusterPodConventionWebhookCertificate) Validate ¶ added in v0.1.0
func (s *ClusterPodConventionWebhookCertificate) Validate() validation.FieldErrors
type ObjectMeta ¶
type ObjectMeta struct { Name string `json:"name,omitempty"` GenerateName string `json:"generateName,omitempty"` Namespace string `json:"namespace,omitempty"` Labels map[string]string `json:"labels,omitempty"` Annotations map[string]string `json:"annotations,omitempty"` }
func (*ObjectMeta) AsObjectMeta ¶
func (m *ObjectMeta) AsObjectMeta() metav1.ObjectMeta
func (*ObjectMeta) DeepCopy ¶
func (in *ObjectMeta) DeepCopy() *ObjectMeta
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ObjectMeta.
func (*ObjectMeta) DeepCopyInto ¶
func (in *ObjectMeta) DeepCopyInto(out *ObjectMeta)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ObjectMeta) GetAnnotations ¶
func (m *ObjectMeta) GetAnnotations() map[string]string
func (*ObjectMeta) GetCreationTimestamp ¶
func (m *ObjectMeta) GetCreationTimestamp() metav1.Time
func (*ObjectMeta) GetDeletionGracePeriodSeconds ¶
func (m *ObjectMeta) GetDeletionGracePeriodSeconds() *int64
func (*ObjectMeta) GetDeletionTimestamp ¶
func (m *ObjectMeta) GetDeletionTimestamp() *metav1.Time
func (*ObjectMeta) GetFinalizers ¶
func (m *ObjectMeta) GetFinalizers() []string
func (*ObjectMeta) GetGenerateName ¶
func (m *ObjectMeta) GetGenerateName() string
func (*ObjectMeta) GetGeneration ¶
func (m *ObjectMeta) GetGeneration() int64
func (*ObjectMeta) GetLabels ¶
func (m *ObjectMeta) GetLabels() map[string]string
func (*ObjectMeta) GetManagedFields ¶
func (m *ObjectMeta) GetManagedFields() []metav1.ManagedFieldsEntry
func (*ObjectMeta) GetName ¶
func (m *ObjectMeta) GetName() string
func (*ObjectMeta) GetNamespace ¶
func (m *ObjectMeta) GetNamespace() string
func (*ObjectMeta) GetOwnerReferences ¶
func (m *ObjectMeta) GetOwnerReferences() []metav1.OwnerReference
func (*ObjectMeta) GetResourceVersion ¶
func (m *ObjectMeta) GetResourceVersion() string
func (*ObjectMeta) GetSelfLink ¶
func (m *ObjectMeta) GetSelfLink() string
func (*ObjectMeta) GetUID ¶
func (m *ObjectMeta) GetUID() types.UID
func (*ObjectMeta) GetZZZ_DeprecatedClusterName ¶ added in v0.1.0
func (m *ObjectMeta) GetZZZ_DeprecatedClusterName() string
func (*ObjectMeta) SetAnnotations ¶
func (m *ObjectMeta) SetAnnotations(annotations map[string]string)
func (*ObjectMeta) SetCreationTimestamp ¶
func (m *ObjectMeta) SetCreationTimestamp(timestamp metav1.Time)
func (*ObjectMeta) SetDeletionGracePeriodSeconds ¶
func (m *ObjectMeta) SetDeletionGracePeriodSeconds(*int64)
func (*ObjectMeta) SetDeletionTimestamp ¶
func (m *ObjectMeta) SetDeletionTimestamp(timestamp *metav1.Time)
func (*ObjectMeta) SetFinalizers ¶
func (m *ObjectMeta) SetFinalizers(finalizers []string)
func (*ObjectMeta) SetGenerateName ¶
func (m *ObjectMeta) SetGenerateName(name string)
func (*ObjectMeta) SetGeneration ¶
func (m *ObjectMeta) SetGeneration(generation int64)
func (*ObjectMeta) SetLabels ¶
func (m *ObjectMeta) SetLabels(labels map[string]string)
func (*ObjectMeta) SetManagedFields ¶
func (m *ObjectMeta) SetManagedFields(managedFields []metav1.ManagedFieldsEntry)
func (*ObjectMeta) SetName ¶
func (m *ObjectMeta) SetName(name string)
func (*ObjectMeta) SetNamespace ¶
func (m *ObjectMeta) SetNamespace(namespace string)
func (*ObjectMeta) SetOwnerReferences ¶
func (m *ObjectMeta) SetOwnerReferences([]metav1.OwnerReference)
func (*ObjectMeta) SetResourceVersion ¶
func (m *ObjectMeta) SetResourceVersion(version string)
func (*ObjectMeta) SetSelfLink ¶
func (m *ObjectMeta) SetSelfLink(selfLink string)
func (*ObjectMeta) SetUID ¶
func (m *ObjectMeta) SetUID(uid types.UID)
func (*ObjectMeta) SetZZZ_DeprecatedClusterName ¶ added in v0.1.0
func (m *ObjectMeta) SetZZZ_DeprecatedClusterName(clusterName string)
type PodIntent ¶
type PodIntent struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec PodIntentSpec `json:"spec"` // +optional Status PodIntentStatus `json:"status"` }
func (*PodIntent) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PodIntent.
func (*PodIntent) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*PodIntent) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*PodIntent) Default ¶
func (r *PodIntent) Default()
Default implements webhook.Defaulter so a webhook will be registered for the type
func (*PodIntent) GetConditionSet ¶
func (s *PodIntent) GetConditionSet() apis.ConditionSet
func (*PodIntent) GetConditionsAccessor ¶
func (s *PodIntent) GetConditionsAccessor() apis.ConditionsAccessor
func (*PodIntent) Validate ¶
func (r *PodIntent) Validate() validation.FieldErrors
func (*PodIntent) ValidateCreate ¶
ValidateCreate implements webhook.Validator so a webhook will be registered for the type
func (*PodIntent) ValidateDelete ¶
ValidateDelete implements webhook.Validator so a webhook will be registered for the type
type PodIntentList ¶
type PodIntentList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []PodIntent `json:"items"` }
func (*PodIntentList) DeepCopy ¶
func (in *PodIntentList) DeepCopy() *PodIntentList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PodIntentList.
func (*PodIntentList) DeepCopyInto ¶
func (in *PodIntentList) DeepCopyInto(out *PodIntentList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*PodIntentList) DeepCopyObject ¶
func (in *PodIntentList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type PodIntentSpec ¶
type PodIntentSpec struct { // ServiceAccountName is the name of the Kubernetes ServiceAccount used to authenticate // the image pull if the service account has attached pull secrets. For more information: // https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/#add-imagepullsecrets-to-a-service-account // +optional ServiceAccountName string `json:"serviceAccountName,omitempty"` // ImagePullSecrets contains the names of the Kubernetes Secrets containing registry login // information to resolve image metadata. // +optional ImagePullSecrets []corev1.LocalObjectReference `json:"imagePullSecrets,omitempty"` // Template defines the workload pod temple Template PodTemplateSpec `json:"template"` }
func (*PodIntentSpec) DeepCopy ¶
func (in *PodIntentSpec) DeepCopy() *PodIntentSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PodIntentSpec.
func (*PodIntentSpec) DeepCopyInto ¶
func (in *PodIntentSpec) DeepCopyInto(out *PodIntentSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*PodIntentSpec) Default ¶
func (s *PodIntentSpec) Default()
func (*PodIntentSpec) Validate ¶
func (s *PodIntentSpec) Validate() validation.FieldErrors
type PodIntentStatus ¶
type PodIntentStatus struct { apis.Status `json:",inline"` Template *PodTemplateSpec `json:"template,omitempty"` }
func (*PodIntentStatus) DeepCopy ¶
func (in *PodIntentStatus) DeepCopy() *PodIntentStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PodIntentStatus.
func (*PodIntentStatus) DeepCopyInto ¶
func (in *PodIntentStatus) DeepCopyInto(out *PodIntentStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*PodIntentStatus) InitializeConditions ¶
func (s *PodIntentStatus) InitializeConditions()
type PodTemplateSpec ¶
type PodTemplateSpec struct { ObjectMeta `json:"metadata,omitempty"` Spec corev1.PodSpec `json:"spec,omitempty"` }
PodTemplateSpec mirrors corev1.PodTemplateSpec with a simplified ObjectMeta. This hacks around an issue with controller-gen where it doesn't generate the correct structural scheme that results in all ObjectMeta fields being lost. See https://github.com/kubernetes-sigs/controller-tools/issues/448
func NewPodTemplateSpec ¶
func NewPodTemplateSpec(pts *corev1.PodTemplateSpec) *PodTemplateSpec
func (*PodTemplateSpec) AsPodTemplateSpec ¶
func (p *PodTemplateSpec) AsPodTemplateSpec() *corev1.PodTemplateSpec
func (*PodTemplateSpec) DeepCopy ¶
func (in *PodTemplateSpec) DeepCopy() *PodTemplateSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PodTemplateSpec.
func (*PodTemplateSpec) DeepCopyInto ¶
func (in *PodTemplateSpec) DeepCopyInto(out *PodTemplateSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*PodTemplateSpec) GetObjectMeta ¶
func (p *PodTemplateSpec) GetObjectMeta() metav1.Object
type PriorityLevel ¶
type PriorityLevel string
const ( // EarlyPriority defines Early priority level for ClusterPodConvention EarlyPriority PriorityLevel = "Early" // NormalPriority defines Normal priority level for ClusterPodConvention NormalPriority PriorityLevel = "Normal" // LatePriority defines Late priority level for ClusterPodConvention LatePriority PriorityLevel = "Late" )
type SelectorTargetSource ¶ added in v0.2.0
type SelectorTargetSource string
const ( PodTemplateSpecLabels SelectorTargetSource = "PodTemplateSpec" PodIntentLabels SelectorTargetSource = "PodIntent" )