build source
This commit is contained in:
commit
ee1fec43ed
4171 changed files with 1351288 additions and 0 deletions
141
vendor/k8s.io/client-go/applyconfigurations/discovery/v1/endpoint.go
generated
vendored
Normal file
141
vendor/k8s.io/client-go/applyconfigurations/discovery/v1/endpoint.go
generated
vendored
Normal file
|
|
@ -0,0 +1,141 @@
|
|||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||
|
||||
package v1
|
||||
|
||||
import (
|
||||
corev1 "k8s.io/client-go/applyconfigurations/core/v1"
|
||||
)
|
||||
|
||||
// EndpointApplyConfiguration represents a declarative configuration of the Endpoint type for use
|
||||
// with apply.
|
||||
//
|
||||
// Endpoint represents a single logical "backend" implementing a service.
|
||||
type EndpointApplyConfiguration struct {
|
||||
// addresses of this endpoint. For EndpointSlices of addressType "IPv4" or "IPv6",
|
||||
// the values are IP addresses in canonical form. The syntax and semantics of
|
||||
// other addressType values are not defined. This must contain at least one
|
||||
// address but no more than 100. EndpointSlices generated by the EndpointSlice
|
||||
// controller will always have exactly 1 address. No semantics are defined for
|
||||
// additional addresses beyond the first, and kube-proxy does not look at them.
|
||||
Addresses []string `json:"addresses,omitempty"`
|
||||
// conditions contains information about the current status of the endpoint.
|
||||
Conditions *EndpointConditionsApplyConfiguration `json:"conditions,omitempty"`
|
||||
// hostname of this endpoint. This field may be used by consumers of
|
||||
// endpoints to distinguish endpoints from each other (e.g. in DNS names).
|
||||
// Multiple endpoints which use the same hostname should be considered
|
||||
// fungible (e.g. multiple A values in DNS). Must be lowercase and pass DNS
|
||||
// Label (RFC 1123) validation.
|
||||
Hostname *string `json:"hostname,omitempty"`
|
||||
// targetRef is a reference to a Kubernetes object that represents this
|
||||
// endpoint.
|
||||
TargetRef *corev1.ObjectReferenceApplyConfiguration `json:"targetRef,omitempty"`
|
||||
// deprecatedTopology contains topology information part of the v1beta1
|
||||
// API. This field is deprecated, and will be removed when the v1beta1
|
||||
// API is removed (no sooner than kubernetes v1.24). While this field can
|
||||
// hold values, it is not writable through the v1 API, and any attempts to
|
||||
// write to it will be silently ignored. Topology information can be found
|
||||
// in the zone and nodeName fields instead.
|
||||
DeprecatedTopology map[string]string `json:"deprecatedTopology,omitempty"`
|
||||
// nodeName represents the name of the Node hosting this endpoint. This can
|
||||
// be used to determine endpoints local to a Node.
|
||||
NodeName *string `json:"nodeName,omitempty"`
|
||||
// zone is the name of the Zone this endpoint exists in.
|
||||
Zone *string `json:"zone,omitempty"`
|
||||
// hints contains information associated with how an endpoint should be
|
||||
// consumed.
|
||||
Hints *EndpointHintsApplyConfiguration `json:"hints,omitempty"`
|
||||
}
|
||||
|
||||
// EndpointApplyConfiguration constructs a declarative configuration of the Endpoint type for use with
|
||||
// apply.
|
||||
func Endpoint() *EndpointApplyConfiguration {
|
||||
return &EndpointApplyConfiguration{}
|
||||
}
|
||||
|
||||
// WithAddresses adds the given value to the Addresses field in the declarative configuration
|
||||
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||
// If called multiple times, values provided by each call will be appended to the Addresses field.
|
||||
func (b *EndpointApplyConfiguration) WithAddresses(values ...string) *EndpointApplyConfiguration {
|
||||
for i := range values {
|
||||
b.Addresses = append(b.Addresses, values[i])
|
||||
}
|
||||
return b
|
||||
}
|
||||
|
||||
// WithConditions sets the Conditions 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 Conditions field is set to the value of the last call.
|
||||
func (b *EndpointApplyConfiguration) WithConditions(value *EndpointConditionsApplyConfiguration) *EndpointApplyConfiguration {
|
||||
b.Conditions = value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithHostname sets the Hostname 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 Hostname field is set to the value of the last call.
|
||||
func (b *EndpointApplyConfiguration) WithHostname(value string) *EndpointApplyConfiguration {
|
||||
b.Hostname = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithTargetRef sets the TargetRef 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 TargetRef field is set to the value of the last call.
|
||||
func (b *EndpointApplyConfiguration) WithTargetRef(value *corev1.ObjectReferenceApplyConfiguration) *EndpointApplyConfiguration {
|
||||
b.TargetRef = value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithDeprecatedTopology puts the entries into the DeprecatedTopology 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 DeprecatedTopology field,
|
||||
// overwriting an existing map entries in DeprecatedTopology field with the same key.
|
||||
func (b *EndpointApplyConfiguration) WithDeprecatedTopology(entries map[string]string) *EndpointApplyConfiguration {
|
||||
if b.DeprecatedTopology == nil && len(entries) > 0 {
|
||||
b.DeprecatedTopology = make(map[string]string, len(entries))
|
||||
}
|
||||
for k, v := range entries {
|
||||
b.DeprecatedTopology[k] = v
|
||||
}
|
||||
return b
|
||||
}
|
||||
|
||||
// WithNodeName sets the NodeName 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 NodeName field is set to the value of the last call.
|
||||
func (b *EndpointApplyConfiguration) WithNodeName(value string) *EndpointApplyConfiguration {
|
||||
b.NodeName = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithZone sets the Zone 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 Zone field is set to the value of the last call.
|
||||
func (b *EndpointApplyConfiguration) WithZone(value string) *EndpointApplyConfiguration {
|
||||
b.Zone = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithHints sets the Hints 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 Hints field is set to the value of the last call.
|
||||
func (b *EndpointApplyConfiguration) WithHints(value *EndpointHintsApplyConfiguration) *EndpointApplyConfiguration {
|
||||
b.Hints = value
|
||||
return b
|
||||
}
|
||||
72
vendor/k8s.io/client-go/applyconfigurations/discovery/v1/endpointconditions.go
generated
vendored
Normal file
72
vendor/k8s.io/client-go/applyconfigurations/discovery/v1/endpointconditions.go
generated
vendored
Normal file
|
|
@ -0,0 +1,72 @@
|
|||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||
|
||||
package v1
|
||||
|
||||
// EndpointConditionsApplyConfiguration represents a declarative configuration of the EndpointConditions type for use
|
||||
// with apply.
|
||||
//
|
||||
// EndpointConditions represents the current condition of an endpoint.
|
||||
type EndpointConditionsApplyConfiguration struct {
|
||||
// ready indicates that this endpoint is ready to receive traffic,
|
||||
// according to whatever system is managing the endpoint. A nil value
|
||||
// should be interpreted as "true". In general, an endpoint should be
|
||||
// marked ready if it is serving and not terminating, though this can
|
||||
// be overridden in some cases, such as when the associated Service has
|
||||
// set the publishNotReadyAddresses flag.
|
||||
Ready *bool `json:"ready,omitempty"`
|
||||
// serving indicates that this endpoint is able to receive traffic,
|
||||
// according to whatever system is managing the endpoint. For endpoints
|
||||
// backed by pods, the EndpointSlice controller will mark the endpoint
|
||||
// as serving if the pod's Ready condition is True. A nil value should be
|
||||
// interpreted as "true".
|
||||
Serving *bool `json:"serving,omitempty"`
|
||||
// terminating indicates that this endpoint is terminating. A nil value
|
||||
// should be interpreted as "false".
|
||||
Terminating *bool `json:"terminating,omitempty"`
|
||||
}
|
||||
|
||||
// EndpointConditionsApplyConfiguration constructs a declarative configuration of the EndpointConditions type for use with
|
||||
// apply.
|
||||
func EndpointConditions() *EndpointConditionsApplyConfiguration {
|
||||
return &EndpointConditionsApplyConfiguration{}
|
||||
}
|
||||
|
||||
// WithReady sets the Ready 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 Ready field is set to the value of the last call.
|
||||
func (b *EndpointConditionsApplyConfiguration) WithReady(value bool) *EndpointConditionsApplyConfiguration {
|
||||
b.Ready = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithServing sets the Serving 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 Serving field is set to the value of the last call.
|
||||
func (b *EndpointConditionsApplyConfiguration) WithServing(value bool) *EndpointConditionsApplyConfiguration {
|
||||
b.Serving = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithTerminating sets the Terminating 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 Terminating field is set to the value of the last call.
|
||||
func (b *EndpointConditionsApplyConfiguration) WithTerminating(value bool) *EndpointConditionsApplyConfiguration {
|
||||
b.Terminating = &value
|
||||
return b
|
||||
}
|
||||
64
vendor/k8s.io/client-go/applyconfigurations/discovery/v1/endpointhints.go
generated
vendored
Normal file
64
vendor/k8s.io/client-go/applyconfigurations/discovery/v1/endpointhints.go
generated
vendored
Normal file
|
|
@ -0,0 +1,64 @@
|
|||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||
|
||||
package v1
|
||||
|
||||
// EndpointHintsApplyConfiguration represents a declarative configuration of the EndpointHints type for use
|
||||
// with apply.
|
||||
//
|
||||
// EndpointHints provides hints describing how an endpoint should be consumed.
|
||||
type EndpointHintsApplyConfiguration struct {
|
||||
// forZones indicates the zone(s) this endpoint should be consumed by when
|
||||
// using topology aware routing. May contain a maximum of 8 entries.
|
||||
ForZones []ForZoneApplyConfiguration `json:"forZones,omitempty"`
|
||||
// forNodes indicates the node(s) this endpoint should be consumed by when
|
||||
// using topology aware routing. May contain a maximum of 8 entries.
|
||||
ForNodes []ForNodeApplyConfiguration `json:"forNodes,omitempty"`
|
||||
}
|
||||
|
||||
// EndpointHintsApplyConfiguration constructs a declarative configuration of the EndpointHints type for use with
|
||||
// apply.
|
||||
func EndpointHints() *EndpointHintsApplyConfiguration {
|
||||
return &EndpointHintsApplyConfiguration{}
|
||||
}
|
||||
|
||||
// WithForZones adds the given value to the ForZones field in the declarative configuration
|
||||
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||
// If called multiple times, values provided by each call will be appended to the ForZones field.
|
||||
func (b *EndpointHintsApplyConfiguration) WithForZones(values ...*ForZoneApplyConfiguration) *EndpointHintsApplyConfiguration {
|
||||
for i := range values {
|
||||
if values[i] == nil {
|
||||
panic("nil value passed to WithForZones")
|
||||
}
|
||||
b.ForZones = append(b.ForZones, *values[i])
|
||||
}
|
||||
return b
|
||||
}
|
||||
|
||||
// WithForNodes adds the given value to the ForNodes field in the declarative configuration
|
||||
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||
// If called multiple times, values provided by each call will be appended to the ForNodes field.
|
||||
func (b *EndpointHintsApplyConfiguration) WithForNodes(values ...*ForNodeApplyConfiguration) *EndpointHintsApplyConfiguration {
|
||||
for i := range values {
|
||||
if values[i] == nil {
|
||||
panic("nil value passed to WithForNodes")
|
||||
}
|
||||
b.ForNodes = append(b.ForNodes, *values[i])
|
||||
}
|
||||
return b
|
||||
}
|
||||
101
vendor/k8s.io/client-go/applyconfigurations/discovery/v1/endpointport.go
generated
vendored
Normal file
101
vendor/k8s.io/client-go/applyconfigurations/discovery/v1/endpointport.go
generated
vendored
Normal file
|
|
@ -0,0 +1,101 @@
|
|||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||
|
||||
package v1
|
||||
|
||||
import (
|
||||
corev1 "k8s.io/api/core/v1"
|
||||
)
|
||||
|
||||
// EndpointPortApplyConfiguration represents a declarative configuration of the EndpointPort type for use
|
||||
// with apply.
|
||||
//
|
||||
// EndpointPort represents a Port used by an EndpointSlice
|
||||
type EndpointPortApplyConfiguration struct {
|
||||
// name represents the name of this port. All ports in an EndpointSlice must have a unique name.
|
||||
// If the EndpointSlice is derived from a Kubernetes service, this corresponds to the Service.ports[].name.
|
||||
// Name must either be an empty string or pass DNS_LABEL validation:
|
||||
// * must be no more than 63 characters long.
|
||||
// * must consist of lower case alphanumeric characters or '-'.
|
||||
// * must start and end with an alphanumeric character.
|
||||
// Default is empty string.
|
||||
Name *string `json:"name,omitempty"`
|
||||
// protocol represents the IP protocol for this port.
|
||||
// Must be UDP, TCP, or SCTP.
|
||||
// Default is TCP.
|
||||
Protocol *corev1.Protocol `json:"protocol,omitempty"`
|
||||
// port represents the port number of the endpoint.
|
||||
// If the EndpointSlice is derived from a Kubernetes service, this must be set
|
||||
// to the service's target port. EndpointSlices used for other purposes may have
|
||||
// a nil port.
|
||||
Port *int32 `json:"port,omitempty"`
|
||||
// The application protocol for this port.
|
||||
// This is used as a hint for implementations to offer richer behavior for protocols that they understand.
|
||||
// This field follows standard Kubernetes label syntax.
|
||||
// Valid values are either:
|
||||
//
|
||||
// * Un-prefixed protocol names - reserved for IANA standard service names (as per
|
||||
// RFC-6335 and https://www.iana.org/assignments/service-names).
|
||||
//
|
||||
// * Kubernetes-defined prefixed names:
|
||||
// * 'kubernetes.io/h2c' - HTTP/2 prior knowledge over cleartext as described in https://www.rfc-editor.org/rfc/rfc9113.html#name-starting-http-2-with-prior-
|
||||
// * 'kubernetes.io/ws' - WebSocket over cleartext as described in https://www.rfc-editor.org/rfc/rfc6455
|
||||
// * 'kubernetes.io/wss' - WebSocket over TLS as described in https://www.rfc-editor.org/rfc/rfc6455
|
||||
//
|
||||
// * Other protocols should use implementation-defined prefixed names such as
|
||||
// mycompany.com/my-custom-protocol.
|
||||
AppProtocol *string `json:"appProtocol,omitempty"`
|
||||
}
|
||||
|
||||
// EndpointPortApplyConfiguration constructs a declarative configuration of the EndpointPort type for use with
|
||||
// apply.
|
||||
func EndpointPort() *EndpointPortApplyConfiguration {
|
||||
return &EndpointPortApplyConfiguration{}
|
||||
}
|
||||
|
||||
// WithName sets the Name 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 Name field is set to the value of the last call.
|
||||
func (b *EndpointPortApplyConfiguration) WithName(value string) *EndpointPortApplyConfiguration {
|
||||
b.Name = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithProtocol sets the Protocol 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 Protocol field is set to the value of the last call.
|
||||
func (b *EndpointPortApplyConfiguration) WithProtocol(value corev1.Protocol) *EndpointPortApplyConfiguration {
|
||||
b.Protocol = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithPort sets the Port 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 Port field is set to the value of the last call.
|
||||
func (b *EndpointPortApplyConfiguration) WithPort(value int32) *EndpointPortApplyConfiguration {
|
||||
b.Port = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithAppProtocol sets the AppProtocol 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 AppProtocol field is set to the value of the last call.
|
||||
func (b *EndpointPortApplyConfiguration) WithAppProtocol(value string) *EndpointPortApplyConfiguration {
|
||||
b.AppProtocol = &value
|
||||
return b
|
||||
}
|
||||
326
vendor/k8s.io/client-go/applyconfigurations/discovery/v1/endpointslice.go
generated
vendored
Normal file
326
vendor/k8s.io/client-go/applyconfigurations/discovery/v1/endpointslice.go
generated
vendored
Normal file
|
|
@ -0,0 +1,326 @@
|
|||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||
|
||||
package v1
|
||||
|
||||
import (
|
||||
discoveryv1 "k8s.io/api/discovery/v1"
|
||||
apismetav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
types "k8s.io/apimachinery/pkg/types"
|
||||
managedfields "k8s.io/apimachinery/pkg/util/managedfields"
|
||||
internal "k8s.io/client-go/applyconfigurations/internal"
|
||||
metav1 "k8s.io/client-go/applyconfigurations/meta/v1"
|
||||
)
|
||||
|
||||
// EndpointSliceApplyConfiguration represents a declarative configuration of the EndpointSlice type for use
|
||||
// with apply.
|
||||
//
|
||||
// EndpointSlice represents a set of service endpoints. Most EndpointSlices are created by
|
||||
// the EndpointSlice controller to represent the Pods selected by Service objects. For a
|
||||
// given service there may be multiple EndpointSlice objects which must be joined to
|
||||
// produce the full set of endpoints; you can find all of the slices for a given service
|
||||
// by listing EndpointSlices in the service's namespace whose `kubernetes.io/service-name`
|
||||
// label contains the service's name.
|
||||
type EndpointSliceApplyConfiguration struct {
|
||||
metav1.TypeMetaApplyConfiguration `json:",inline"`
|
||||
// Standard object's metadata.
|
||||
*metav1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"`
|
||||
// addressType specifies the type of address carried by this EndpointSlice.
|
||||
// All addresses in this slice must be the same type. This field is
|
||||
// immutable after creation. The following address types are currently
|
||||
// supported:
|
||||
// * IPv4: Represents an IPv4 Address.
|
||||
// * IPv6: Represents an IPv6 Address.
|
||||
// * FQDN: Represents a Fully Qualified Domain Name. (Deprecated)
|
||||
// The EndpointSlice controller only generates, and kube-proxy only processes,
|
||||
// slices of addressType "IPv4" and "IPv6". No semantics are defined for
|
||||
// the "FQDN" type.
|
||||
AddressType *discoveryv1.AddressType `json:"addressType,omitempty"`
|
||||
// endpoints is a list of unique endpoints in this slice. Each slice may
|
||||
// include a maximum of 1000 endpoints.
|
||||
Endpoints []EndpointApplyConfiguration `json:"endpoints,omitempty"`
|
||||
// ports specifies the list of network ports exposed by each endpoint in
|
||||
// this slice. Each port must have a unique name. Each slice may include a
|
||||
// maximum of 100 ports.
|
||||
// Services always have at least 1 port, so EndpointSlices generated by the
|
||||
// EndpointSlice controller will likewise always have at least 1 port.
|
||||
// EndpointSlices used for other purposes may have an empty ports list.
|
||||
Ports []EndpointPortApplyConfiguration `json:"ports,omitempty"`
|
||||
}
|
||||
|
||||
// EndpointSlice constructs a declarative configuration of the EndpointSlice type for use with
|
||||
// apply.
|
||||
func EndpointSlice(name, namespace string) *EndpointSliceApplyConfiguration {
|
||||
b := &EndpointSliceApplyConfiguration{}
|
||||
b.WithName(name)
|
||||
b.WithNamespace(namespace)
|
||||
b.WithKind("EndpointSlice")
|
||||
b.WithAPIVersion("discovery.k8s.io/v1")
|
||||
return b
|
||||
}
|
||||
|
||||
// ExtractEndpointSliceFrom extracts the applied configuration owned by fieldManager from
|
||||
// endpointSlice for the specified subresource. Pass an empty string for subresource to extract
|
||||
// the main resource. Common subresources include "status", "scale", etc.
|
||||
// endpointSlice must be a unmodified EndpointSlice API object that was retrieved from the Kubernetes API.
|
||||
// ExtractEndpointSliceFrom provides a way to perform a extract/modify-in-place/apply workflow.
|
||||
// Note that an extracted apply configuration will contain fewer fields than what the fieldManager previously
|
||||
// applied if another fieldManager has updated or force applied any of the previously applied fields.
|
||||
func ExtractEndpointSliceFrom(endpointSlice *discoveryv1.EndpointSlice, fieldManager string, subresource string) (*EndpointSliceApplyConfiguration, error) {
|
||||
b := &EndpointSliceApplyConfiguration{}
|
||||
err := managedfields.ExtractInto(endpointSlice, internal.Parser().Type("io.k8s.api.discovery.v1.EndpointSlice"), fieldManager, b, subresource)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
b.WithName(endpointSlice.Name)
|
||||
b.WithNamespace(endpointSlice.Namespace)
|
||||
|
||||
b.WithKind("EndpointSlice")
|
||||
b.WithAPIVersion("discovery.k8s.io/v1")
|
||||
return b, nil
|
||||
}
|
||||
|
||||
// ExtractEndpointSlice extracts the applied configuration owned by fieldManager from
|
||||
// endpointSlice. If no managedFields are found in endpointSlice for fieldManager, a
|
||||
// EndpointSliceApplyConfiguration is returned with only the Name, Namespace (if applicable),
|
||||
// APIVersion and Kind populated. It is possible that no managed fields were found for because other
|
||||
// field managers have taken ownership of all the fields previously owned by fieldManager, or because
|
||||
// the fieldManager never owned fields any fields.
|
||||
// endpointSlice must be a unmodified EndpointSlice API object that was retrieved from the Kubernetes API.
|
||||
// ExtractEndpointSlice provides a way to perform a extract/modify-in-place/apply workflow.
|
||||
// Note that an extracted apply configuration will contain fewer fields than what the fieldManager previously
|
||||
// applied if another fieldManager has updated or force applied any of the previously applied fields.
|
||||
func ExtractEndpointSlice(endpointSlice *discoveryv1.EndpointSlice, fieldManager string) (*EndpointSliceApplyConfiguration, error) {
|
||||
return ExtractEndpointSliceFrom(endpointSlice, fieldManager, "")
|
||||
}
|
||||
|
||||
func (b EndpointSliceApplyConfiguration) IsApplyConfiguration() {}
|
||||
|
||||
// WithKind sets the Kind 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 Kind field is set to the value of the last call.
|
||||
func (b *EndpointSliceApplyConfiguration) WithKind(value string) *EndpointSliceApplyConfiguration {
|
||||
b.TypeMetaApplyConfiguration.Kind = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithAPIVersion sets the APIVersion 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 APIVersion field is set to the value of the last call.
|
||||
func (b *EndpointSliceApplyConfiguration) WithAPIVersion(value string) *EndpointSliceApplyConfiguration {
|
||||
b.TypeMetaApplyConfiguration.APIVersion = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithName sets the Name 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 Name field is set to the value of the last call.
|
||||
func (b *EndpointSliceApplyConfiguration) WithName(value string) *EndpointSliceApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
b.ObjectMetaApplyConfiguration.Name = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithGenerateName sets the GenerateName 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 GenerateName field is set to the value of the last call.
|
||||
func (b *EndpointSliceApplyConfiguration) WithGenerateName(value string) *EndpointSliceApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
b.ObjectMetaApplyConfiguration.GenerateName = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithNamespace sets the Namespace 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 Namespace field is set to the value of the last call.
|
||||
func (b *EndpointSliceApplyConfiguration) WithNamespace(value string) *EndpointSliceApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
b.ObjectMetaApplyConfiguration.Namespace = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithUID sets the UID 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 UID field is set to the value of the last call.
|
||||
func (b *EndpointSliceApplyConfiguration) WithUID(value types.UID) *EndpointSliceApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
b.ObjectMetaApplyConfiguration.UID = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithResourceVersion sets the ResourceVersion 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 ResourceVersion field is set to the value of the last call.
|
||||
func (b *EndpointSliceApplyConfiguration) WithResourceVersion(value string) *EndpointSliceApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
b.ObjectMetaApplyConfiguration.ResourceVersion = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithGeneration sets the Generation 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 Generation field is set to the value of the last call.
|
||||
func (b *EndpointSliceApplyConfiguration) WithGeneration(value int64) *EndpointSliceApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
b.ObjectMetaApplyConfiguration.Generation = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithCreationTimestamp sets the CreationTimestamp 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 CreationTimestamp field is set to the value of the last call.
|
||||
func (b *EndpointSliceApplyConfiguration) WithCreationTimestamp(value apismetav1.Time) *EndpointSliceApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
b.ObjectMetaApplyConfiguration.CreationTimestamp = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithDeletionTimestamp sets the DeletionTimestamp 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 DeletionTimestamp field is set to the value of the last call.
|
||||
func (b *EndpointSliceApplyConfiguration) WithDeletionTimestamp(value apismetav1.Time) *EndpointSliceApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds 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 DeletionGracePeriodSeconds field is set to the value of the last call.
|
||||
func (b *EndpointSliceApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *EndpointSliceApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// 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 *EndpointSliceApplyConfiguration) WithLabels(entries map[string]string) *EndpointSliceApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 {
|
||||
b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries))
|
||||
}
|
||||
for k, v := range entries {
|
||||
b.ObjectMetaApplyConfiguration.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 *EndpointSliceApplyConfiguration) WithAnnotations(entries map[string]string) *EndpointSliceApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 {
|
||||
b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries))
|
||||
}
|
||||
for k, v := range entries {
|
||||
b.ObjectMetaApplyConfiguration.Annotations[k] = v
|
||||
}
|
||||
return b
|
||||
}
|
||||
|
||||
// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration
|
||||
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||
// If called multiple times, values provided by each call will be appended to the OwnerReferences field.
|
||||
func (b *EndpointSliceApplyConfiguration) WithOwnerReferences(values ...*metav1.OwnerReferenceApplyConfiguration) *EndpointSliceApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
for i := range values {
|
||||
if values[i] == nil {
|
||||
panic("nil value passed to WithOwnerReferences")
|
||||
}
|
||||
b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i])
|
||||
}
|
||||
return b
|
||||
}
|
||||
|
||||
// WithFinalizers adds the given value to the Finalizers field in the declarative configuration
|
||||
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||
// If called multiple times, values provided by each call will be appended to the Finalizers field.
|
||||
func (b *EndpointSliceApplyConfiguration) WithFinalizers(values ...string) *EndpointSliceApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
for i := range values {
|
||||
b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i])
|
||||
}
|
||||
return b
|
||||
}
|
||||
|
||||
func (b *EndpointSliceApplyConfiguration) ensureObjectMetaApplyConfigurationExists() {
|
||||
if b.ObjectMetaApplyConfiguration == nil {
|
||||
b.ObjectMetaApplyConfiguration = &metav1.ObjectMetaApplyConfiguration{}
|
||||
}
|
||||
}
|
||||
|
||||
// WithAddressType sets the AddressType 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 AddressType field is set to the value of the last call.
|
||||
func (b *EndpointSliceApplyConfiguration) WithAddressType(value discoveryv1.AddressType) *EndpointSliceApplyConfiguration {
|
||||
b.AddressType = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithEndpoints adds the given value to the Endpoints field in the declarative configuration
|
||||
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||
// If called multiple times, values provided by each call will be appended to the Endpoints field.
|
||||
func (b *EndpointSliceApplyConfiguration) WithEndpoints(values ...*EndpointApplyConfiguration) *EndpointSliceApplyConfiguration {
|
||||
for i := range values {
|
||||
if values[i] == nil {
|
||||
panic("nil value passed to WithEndpoints")
|
||||
}
|
||||
b.Endpoints = append(b.Endpoints, *values[i])
|
||||
}
|
||||
return b
|
||||
}
|
||||
|
||||
// WithPorts adds the given value to the Ports field in the declarative configuration
|
||||
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||
// If called multiple times, values provided by each call will be appended to the Ports field.
|
||||
func (b *EndpointSliceApplyConfiguration) WithPorts(values ...*EndpointPortApplyConfiguration) *EndpointSliceApplyConfiguration {
|
||||
for i := range values {
|
||||
if values[i] == nil {
|
||||
panic("nil value passed to WithPorts")
|
||||
}
|
||||
b.Ports = append(b.Ports, *values[i])
|
||||
}
|
||||
return b
|
||||
}
|
||||
|
||||
// GetKind retrieves the value of the Kind field in the declarative configuration.
|
||||
func (b *EndpointSliceApplyConfiguration) GetKind() *string {
|
||||
return b.TypeMetaApplyConfiguration.Kind
|
||||
}
|
||||
|
||||
// GetAPIVersion retrieves the value of the APIVersion field in the declarative configuration.
|
||||
func (b *EndpointSliceApplyConfiguration) GetAPIVersion() *string {
|
||||
return b.TypeMetaApplyConfiguration.APIVersion
|
||||
}
|
||||
|
||||
// GetName retrieves the value of the Name field in the declarative configuration.
|
||||
func (b *EndpointSliceApplyConfiguration) GetName() *string {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
return b.ObjectMetaApplyConfiguration.Name
|
||||
}
|
||||
|
||||
// GetNamespace retrieves the value of the Namespace field in the declarative configuration.
|
||||
func (b *EndpointSliceApplyConfiguration) GetNamespace() *string {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
return b.ObjectMetaApplyConfiguration.Namespace
|
||||
}
|
||||
42
vendor/k8s.io/client-go/applyconfigurations/discovery/v1/fornode.go
generated
vendored
Normal file
42
vendor/k8s.io/client-go/applyconfigurations/discovery/v1/fornode.go
generated
vendored
Normal file
|
|
@ -0,0 +1,42 @@
|
|||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||
|
||||
package v1
|
||||
|
||||
// ForNodeApplyConfiguration represents a declarative configuration of the ForNode type for use
|
||||
// with apply.
|
||||
//
|
||||
// ForNode provides information about which nodes should consume this endpoint.
|
||||
type ForNodeApplyConfiguration struct {
|
||||
// name represents the name of the node.
|
||||
Name *string `json:"name,omitempty"`
|
||||
}
|
||||
|
||||
// ForNodeApplyConfiguration constructs a declarative configuration of the ForNode type for use with
|
||||
// apply.
|
||||
func ForNode() *ForNodeApplyConfiguration {
|
||||
return &ForNodeApplyConfiguration{}
|
||||
}
|
||||
|
||||
// WithName sets the Name 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 Name field is set to the value of the last call.
|
||||
func (b *ForNodeApplyConfiguration) WithName(value string) *ForNodeApplyConfiguration {
|
||||
b.Name = &value
|
||||
return b
|
||||
}
|
||||
42
vendor/k8s.io/client-go/applyconfigurations/discovery/v1/forzone.go
generated
vendored
Normal file
42
vendor/k8s.io/client-go/applyconfigurations/discovery/v1/forzone.go
generated
vendored
Normal file
|
|
@ -0,0 +1,42 @@
|
|||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||
|
||||
package v1
|
||||
|
||||
// ForZoneApplyConfiguration represents a declarative configuration of the ForZone type for use
|
||||
// with apply.
|
||||
//
|
||||
// ForZone provides information about which zones should consume this endpoint.
|
||||
type ForZoneApplyConfiguration struct {
|
||||
// name represents the name of the zone.
|
||||
Name *string `json:"name,omitempty"`
|
||||
}
|
||||
|
||||
// ForZoneApplyConfiguration constructs a declarative configuration of the ForZone type for use with
|
||||
// apply.
|
||||
func ForZone() *ForZoneApplyConfiguration {
|
||||
return &ForZoneApplyConfiguration{}
|
||||
}
|
||||
|
||||
// WithName sets the Name 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 Name field is set to the value of the last call.
|
||||
func (b *ForZoneApplyConfiguration) WithName(value string) *ForZoneApplyConfiguration {
|
||||
b.Name = &value
|
||||
return b
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue