mirror of
https://github.com/YuzuZensai/netbird-kubernetes-operator.git
synced 2026-09-13 18:59:09 +00:00
71 lines
3.1 KiB
Go
71 lines
3.1 KiB
Go
// Code generated by controller-gen. DO NOT EDIT.
|
|||
|
|
|
||
|
|
package v1alpha1
|
||
|
|
|
||
|
|
import (
|
||
|
|
v1 "k8s.io/api/core/v1"
|
||
|
|
)
|
||
|
|
|
||
|
|
// DeploymentOverrideApplyConfiguration represents a declarative configuration of the DeploymentOverride type for use
|
||
|
|
// with apply.
|
||
|
|
type DeploymentOverrideApplyConfiguration struct {
|
||
|
|
// Labels that will be added to the deployment.
|
||
|
|
Labels map[string]string `json:"labels,omitempty"`
|
||
|
|
// Annotations that will be added to the deployment.
|
||
|
|
Annotations map[string]string `json:"annotations,omitempty"`
|
||
|
|
// Replicas set for the deployment.
|
||
|
|
Replicas *int32 `json:"replicas,omitempty"`
|
||
|
|
// PodTemplate overrides the deployment pod template.
|
||
|
|
PodTemplate *v1.PodTemplateSpec `json:"podTemplate,omitempty"`
|
||
|
|
}
|
||
|
|
|
||
|
|
// DeploymentOverrideApplyConfiguration constructs a declarative configuration of the DeploymentOverride type for use with
|
||
|
|
// apply.
|
||
|
|
func DeploymentOverride() *DeploymentOverrideApplyConfiguration {
|
||
|
|
return &DeploymentOverrideApplyConfiguration{}
|
||
|
|
}
|
||
|
|
|
||
|
|
// WithLabels puts the entries into the Labels field in the declarative configuration
|
||
|
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||
|
|
// If called multiple times, the entries provided by each call will be put on the Labels field,
|
||
|
|
// overwriting an existing map entries in Labels field with the same key.
|
||
|
|
func (b *DeploymentOverrideApplyConfiguration) WithLabels(entries map[string]string) *DeploymentOverrideApplyConfiguration {
|
||
|
|
if b.Labels == nil && len(entries) > 0 {
|
||
|
|
b.Labels = make(map[string]string, len(entries))
|
||
|
|
}
|
||
|
|
for k, v := range entries {
|
||
|
|
b.Labels[k] = v
|
||
|
|
}
|
||
|
|
return b
|
||
|
|
}
|
||
|
|
|
||
|
|
// WithAnnotations puts the entries into the Annotations field in the declarative configuration
|
||
|
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||
|
|
// If called multiple times, the entries provided by each call will be put on the Annotations field,
|
||
|
|
// overwriting an existing map entries in Annotations field with the same key.
|
||
|
|
func (b *DeploymentOverrideApplyConfiguration) WithAnnotations(entries map[string]string) *DeploymentOverrideApplyConfiguration {
|
||
|
|
if b.Annotations == nil && len(entries) > 0 {
|
||
|
|
b.Annotations = make(map[string]string, len(entries))
|
||
|
|
}
|
||
|
|
for k, v := range entries {
|
||
|
|
b.Annotations[k] = v
|
||
|
|
}
|
||
|
|
return b
|
||
|
|
}
|
||
|
|
|
||
|
|
// WithReplicas sets the Replicas field in the declarative configuration to the given value
|
||
|
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||
|
|
// If called multiple times, the Replicas field is set to the value of the last call.
|
||
|
|
func (b *DeploymentOverrideApplyConfiguration) WithReplicas(value int32) *DeploymentOverrideApplyConfiguration {
|
||
|
|
b.Replicas = &value
|
||
|
|
return b
|
||
|
|
}
|
||
|
|
|
||
|
|
// WithPodTemplate sets the PodTemplate field in the declarative configuration to the given value
|
||
|
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||
|
|
// If called multiple times, the PodTemplate field is set to the value of the last call.
|
||
|
|
func (b *DeploymentOverrideApplyConfiguration) WithPodTemplate(value v1.PodTemplateSpec) *DeploymentOverrideApplyConfiguration {
|
||
|
|
b.PodTemplate = &value
|
||
|
|
return b
|
||
|
|
}
|