mirror of
https://github.com/kubernetes/sample-controller.git
synced 2026-05-01 00:00:03 +08:00
Merge pull request #67359 from mikedanese/reloadtoken
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions here: https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md. client: periodically reload InClusterConfig token /sig auth /sig api-machinery ```release-note NONE ``` Kubernetes-commit: 7b6647a418c660f2c87f183f706b297f1cb573ca
This commit is contained in:
+1484
-1190
File diff suppressed because it is too large
Load Diff
+34
-3
@@ -749,7 +749,7 @@ message ContainerPort {
|
||||
// This must be a valid port number, 0 < x < 65536.
|
||||
optional int32 containerPort = 3;
|
||||
|
||||
// Protocol for port. Must be UDP or TCP.
|
||||
// Protocol for port. Must be UDP, TCP, or SCTP.
|
||||
// Defaults to "TCP".
|
||||
// +optional
|
||||
optional string protocol = 4;
|
||||
@@ -968,7 +968,7 @@ message EndpointPort {
|
||||
optional int32 port = 2;
|
||||
|
||||
// The IP protocol for this port.
|
||||
// Must be UDP or TCP.
|
||||
// Must be UDP, TCP, or SCTP.
|
||||
// Default is TCP.
|
||||
// +optional
|
||||
optional string protocol = 3;
|
||||
@@ -2292,6 +2292,17 @@ message PersistentVolumeClaimSpec {
|
||||
// This is an alpha feature and may change in the future.
|
||||
// +optional
|
||||
optional string volumeMode = 6;
|
||||
|
||||
// This field requires the VolumeSnapshotDataSource alpha feature gate to be
|
||||
// enabled and currently VolumeSnapshot is the only supported data source.
|
||||
// If the provisioner can support VolumeSnapshot data source, it will create
|
||||
// a new volume and data will be restored to the volume at the same time.
|
||||
// If the provisioner does not support VolumeSnapshot data source, volume will
|
||||
// not be created and the failure will be reported as an event.
|
||||
// In the future, we plan to support more data source types and the behavior
|
||||
// of the provisioner may change.
|
||||
// +optional
|
||||
optional TypedLocalObjectReference dataSource = 7;
|
||||
}
|
||||
|
||||
// PersistentVolumeClaimStatus is the current status of a persistent volume claim.
|
||||
@@ -4029,6 +4040,13 @@ message SecurityContext {
|
||||
// 2) has CAP_SYS_ADMIN
|
||||
// +optional
|
||||
optional bool allowPrivilegeEscalation = 7;
|
||||
|
||||
// procMount denotes the type of proc mount to use for the containers.
|
||||
// The default is DefaultProcMount which uses the container runtime defaults for
|
||||
// readonly paths and masked paths.
|
||||
// This requires the ProcMountType feature flag to be enabled.
|
||||
// +optional
|
||||
optional string procMount = 9;
|
||||
}
|
||||
|
||||
// SerializedReference is a reference to serialized object.
|
||||
@@ -4148,7 +4166,7 @@ message ServicePort {
|
||||
// +optional
|
||||
optional string name = 1;
|
||||
|
||||
// The IP protocol for this port. Supports "TCP" and "UDP".
|
||||
// The IP protocol for this port. Supports "TCP", "UDP", and "SCTP".
|
||||
// Default is TCP.
|
||||
// +optional
|
||||
optional string protocol = 2;
|
||||
@@ -4478,6 +4496,19 @@ message TopologySelectorTerm {
|
||||
repeated TopologySelectorLabelRequirement matchLabelExpressions = 1;
|
||||
}
|
||||
|
||||
// TypedLocalObjectReference contains enough information to let you locate the
|
||||
// typed referenced object inside the same namespace.
|
||||
message TypedLocalObjectReference {
|
||||
// APIGroup is the group for the resource being referenced
|
||||
optional string apiGroup = 1;
|
||||
|
||||
// Kind is the type of resource being referenced
|
||||
optional string kind = 2;
|
||||
|
||||
// Name is the name of resource being referenced
|
||||
optional string name = 3;
|
||||
}
|
||||
|
||||
// Volume represents a named volume in a pod that may be accessed by any container in the pod.
|
||||
message Volume {
|
||||
// Volume's name.
|
||||
|
||||
+46
-3
@@ -458,6 +458,16 @@ type PersistentVolumeClaimSpec struct {
|
||||
// This is an alpha feature and may change in the future.
|
||||
// +optional
|
||||
VolumeMode *PersistentVolumeMode `json:"volumeMode,omitempty" protobuf:"bytes,6,opt,name=volumeMode,casttype=PersistentVolumeMode"`
|
||||
// This field requires the VolumeSnapshotDataSource alpha feature gate to be
|
||||
// enabled and currently VolumeSnapshot is the only supported data source.
|
||||
// If the provisioner can support VolumeSnapshot data source, it will create
|
||||
// a new volume and data will be restored to the volume at the same time.
|
||||
// If the provisioner does not support VolumeSnapshot data source, volume will
|
||||
// not be created and the failure will be reported as an event.
|
||||
// In the future, we plan to support more data source types and the behavior
|
||||
// of the provisioner may change.
|
||||
// +optional
|
||||
DataSource *TypedLocalObjectReference `json:"dataSource" protobuf:"bytes,7,opt,name=dataSource"`
|
||||
}
|
||||
|
||||
// PersistentVolumeClaimConditionType is a valid value of PersistentVolumeClaimCondition.Type
|
||||
@@ -861,6 +871,8 @@ const (
|
||||
ProtocolTCP Protocol = "TCP"
|
||||
// ProtocolUDP is the UDP protocol.
|
||||
ProtocolUDP Protocol = "UDP"
|
||||
// ProtocolSCTP is the SCTP protocol.
|
||||
ProtocolSCTP Protocol = "SCTP"
|
||||
)
|
||||
|
||||
// Represents a Persistent Disk resource in Google Compute Engine.
|
||||
@@ -1662,7 +1674,7 @@ type ContainerPort struct {
|
||||
// Number of port to expose on the pod's IP address.
|
||||
// This must be a valid port number, 0 < x < 65536.
|
||||
ContainerPort int32 `json:"containerPort" protobuf:"varint,3,opt,name=containerPort"`
|
||||
// Protocol for port. Must be UDP or TCP.
|
||||
// Protocol for port. Must be UDP, TCP, or SCTP.
|
||||
// Defaults to "TCP".
|
||||
// +optional
|
||||
Protocol Protocol `json:"protocol,omitempty" protobuf:"bytes,4,opt,name=protocol,casttype=Protocol"`
|
||||
@@ -3515,7 +3527,7 @@ type ServicePort struct {
|
||||
// +optional
|
||||
Name string `json:"name,omitempty" protobuf:"bytes,1,opt,name=name"`
|
||||
|
||||
// The IP protocol for this port. Supports "TCP" and "UDP".
|
||||
// The IP protocol for this port. Supports "TCP", "UDP", and "SCTP".
|
||||
// Default is TCP.
|
||||
// +optional
|
||||
Protocol Protocol `json:"protocol,omitempty" protobuf:"bytes,2,opt,name=protocol,casttype=Protocol"`
|
||||
@@ -3729,7 +3741,7 @@ type EndpointPort struct {
|
||||
Port int32 `json:"port" protobuf:"varint,2,opt,name=port"`
|
||||
|
||||
// The IP protocol for this port.
|
||||
// Must be UDP or TCP.
|
||||
// Must be UDP, TCP, or SCTP.
|
||||
// Default is TCP.
|
||||
// +optional
|
||||
Protocol Protocol `json:"protocol,omitempty" protobuf:"bytes,3,opt,name=protocol,casttype=Protocol"`
|
||||
@@ -4476,6 +4488,17 @@ type LocalObjectReference struct {
|
||||
Name string `json:"name,omitempty" protobuf:"bytes,1,opt,name=name"`
|
||||
}
|
||||
|
||||
// TypedLocalObjectReference contains enough information to let you locate the
|
||||
// typed referenced object inside the same namespace.
|
||||
type TypedLocalObjectReference struct {
|
||||
// APIGroup is the group for the resource being referenced
|
||||
APIGroup string `json:"apiGroup" protobuf:"bytes,1,opt,name=apiGroup"`
|
||||
// Kind is the type of resource being referenced
|
||||
Kind string `json:"kind" protobuf:"bytes,2,opt,name=kind"`
|
||||
// Name is the name of resource being referenced
|
||||
Name string `json:"name" protobuf:"bytes,3,opt,name=name"`
|
||||
}
|
||||
|
||||
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
|
||||
|
||||
// SerializedReference is a reference to serialized object.
|
||||
@@ -5175,8 +5198,28 @@ type SecurityContext struct {
|
||||
// 2) has CAP_SYS_ADMIN
|
||||
// +optional
|
||||
AllowPrivilegeEscalation *bool `json:"allowPrivilegeEscalation,omitempty" protobuf:"varint,7,opt,name=allowPrivilegeEscalation"`
|
||||
// procMount denotes the type of proc mount to use for the containers.
|
||||
// The default is DefaultProcMount which uses the container runtime defaults for
|
||||
// readonly paths and masked paths.
|
||||
// This requires the ProcMountType feature flag to be enabled.
|
||||
// +optional
|
||||
ProcMount *ProcMountType `json:"procMount,omitEmpty" protobuf:"bytes,9,opt,name=procMount"`
|
||||
}
|
||||
|
||||
type ProcMountType string
|
||||
|
||||
const (
|
||||
// DefaultProcMount uses the container runtime defaults for readonly and masked
|
||||
// paths for /proc. Most container runtimes mask certain paths in /proc to avoid
|
||||
// accidental security exposure of special devices or information.
|
||||
DefaultProcMount ProcMountType = "Default"
|
||||
|
||||
// UnmaskedProcMount bypasses the default masking behavior of the container
|
||||
// runtime and ensures the newly created /proc the container stays in tact with
|
||||
// no modifications.
|
||||
UnmaskedProcMount ProcMountType = "Unmasked"
|
||||
)
|
||||
|
||||
// SELinuxOptions are the labels to be applied to the container
|
||||
type SELinuxOptions struct {
|
||||
// User is a SELinux user label that applies to the container.
|
||||
|
||||
+16
-3
@@ -353,7 +353,7 @@ var map_ContainerPort = map[string]string{
|
||||
"name": "If specified, this must be an IANA_SVC_NAME and unique within the pod. Each named port in a pod must have a unique name. Name for the port that can be referred to by services.",
|
||||
"hostPort": "Number of port to expose on the host. If specified, this must be a valid port number, 0 < x < 65536. If HostNetwork is specified, this must match ContainerPort. Most containers do not need this.",
|
||||
"containerPort": "Number of port to expose on the pod's IP address. This must be a valid port number, 0 < x < 65536.",
|
||||
"protocol": "Protocol for port. Must be UDP or TCP. Defaults to \"TCP\".",
|
||||
"protocol": "Protocol for port. Must be UDP, TCP, or SCTP. Defaults to \"TCP\".",
|
||||
"hostIP": "What host IP to bind the external port to.",
|
||||
}
|
||||
|
||||
@@ -488,7 +488,7 @@ var map_EndpointPort = map[string]string{
|
||||
"": "EndpointPort is a tuple that describes a single port.",
|
||||
"name": "The name of this port (corresponds to ServicePort.Name). Must be a DNS_LABEL. Optional only if one port is defined.",
|
||||
"port": "The port number of the endpoint.",
|
||||
"protocol": "The IP protocol for this port. Must be UDP or TCP. Default is TCP.",
|
||||
"protocol": "The IP protocol for this port. Must be UDP, TCP, or SCTP. Default is TCP.",
|
||||
}
|
||||
|
||||
func (EndpointPort) SwaggerDoc() map[string]string {
|
||||
@@ -1210,6 +1210,7 @@ var map_PersistentVolumeClaimSpec = map[string]string{
|
||||
"volumeName": "VolumeName is the binding reference to the PersistentVolume backing this claim.",
|
||||
"storageClassName": "Name of the StorageClass required by the claim. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#class-1",
|
||||
"volumeMode": "volumeMode defines what type of volume is required by the claim. Value of Filesystem is implied when not included in claim spec. This is an alpha feature and may change in the future.",
|
||||
"dataSource": "This field requires the VolumeSnapshotDataSource alpha feature gate to be enabled and currently VolumeSnapshot is the only supported data source. If the provisioner can support VolumeSnapshot data source, it will create a new volume and data will be restored to the volume at the same time. If the provisioner does not support VolumeSnapshot data source, volume will not be created and the failure will be reported as an event. In the future, we plan to support more data source types and the behavior of the provisioner may change.",
|
||||
}
|
||||
|
||||
func (PersistentVolumeClaimSpec) SwaggerDoc() map[string]string {
|
||||
@@ -1986,6 +1987,7 @@ var map_SecurityContext = map[string]string{
|
||||
"runAsNonRoot": "Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence.",
|
||||
"readOnlyRootFilesystem": "Whether this container has a read-only root filesystem. Default is false.",
|
||||
"allowPrivilegeEscalation": "AllowPrivilegeEscalation controls whether a process can gain more privileges than its parent process. This bool directly controls if the no_new_privs flag will be set on the container process. AllowPrivilegeEscalation is true always when the container is: 1) run as Privileged 2) has CAP_SYS_ADMIN",
|
||||
"procMount": "procMount denotes the type of proc mount to use for the containers. The default is DefaultProcMount which uses the container runtime defaults for readonly paths and masked paths. This requires the ProcMountType feature flag to be enabled.",
|
||||
}
|
||||
|
||||
func (SecurityContext) SwaggerDoc() map[string]string {
|
||||
@@ -2058,7 +2060,7 @@ func (ServiceList) SwaggerDoc() map[string]string {
|
||||
var map_ServicePort = map[string]string{
|
||||
"": "ServicePort contains information on service's port.",
|
||||
"name": "The name of this port within the service. This must be a DNS_LABEL. All ports within a ServiceSpec must have unique names. This maps to the 'Name' field in EndpointPort objects. Optional if only one ServicePort is defined on this service.",
|
||||
"protocol": "The IP protocol for this port. Supports \"TCP\" and \"UDP\". Default is TCP.",
|
||||
"protocol": "The IP protocol for this port. Supports \"TCP\", \"UDP\", and \"SCTP\". Default is TCP.",
|
||||
"port": "The port that will be exposed by this service.",
|
||||
"targetPort": "Number or name of the port to access on the pods targeted by the service. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. If this is a string, it will be looked up as a named port in the target Pod's container ports. If this is not specified, the value of the 'port' field is used (an identity map). This field is ignored for services with clusterIP=None, and should be omitted or set equal to the 'port' field. More info: https://kubernetes.io/docs/concepts/services-networking/service/#defining-a-service",
|
||||
"nodePort": "The port on each node on which this service is exposed when type=NodePort or LoadBalancer. Usually assigned by the system. If specified, it will be allocated to the service if unused or else creation of the service will fail. Default is to auto-allocate a port if the ServiceType of this Service requires one. More info: https://kubernetes.io/docs/concepts/services-networking/service/#type-nodeport",
|
||||
@@ -2206,6 +2208,17 @@ func (TopologySelectorTerm) SwaggerDoc() map[string]string {
|
||||
return map_TopologySelectorTerm
|
||||
}
|
||||
|
||||
var map_TypedLocalObjectReference = map[string]string{
|
||||
"": "TypedLocalObjectReference contains enough information to let you locate the typed referenced object inside the same namespace.",
|
||||
"apiGroup": "APIGroup is the group for the resource being referenced",
|
||||
"kind": "Kind is the type of resource being referenced",
|
||||
"name": "Name is the name of resource being referenced",
|
||||
}
|
||||
|
||||
func (TypedLocalObjectReference) SwaggerDoc() map[string]string {
|
||||
return map_TypedLocalObjectReference
|
||||
}
|
||||
|
||||
var map_Volume = map[string]string{
|
||||
"": "Volume represents a named volume in a pod that may be accessed by any container in the pod.",
|
||||
"name": "Volume's name. Must be a DNS_LABEL and unique within the pod. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names",
|
||||
|
||||
+26
@@ -2679,6 +2679,11 @@ func (in *PersistentVolumeClaimSpec) DeepCopyInto(out *PersistentVolumeClaimSpec
|
||||
*out = new(PersistentVolumeMode)
|
||||
**out = **in
|
||||
}
|
||||
if in.DataSource != nil {
|
||||
in, out := &in.DataSource, &out.DataSource
|
||||
*out = new(TypedLocalObjectReference)
|
||||
**out = **in
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
@@ -4594,6 +4599,11 @@ func (in *SecurityContext) DeepCopyInto(out *SecurityContext) {
|
||||
*out = new(bool)
|
||||
**out = **in
|
||||
}
|
||||
if in.ProcMount != nil {
|
||||
in, out := &in.ProcMount, &out.ProcMount
|
||||
*out = new(ProcMountType)
|
||||
**out = **in
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
@@ -5072,6 +5082,22 @@ func (in *TopologySelectorTerm) DeepCopy() *TopologySelectorTerm {
|
||||
return out
|
||||
}
|
||||
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *TypedLocalObjectReference) DeepCopyInto(out *TypedLocalObjectReference) {
|
||||
*out = *in
|
||||
return
|
||||
}
|
||||
|
||||
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TypedLocalObjectReference.
|
||||
func (in *TypedLocalObjectReference) DeepCopy() *TypedLocalObjectReference {
|
||||
if in == nil {
|
||||
return nil
|
||||
}
|
||||
out := new(TypedLocalObjectReference)
|
||||
in.DeepCopyInto(out)
|
||||
return out
|
||||
}
|
||||
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *Volume) DeepCopyInto(out *Volume) {
|
||||
*out = *in
|
||||
|
||||
Reference in New Issue
Block a user