blob: b13a2db72f584e95a521162369a4edfdf6a09067 [file] [log] [blame]
sslobodrd046be82019-01-16 10:02:22 -05001/*
2Copyright The Kubernetes Authors.
3
4Licensed under the Apache License, Version 2.0 (the "License");
5you may not use this file except in compliance with the License.
6You may obtain a copy of the License at
7
8 http://www.apache.org/licenses/LICENSE-2.0
9
10Unless required by applicable law or agreed to in writing, software
11distributed under the License is distributed on an "AS IS" BASIS,
12WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13See the License for the specific language governing permissions and
14limitations under the License.
15*/
16
17
18// This file was autogenerated by go-to-protobuf. Do not edit it manually!
19
20syntax = 'proto2';
21
22package k8s.io.api.core.v1;
23
24import "k8s.io/apimachinery/pkg/api/resource/generated.proto";
25import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto";
26import "k8s.io/apimachinery/pkg/runtime/generated.proto";
27import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto";
28import "k8s.io/apimachinery/pkg/util/intstr/generated.proto";
29
30// Package-wide variables from generator "generated".
31option go_package = "v1";
32
33// Represents a Persistent Disk resource in AWS.
34//
35// An AWS EBS disk must exist before mounting to a container. The disk
36// must also be in the same AWS zone as the kubelet. An AWS EBS disk
37// can only be mounted as read/write once. AWS EBS volumes support
38// ownership management and SELinux relabeling.
39message AWSElasticBlockStoreVolumeSource {
40 // Unique ID of the persistent disk resource in AWS (Amazon EBS volume).
41 // More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore
42 optional string volumeID = 1;
43
44 // Filesystem type of the volume that you want to mount.
45 // Tip: Ensure that the filesystem type is supported by the host operating system.
46 // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
47 // More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore
48 // TODO: how do we prevent errors in the filesystem from compromising the machine
49 // +optional
50 optional string fsType = 2;
51
52 // The partition in the volume that you want to mount.
53 // If omitted, the default is to mount by volume name.
54 // Examples: For volume /dev/sda1, you specify the partition as "1".
55 // Similarly, the volume partition for /dev/sda is "0" (or you can leave the property empty).
56 // +optional
57 optional int32 partition = 3;
58
59 // Specify "true" to force and set the ReadOnly property in VolumeMounts to "true".
60 // If omitted, the default is "false".
61 // More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore
62 // +optional
63 optional bool readOnly = 4;
64}
65
66// Affinity is a group of affinity scheduling rules.
67message Affinity {
68 // Describes node affinity scheduling rules for the pod.
69 // +optional
70 optional NodeAffinity nodeAffinity = 1;
71
72 // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)).
73 // +optional
74 optional PodAffinity podAffinity = 2;
75
76 // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)).
77 // +optional
78 optional PodAntiAffinity podAntiAffinity = 3;
79}
80
81// AttachedVolume describes a volume attached to a node
82message AttachedVolume {
83 // Name of the attached volume
84 optional string name = 1;
85
86 // DevicePath represents the device path where the volume should be available
87 optional string devicePath = 2;
88}
89
90// AvoidPods describes pods that should avoid this node. This is the value for a
91// Node annotation with key scheduler.alpha.kubernetes.io/preferAvoidPods and
92// will eventually become a field of NodeStatus.
93message AvoidPods {
94 // Bounded-sized list of signatures of pods that should avoid this node, sorted
95 // in timestamp order from oldest to newest. Size of the slice is unspecified.
96 // +optional
97 repeated PreferAvoidPodsEntry preferAvoidPods = 1;
98}
99
100// AzureDisk represents an Azure Data Disk mount on the host and bind mount to the pod.
101message AzureDiskVolumeSource {
102 // The Name of the data disk in the blob storage
103 optional string diskName = 1;
104
105 // The URI the data disk in the blob storage
106 optional string diskURI = 2;
107
108 // Host Caching mode: None, Read Only, Read Write.
109 // +optional
110 optional string cachingMode = 3;
111
112 // Filesystem type to mount.
113 // Must be a filesystem type supported by the host operating system.
114 // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
115 // +optional
116 optional string fsType = 4;
117
118 // Defaults to false (read/write). ReadOnly here will force
119 // the ReadOnly setting in VolumeMounts.
120 // +optional
121 optional bool readOnly = 5;
122
123 // Expected values Shared: multiple blob disks per storage account Dedicated: single blob disk per storage account Managed: azure managed data disk (only in managed availability set). defaults to shared
124 optional string kind = 6;
125}
126
127// AzureFile represents an Azure File Service mount on the host and bind mount to the pod.
128message AzureFilePersistentVolumeSource {
129 // the name of secret that contains Azure Storage Account Name and Key
130 optional string secretName = 1;
131
132 // Share Name
133 optional string shareName = 2;
134
135 // Defaults to false (read/write). ReadOnly here will force
136 // the ReadOnly setting in VolumeMounts.
137 // +optional
138 optional bool readOnly = 3;
139
140 // the namespace of the secret that contains Azure Storage Account Name and Key
141 // default is the same as the Pod
142 // +optional
143 optional string secretNamespace = 4;
144}
145
146// AzureFile represents an Azure File Service mount on the host and bind mount to the pod.
147message AzureFileVolumeSource {
148 // the name of secret that contains Azure Storage Account Name and Key
149 optional string secretName = 1;
150
151 // Share Name
152 optional string shareName = 2;
153
154 // Defaults to false (read/write). ReadOnly here will force
155 // the ReadOnly setting in VolumeMounts.
156 // +optional
157 optional bool readOnly = 3;
158}
159
160// Binding ties one object to another; for example, a pod is bound to a node by a scheduler.
161// Deprecated in 1.7, please use the bindings subresource of pods instead.
162message Binding {
163 // Standard object's metadata.
164 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata
165 // +optional
166 optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
167
168 // The target object that you want to bind to the standard object.
169 optional ObjectReference target = 2;
170}
171
172// Represents storage that is managed by an external CSI volume driver (Beta feature)
173message CSIPersistentVolumeSource {
174 // Driver is the name of the driver to use for this volume.
175 // Required.
176 optional string driver = 1;
177
178 // VolumeHandle is the unique volume name returned by the CSI volume
179 // plugin’s CreateVolume to refer to the volume on all subsequent calls.
180 // Required.
181 optional string volumeHandle = 2;
182
183 // Optional: The value to pass to ControllerPublishVolumeRequest.
184 // Defaults to false (read/write).
185 // +optional
186 optional bool readOnly = 3;
187
188 // Filesystem type to mount.
189 // Must be a filesystem type supported by the host operating system.
190 // Ex. "ext4", "xfs", "ntfs".
191 // +optional
192 optional string fsType = 4;
193
194 // Attributes of the volume to publish.
195 // +optional
196 map<string, string> volumeAttributes = 5;
197
198 // ControllerPublishSecretRef is a reference to the secret object containing
199 // sensitive information to pass to the CSI driver to complete the CSI
200 // ControllerPublishVolume and ControllerUnpublishVolume calls.
201 // This field is optional, and may be empty if no secret is required. If the
202 // secret object contains more than one secret, all secrets are passed.
203 // +optional
204 optional SecretReference controllerPublishSecretRef = 6;
205
206 // NodeStageSecretRef is a reference to the secret object containing sensitive
207 // information to pass to the CSI driver to complete the CSI NodeStageVolume
208 // and NodeStageVolume and NodeUnstageVolume calls.
209 // This field is optional, and may be empty if no secret is required. If the
210 // secret object contains more than one secret, all secrets are passed.
211 // +optional
212 optional SecretReference nodeStageSecretRef = 7;
213
214 // NodePublishSecretRef is a reference to the secret object containing
215 // sensitive information to pass to the CSI driver to complete the CSI
216 // NodePublishVolume and NodeUnpublishVolume calls.
217 // This field is optional, and may be empty if no secret is required. If the
218 // secret object contains more than one secret, all secrets are passed.
219 // +optional
220 optional SecretReference nodePublishSecretRef = 8;
221}
222
223// Adds and removes POSIX capabilities from running containers.
224message Capabilities {
225 // Added capabilities
226 // +optional
227 repeated string add = 1;
228
229 // Removed capabilities
230 // +optional
231 repeated string drop = 2;
232}
233
234// Represents a Ceph Filesystem mount that lasts the lifetime of a pod
235// Cephfs volumes do not support ownership management or SELinux relabeling.
236message CephFSPersistentVolumeSource {
237 // Required: Monitors is a collection of Ceph monitors
238 // More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it
239 repeated string monitors = 1;
240
241 // Optional: Used as the mounted root, rather than the full Ceph tree, default is /
242 // +optional
243 optional string path = 2;
244
245 // Optional: User is the rados user name, default is admin
246 // More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it
247 // +optional
248 optional string user = 3;
249
250 // Optional: SecretFile is the path to key ring for User, default is /etc/ceph/user.secret
251 // More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it
252 // +optional
253 optional string secretFile = 4;
254
255 // Optional: SecretRef is reference to the authentication secret for User, default is empty.
256 // More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it
257 // +optional
258 optional SecretReference secretRef = 5;
259
260 // Optional: Defaults to false (read/write). ReadOnly here will force
261 // the ReadOnly setting in VolumeMounts.
262 // More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it
263 // +optional
264 optional bool readOnly = 6;
265}
266
267// Represents a Ceph Filesystem mount that lasts the lifetime of a pod
268// Cephfs volumes do not support ownership management or SELinux relabeling.
269message CephFSVolumeSource {
270 // Required: Monitors is a collection of Ceph monitors
271 // More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it
272 repeated string monitors = 1;
273
274 // Optional: Used as the mounted root, rather than the full Ceph tree, default is /
275 // +optional
276 optional string path = 2;
277
278 // Optional: User is the rados user name, default is admin
279 // More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it
280 // +optional
281 optional string user = 3;
282
283 // Optional: SecretFile is the path to key ring for User, default is /etc/ceph/user.secret
284 // More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it
285 // +optional
286 optional string secretFile = 4;
287
288 // Optional: SecretRef is reference to the authentication secret for User, default is empty.
289 // More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it
290 // +optional
291 optional LocalObjectReference secretRef = 5;
292
293 // Optional: Defaults to false (read/write). ReadOnly here will force
294 // the ReadOnly setting in VolumeMounts.
295 // More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it
296 // +optional
297 optional bool readOnly = 6;
298}
299
300// Represents a cinder volume resource in Openstack.
301// A Cinder volume must exist before mounting to a container.
302// The volume must also be in the same region as the kubelet.
303// Cinder volumes support ownership management and SELinux relabeling.
304message CinderPersistentVolumeSource {
305 // volume id used to identify the volume in cinder
306 // More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md
307 optional string volumeID = 1;
308
309 // Filesystem type to mount.
310 // Must be a filesystem type supported by the host operating system.
311 // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
312 // More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md
313 // +optional
314 optional string fsType = 2;
315
316 // Optional: Defaults to false (read/write). ReadOnly here will force
317 // the ReadOnly setting in VolumeMounts.
318 // More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md
319 // +optional
320 optional bool readOnly = 3;
321
322 // Optional: points to a secret object containing parameters used to connect
323 // to OpenStack.
324 // +optional
325 optional SecretReference secretRef = 4;
326}
327
328// Represents a cinder volume resource in Openstack.
329// A Cinder volume must exist before mounting to a container.
330// The volume must also be in the same region as the kubelet.
331// Cinder volumes support ownership management and SELinux relabeling.
332message CinderVolumeSource {
333 // volume id used to identify the volume in cinder
334 // More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md
335 optional string volumeID = 1;
336
337 // Filesystem type to mount.
338 // Must be a filesystem type supported by the host operating system.
339 // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
340 // More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md
341 // +optional
342 optional string fsType = 2;
343
344 // Optional: Defaults to false (read/write). ReadOnly here will force
345 // the ReadOnly setting in VolumeMounts.
346 // More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md
347 // +optional
348 optional bool readOnly = 3;
349
350 // Optional: points to a secret object containing parameters used to connect
351 // to OpenStack.
352 // +optional
353 optional LocalObjectReference secretRef = 4;
354}
355
356// ClientIPConfig represents the configurations of Client IP based session affinity.
357message ClientIPConfig {
358 // timeoutSeconds specifies the seconds of ClientIP type session sticky time.
359 // The value must be >0 && <=86400(for 1 day) if ServiceAffinity == "ClientIP".
360 // Default value is 10800(for 3 hours).
361 // +optional
362 optional int32 timeoutSeconds = 1;
363}
364
365// Information about the condition of a component.
366message ComponentCondition {
367 // Type of condition for a component.
368 // Valid value: "Healthy"
369 optional string type = 1;
370
371 // Status of the condition for a component.
372 // Valid values for "Healthy": "True", "False", or "Unknown".
373 optional string status = 2;
374
375 // Message about the condition for a component.
376 // For example, information about a health check.
377 // +optional
378 optional string message = 3;
379
380 // Condition error code for a component.
381 // For example, a health check error code.
382 // +optional
383 optional string error = 4;
384}
385
386// ComponentStatus (and ComponentStatusList) holds the cluster validation info.
387message ComponentStatus {
388 // Standard object's metadata.
389 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata
390 // +optional
391 optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
392
393 // List of component conditions observed
394 // +optional
395 // +patchMergeKey=type
396 // +patchStrategy=merge
397 repeated ComponentCondition conditions = 2;
398}
399
400// Status of all the conditions for the component as a list of ComponentStatus objects.
401message ComponentStatusList {
402 // Standard list metadata.
403 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds
404 // +optional
405 optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1;
406
407 // List of ComponentStatus objects.
408 repeated ComponentStatus items = 2;
409}
410
411// ConfigMap holds configuration data for pods to consume.
412message ConfigMap {
413 // Standard object's metadata.
414 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata
415 // +optional
416 optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
417
418 // Data contains the configuration data.
419 // Each key must consist of alphanumeric characters, '-', '_' or '.'.
420 // Values with non-UTF-8 byte sequences must use the BinaryData field.
421 // The keys stored in Data must not overlap with the keys in
422 // the BinaryData field, this is enforced during validation process.
423 // +optional
424 map<string, string> data = 2;
425
426 // BinaryData contains the binary data.
427 // Each key must consist of alphanumeric characters, '-', '_' or '.'.
428 // BinaryData can contain byte sequences that are not in the UTF-8 range.
429 // The keys stored in BinaryData must not overlap with the ones in
430 // the Data field, this is enforced during validation process.
431 // Using this field will require 1.10+ apiserver and
432 // kubelet.
433 // +optional
434 map<string, bytes> binaryData = 3;
435}
436
437// ConfigMapEnvSource selects a ConfigMap to populate the environment
438// variables with.
439//
440// The contents of the target ConfigMap's Data field will represent the
441// key-value pairs as environment variables.
442message ConfigMapEnvSource {
443 // The ConfigMap to select from.
444 optional LocalObjectReference localObjectReference = 1;
445
446 // Specify whether the ConfigMap must be defined
447 // +optional
448 optional bool optional = 2;
449}
450
451// Selects a key from a ConfigMap.
452message ConfigMapKeySelector {
453 // The ConfigMap to select from.
454 optional LocalObjectReference localObjectReference = 1;
455
456 // The key to select.
457 optional string key = 2;
458
459 // Specify whether the ConfigMap or it's key must be defined
460 // +optional
461 optional bool optional = 3;
462}
463
464// ConfigMapList is a resource containing a list of ConfigMap objects.
465message ConfigMapList {
466 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata
467 // +optional
468 optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1;
469
470 // Items is the list of ConfigMaps.
471 repeated ConfigMap items = 2;
472}
473
474// ConfigMapNodeConfigSource contains the information to reference a ConfigMap as a config source for the Node.
475message ConfigMapNodeConfigSource {
476 // Namespace is the metadata.namespace of the referenced ConfigMap.
477 // This field is required in all cases.
478 optional string namespace = 1;
479
480 // Name is the metadata.name of the referenced ConfigMap.
481 // This field is required in all cases.
482 optional string name = 2;
483
484 // UID is the metadata.UID of the referenced ConfigMap.
485 // This field is forbidden in Node.Spec, and required in Node.Status.
486 // +optional
487 optional string uid = 3;
488
489 // ResourceVersion is the metadata.ResourceVersion of the referenced ConfigMap.
490 // This field is forbidden in Node.Spec, and required in Node.Status.
491 // +optional
492 optional string resourceVersion = 4;
493
494 // KubeletConfigKey declares which key of the referenced ConfigMap corresponds to the KubeletConfiguration structure
495 // This field is required in all cases.
496 optional string kubeletConfigKey = 5;
497}
498
499// Adapts a ConfigMap into a projected volume.
500//
501// The contents of the target ConfigMap's Data field will be presented in a
502// projected volume as files using the keys in the Data field as the file names,
503// unless the items element is populated with specific mappings of keys to paths.
504// Note that this is identical to a configmap volume source without the default
505// mode.
506message ConfigMapProjection {
507 optional LocalObjectReference localObjectReference = 1;
508
509 // If unspecified, each key-value pair in the Data field of the referenced
510 // ConfigMap will be projected into the volume as a file whose name is the
511 // key and content is the value. If specified, the listed keys will be
512 // projected into the specified paths, and unlisted keys will not be
513 // present. If a key is specified which is not present in the ConfigMap,
514 // the volume setup will error unless it is marked optional. Paths must be
515 // relative and may not contain the '..' path or start with '..'.
516 // +optional
517 repeated KeyToPath items = 2;
518
519 // Specify whether the ConfigMap or it's keys must be defined
520 // +optional
521 optional bool optional = 4;
522}
523
524// Adapts a ConfigMap into a volume.
525//
526// The contents of the target ConfigMap's Data field will be presented in a
527// volume as files using the keys in the Data field as the file names, unless
528// the items element is populated with specific mappings of keys to paths.
529// ConfigMap volumes support ownership management and SELinux relabeling.
530message ConfigMapVolumeSource {
531 optional LocalObjectReference localObjectReference = 1;
532
533 // If unspecified, each key-value pair in the Data field of the referenced
534 // ConfigMap will be projected into the volume as a file whose name is the
535 // key and content is the value. If specified, the listed keys will be
536 // projected into the specified paths, and unlisted keys will not be
537 // present. If a key is specified which is not present in the ConfigMap,
538 // the volume setup will error unless it is marked optional. Paths must be
539 // relative and may not contain the '..' path or start with '..'.
540 // +optional
541 repeated KeyToPath items = 2;
542
543 // Optional: mode bits to use on created files by default. Must be a
544 // value between 0 and 0777. Defaults to 0644.
545 // Directories within the path are not affected by this setting.
546 // This might be in conflict with other options that affect the file
547 // mode, like fsGroup, and the result can be other mode bits set.
548 // +optional
549 optional int32 defaultMode = 3;
550
551 // Specify whether the ConfigMap or it's keys must be defined
552 // +optional
553 optional bool optional = 4;
554}
555
556// A single application container that you want to run within a pod.
557message Container {
558 // Name of the container specified as a DNS_LABEL.
559 // Each container in a pod must have a unique name (DNS_LABEL).
560 // Cannot be updated.
561 optional string name = 1;
562
563 // Docker image name.
564 // More info: https://kubernetes.io/docs/concepts/containers/images
565 // This field is optional to allow higher level config management to default or override
566 // container images in workload controllers like Deployments and StatefulSets.
567 // +optional
568 optional string image = 2;
569
570 // Entrypoint array. Not executed within a shell.
571 // The docker image's ENTRYPOINT is used if this is not provided.
572 // Variable references $(VAR_NAME) are expanded using the container's environment. If a variable
573 // cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax
574 // can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded,
575 // regardless of whether the variable exists or not.
576 // Cannot be updated.
577 // More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell
578 // +optional
579 repeated string command = 3;
580
581 // Arguments to the entrypoint.
582 // The docker image's CMD is used if this is not provided.
583 // Variable references $(VAR_NAME) are expanded using the container's environment. If a variable
584 // cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax
585 // can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded,
586 // regardless of whether the variable exists or not.
587 // Cannot be updated.
588 // More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell
589 // +optional
590 repeated string args = 4;
591
592 // Container's working directory.
593 // If not specified, the container runtime's default will be used, which
594 // might be configured in the container image.
595 // Cannot be updated.
596 // +optional
597 optional string workingDir = 5;
598
599 // List of ports to expose from the container. Exposing a port here gives
600 // the system additional information about the network connections a
601 // container uses, but is primarily informational. Not specifying a port here
602 // DOES NOT prevent that port from being exposed. Any port which is
603 // listening on the default "0.0.0.0" address inside a container will be
604 // accessible from the network.
605 // Cannot be updated.
606 // +optional
607 // +patchMergeKey=containerPort
608 // +patchStrategy=merge
609 // +listType=map
610 // +listMapKey=containerPort
611 // +listMapKey=protocol
612 repeated ContainerPort ports = 6;
613
614 // List of sources to populate environment variables in the container.
615 // The keys defined within a source must be a C_IDENTIFIER. All invalid keys
616 // will be reported as an event when the container is starting. When a key exists in multiple
617 // sources, the value associated with the last source will take precedence.
618 // Values defined by an Env with a duplicate key will take precedence.
619 // Cannot be updated.
620 // +optional
621 repeated EnvFromSource envFrom = 19;
622
623 // List of environment variables to set in the container.
624 // Cannot be updated.
625 // +optional
626 // +patchMergeKey=name
627 // +patchStrategy=merge
628 repeated EnvVar env = 7;
629
630 // Compute Resources required by this container.
631 // Cannot be updated.
632 // More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/
633 // +optional
634 optional ResourceRequirements resources = 8;
635
636 // Pod volumes to mount into the container's filesystem.
637 // Cannot be updated.
638 // +optional
639 // +patchMergeKey=mountPath
640 // +patchStrategy=merge
641 repeated VolumeMount volumeMounts = 9;
642
643 // volumeDevices is the list of block devices to be used by the container.
644 // This is a beta feature.
645 // +patchMergeKey=devicePath
646 // +patchStrategy=merge
647 // +optional
648 repeated VolumeDevice volumeDevices = 21;
649
650 // Periodic probe of container liveness.
651 // Container will be restarted if the probe fails.
652 // Cannot be updated.
653 // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes
654 // +optional
655 optional Probe livenessProbe = 10;
656
657 // Periodic probe of container service readiness.
658 // Container will be removed from service endpoints if the probe fails.
659 // Cannot be updated.
660 // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes
661 // +optional
662 optional Probe readinessProbe = 11;
663
664 // Actions that the management system should take in response to container lifecycle events.
665 // Cannot be updated.
666 // +optional
667 optional Lifecycle lifecycle = 12;
668
669 // Optional: Path at which the file to which the container's termination message
670 // will be written is mounted into the container's filesystem.
671 // Message written is intended to be brief final status, such as an assertion failure message.
672 // Will be truncated by the node if greater than 4096 bytes. The total message length across
673 // all containers will be limited to 12kb.
674 // Defaults to /dev/termination-log.
675 // Cannot be updated.
676 // +optional
677 optional string terminationMessagePath = 13;
678
679 // Indicate how the termination message should be populated. File will use the contents of
680 // terminationMessagePath to populate the container status message on both success and failure.
681 // FallbackToLogsOnError will use the last chunk of container log output if the termination
682 // message file is empty and the container exited with an error.
683 // The log output is limited to 2048 bytes or 80 lines, whichever is smaller.
684 // Defaults to File.
685 // Cannot be updated.
686 // +optional
687 optional string terminationMessagePolicy = 20;
688
689 // Image pull policy.
690 // One of Always, Never, IfNotPresent.
691 // Defaults to Always if :latest tag is specified, or IfNotPresent otherwise.
692 // Cannot be updated.
693 // More info: https://kubernetes.io/docs/concepts/containers/images#updating-images
694 // +optional
695 optional string imagePullPolicy = 14;
696
697 // Security options the pod should run with.
698 // More info: https://kubernetes.io/docs/concepts/policy/security-context/
699 // More info: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/
700 // +optional
701 optional SecurityContext securityContext = 15;
702
703 // Whether this container should allocate a buffer for stdin in the container runtime. If this
704 // is not set, reads from stdin in the container will always result in EOF.
705 // Default is false.
706 // +optional
707 optional bool stdin = 16;
708
709 // Whether the container runtime should close the stdin channel after it has been opened by
710 // a single attach. When stdin is true the stdin stream will remain open across multiple attach
711 // sessions. If stdinOnce is set to true, stdin is opened on container start, is empty until the
712 // first client attaches to stdin, and then remains open and accepts data until the client disconnects,
713 // at which time stdin is closed and remains closed until the container is restarted. If this
714 // flag is false, a container processes that reads from stdin will never receive an EOF.
715 // Default is false
716 // +optional
717 optional bool stdinOnce = 17;
718
719 // Whether this container should allocate a TTY for itself, also requires 'stdin' to be true.
720 // Default is false.
721 // +optional
722 optional bool tty = 18;
723}
724
725// Describe a container image
726message ContainerImage {
727 // Names by which this image is known.
728 // e.g. ["k8s.gcr.io/hyperkube:v1.0.7", "dockerhub.io/google_containers/hyperkube:v1.0.7"]
729 repeated string names = 1;
730
731 // The size of the image in bytes.
732 // +optional
733 optional int64 sizeBytes = 2;
734}
735
736// ContainerPort represents a network port in a single container.
737message ContainerPort {
738 // If specified, this must be an IANA_SVC_NAME and unique within the pod. Each
739 // named port in a pod must have a unique name. Name for the port that can be
740 // referred to by services.
741 // +optional
742 optional string name = 1;
743
744 // Number of port to expose on the host.
745 // If specified, this must be a valid port number, 0 < x < 65536.
746 // If HostNetwork is specified, this must match ContainerPort.
747 // Most containers do not need this.
748 // +optional
749 optional int32 hostPort = 2;
750
751 // Number of port to expose on the pod's IP address.
752 // This must be a valid port number, 0 < x < 65536.
753 optional int32 containerPort = 3;
754
755 // Protocol for port. Must be UDP, TCP, or SCTP.
756 // Defaults to "TCP".
757 // +optional
758 optional string protocol = 4;
759
760 // What host IP to bind the external port to.
761 // +optional
762 optional string hostIP = 5;
763}
764
765// ContainerState holds a possible state of container.
766// Only one of its members may be specified.
767// If none of them is specified, the default one is ContainerStateWaiting.
768message ContainerState {
769 // Details about a waiting container
770 // +optional
771 optional ContainerStateWaiting waiting = 1;
772
773 // Details about a running container
774 // +optional
775 optional ContainerStateRunning running = 2;
776
777 // Details about a terminated container
778 // +optional
779 optional ContainerStateTerminated terminated = 3;
780}
781
782// ContainerStateRunning is a running state of a container.
783message ContainerStateRunning {
784 // Time at which the container was last (re-)started
785 // +optional
786 optional k8s.io.apimachinery.pkg.apis.meta.v1.Time startedAt = 1;
787}
788
789// ContainerStateTerminated is a terminated state of a container.
790message ContainerStateTerminated {
791 // Exit status from the last termination of the container
792 optional int32 exitCode = 1;
793
794 // Signal from the last termination of the container
795 // +optional
796 optional int32 signal = 2;
797
798 // (brief) reason from the last termination of the container
799 // +optional
800 optional string reason = 3;
801
802 // Message regarding the last termination of the container
803 // +optional
804 optional string message = 4;
805
806 // Time at which previous execution of the container started
807 // +optional
808 optional k8s.io.apimachinery.pkg.apis.meta.v1.Time startedAt = 5;
809
810 // Time at which the container last terminated
811 // +optional
812 optional k8s.io.apimachinery.pkg.apis.meta.v1.Time finishedAt = 6;
813
814 // Container's ID in the format 'docker://<container_id>'
815 // +optional
816 optional string containerID = 7;
817}
818
819// ContainerStateWaiting is a waiting state of a container.
820message ContainerStateWaiting {
821 // (brief) reason the container is not yet running.
822 // +optional
823 optional string reason = 1;
824
825 // Message regarding why the container is not yet running.
826 // +optional
827 optional string message = 2;
828}
829
830// ContainerStatus contains details for the current status of this container.
831message ContainerStatus {
832 // This must be a DNS_LABEL. Each container in a pod must have a unique name.
833 // Cannot be updated.
834 optional string name = 1;
835
836 // Details about the container's current condition.
837 // +optional
838 optional ContainerState state = 2;
839
840 // Details about the container's last termination condition.
841 // +optional
842 optional ContainerState lastState = 3;
843
844 // Specifies whether the container has passed its readiness probe.
845 optional bool ready = 4;
846
847 // The number of times the container has been restarted, currently based on
848 // the number of dead containers that have not yet been removed.
849 // Note that this is calculated from dead containers. But those containers are subject to
850 // garbage collection. This value will get capped at 5 by GC.
851 optional int32 restartCount = 5;
852
853 // The image the container is running.
854 // More info: https://kubernetes.io/docs/concepts/containers/images
855 // TODO(dchen1107): Which image the container is running with?
856 optional string image = 6;
857
858 // ImageID of the container's image.
859 optional string imageID = 7;
860
861 // Container's ID in the format 'docker://<container_id>'.
862 // +optional
863 optional string containerID = 8;
864}
865
866// DaemonEndpoint contains information about a single Daemon endpoint.
867message DaemonEndpoint {
868 // Port number of the given endpoint.
869 optional int32 Port = 1;
870}
871
872// Represents downward API info for projecting into a projected volume.
873// Note that this is identical to a downwardAPI volume source without the default
874// mode.
875message DownwardAPIProjection {
876 // Items is a list of DownwardAPIVolume file
877 // +optional
878 repeated DownwardAPIVolumeFile items = 1;
879}
880
881// DownwardAPIVolumeFile represents information to create the file containing the pod field
882message DownwardAPIVolumeFile {
883 // Required: Path is the relative path name of the file to be created. Must not be absolute or contain the '..' path. Must be utf-8 encoded. The first item of the relative path must not start with '..'
884 optional string path = 1;
885
886 // Required: Selects a field of the pod: only annotations, labels, name and namespace are supported.
887 // +optional
888 optional ObjectFieldSelector fieldRef = 2;
889
890 // Selects a resource of the container: only resources limits and requests
891 // (limits.cpu, limits.memory, requests.cpu and requests.memory) are currently supported.
892 // +optional
893 optional ResourceFieldSelector resourceFieldRef = 3;
894
895 // Optional: mode bits to use on this file, must be a value between 0
896 // and 0777. If not specified, the volume defaultMode will be used.
897 // This might be in conflict with other options that affect the file
898 // mode, like fsGroup, and the result can be other mode bits set.
899 // +optional
900 optional int32 mode = 4;
901}
902
903// DownwardAPIVolumeSource represents a volume containing downward API info.
904// Downward API volumes support ownership management and SELinux relabeling.
905message DownwardAPIVolumeSource {
906 // Items is a list of downward API volume file
907 // +optional
908 repeated DownwardAPIVolumeFile items = 1;
909
910 // Optional: mode bits to use on created files by default. Must be a
911 // value between 0 and 0777. Defaults to 0644.
912 // Directories within the path are not affected by this setting.
913 // This might be in conflict with other options that affect the file
914 // mode, like fsGroup, and the result can be other mode bits set.
915 // +optional
916 optional int32 defaultMode = 2;
917}
918
919// Represents an empty directory for a pod.
920// Empty directory volumes support ownership management and SELinux relabeling.
921message EmptyDirVolumeSource {
922 // What type of storage medium should back this directory.
923 // The default is "" which means to use the node's default medium.
924 // Must be an empty string (default) or Memory.
925 // More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir
926 // +optional
927 optional string medium = 1;
928
929 // Total amount of local storage required for this EmptyDir volume.
930 // The size limit is also applicable for memory medium.
931 // The maximum usage on memory medium EmptyDir would be the minimum value between
932 // the SizeLimit specified here and the sum of memory limits of all containers in a pod.
933 // The default is nil which means that the limit is undefined.
934 // More info: http://kubernetes.io/docs/user-guide/volumes#emptydir
935 // +optional
936 optional k8s.io.apimachinery.pkg.api.resource.Quantity sizeLimit = 2;
937}
938
939// EndpointAddress is a tuple that describes single IP address.
940message EndpointAddress {
941 // The IP of this endpoint.
942 // May not be loopback (127.0.0.0/8), link-local (169.254.0.0/16),
943 // or link-local multicast ((224.0.0.0/24).
944 // IPv6 is also accepted but not fully supported on all platforms. Also, certain
945 // kubernetes components, like kube-proxy, are not IPv6 ready.
946 // TODO: This should allow hostname or IP, See #4447.
947 optional string ip = 1;
948
949 // The Hostname of this endpoint
950 // +optional
951 optional string hostname = 3;
952
953 // Optional: Node hosting this endpoint. This can be used to determine endpoints local to a node.
954 // +optional
955 optional string nodeName = 4;
956
957 // Reference to object providing the endpoint.
958 // +optional
959 optional ObjectReference targetRef = 2;
960}
961
962// EndpointPort is a tuple that describes a single port.
963message EndpointPort {
964 // The name of this port (corresponds to ServicePort.Name).
965 // Must be a DNS_LABEL.
966 // Optional only if one port is defined.
967 // +optional
968 optional string name = 1;
969
970 // The port number of the endpoint.
971 optional int32 port = 2;
972
973 // The IP protocol for this port.
974 // Must be UDP, TCP, or SCTP.
975 // Default is TCP.
976 // +optional
977 optional string protocol = 3;
978}
979
980// EndpointSubset is a group of addresses with a common set of ports. The
981// expanded set of endpoints is the Cartesian product of Addresses x Ports.
982// For example, given:
983// {
984// Addresses: [{"ip": "10.10.1.1"}, {"ip": "10.10.2.2"}],
985// Ports: [{"name": "a", "port": 8675}, {"name": "b", "port": 309}]
986// }
987// The resulting set of endpoints can be viewed as:
988// a: [ 10.10.1.1:8675, 10.10.2.2:8675 ],
989// b: [ 10.10.1.1:309, 10.10.2.2:309 ]
990message EndpointSubset {
991 // IP addresses which offer the related ports that are marked as ready. These endpoints
992 // should be considered safe for load balancers and clients to utilize.
993 // +optional
994 repeated EndpointAddress addresses = 1;
995
996 // IP addresses which offer the related ports but are not currently marked as ready
997 // because they have not yet finished starting, have recently failed a readiness check,
998 // or have recently failed a liveness check.
999 // +optional
1000 repeated EndpointAddress notReadyAddresses = 2;
1001
1002 // Port numbers available on the related IP addresses.
1003 // +optional
1004 repeated EndpointPort ports = 3;
1005}
1006
1007// Endpoints is a collection of endpoints that implement the actual service. Example:
1008// Name: "mysvc",
1009// Subsets: [
1010// {
1011// Addresses: [{"ip": "10.10.1.1"}, {"ip": "10.10.2.2"}],
1012// Ports: [{"name": "a", "port": 8675}, {"name": "b", "port": 309}]
1013// },
1014// {
1015// Addresses: [{"ip": "10.10.3.3"}],
1016// Ports: [{"name": "a", "port": 93}, {"name": "b", "port": 76}]
1017// },
1018// ]
1019message Endpoints {
1020 // Standard object's metadata.
1021 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata
1022 // +optional
1023 optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
1024
1025 // The set of all endpoints is the union of all subsets. Addresses are placed into
1026 // subsets according to the IPs they share. A single address with multiple ports,
1027 // some of which are ready and some of which are not (because they come from
1028 // different containers) will result in the address being displayed in different
1029 // subsets for the different ports. No address will appear in both Addresses and
1030 // NotReadyAddresses in the same subset.
1031 // Sets of addresses and ports that comprise a service.
1032 // +optional
1033 repeated EndpointSubset subsets = 2;
1034}
1035
1036// EndpointsList is a list of endpoints.
1037message EndpointsList {
1038 // Standard list metadata.
1039 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds
1040 // +optional
1041 optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1;
1042
1043 // List of endpoints.
1044 repeated Endpoints items = 2;
1045}
1046
1047// EnvFromSource represents the source of a set of ConfigMaps
1048message EnvFromSource {
1049 // An optional identifier to prepend to each key in the ConfigMap. Must be a C_IDENTIFIER.
1050 // +optional
1051 optional string prefix = 1;
1052
1053 // The ConfigMap to select from
1054 // +optional
1055 optional ConfigMapEnvSource configMapRef = 2;
1056
1057 // The Secret to select from
1058 // +optional
1059 optional SecretEnvSource secretRef = 3;
1060}
1061
1062// EnvVar represents an environment variable present in a Container.
1063message EnvVar {
1064 // Name of the environment variable. Must be a C_IDENTIFIER.
1065 optional string name = 1;
1066
1067 // Variable references $(VAR_NAME) are expanded
1068 // using the previous defined environment variables in the container and
1069 // any service environment variables. If a variable cannot be resolved,
1070 // the reference in the input string will be unchanged. The $(VAR_NAME)
1071 // syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped
1072 // references will never be expanded, regardless of whether the variable
1073 // exists or not.
1074 // Defaults to "".
1075 // +optional
1076 optional string value = 2;
1077
1078 // Source for the environment variable's value. Cannot be used if value is not empty.
1079 // +optional
1080 optional EnvVarSource valueFrom = 3;
1081}
1082
1083// EnvVarSource represents a source for the value of an EnvVar.
1084message EnvVarSource {
1085 // Selects a field of the pod: supports metadata.name, metadata.namespace, metadata.labels, metadata.annotations,
1086 // spec.nodeName, spec.serviceAccountName, status.hostIP, status.podIP.
1087 // +optional
1088 optional ObjectFieldSelector fieldRef = 1;
1089
1090 // Selects a resource of the container: only resources limits and requests
1091 // (limits.cpu, limits.memory, limits.ephemeral-storage, requests.cpu, requests.memory and requests.ephemeral-storage) are currently supported.
1092 // +optional
1093 optional ResourceFieldSelector resourceFieldRef = 2;
1094
1095 // Selects a key of a ConfigMap.
1096 // +optional
1097 optional ConfigMapKeySelector configMapKeyRef = 3;
1098
1099 // Selects a key of a secret in the pod's namespace
1100 // +optional
1101 optional SecretKeySelector secretKeyRef = 4;
1102}
1103
1104// Event is a report of an event somewhere in the cluster.
1105message Event {
1106 // Standard object's metadata.
1107 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata
1108 optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
1109
1110 // The object that this event is about.
1111 optional ObjectReference involvedObject = 2;
1112
1113 // This should be a short, machine understandable string that gives the reason
1114 // for the transition into the object's current status.
1115 // TODO: provide exact specification for format.
1116 // +optional
1117 optional string reason = 3;
1118
1119 // A human-readable description of the status of this operation.
1120 // TODO: decide on maximum length.
1121 // +optional
1122 optional string message = 4;
1123
1124 // The component reporting this event. Should be a short machine understandable string.
1125 // +optional
1126 optional EventSource source = 5;
1127
1128 // The time at which the event was first recorded. (Time of server receipt is in TypeMeta.)
1129 // +optional
1130 optional k8s.io.apimachinery.pkg.apis.meta.v1.Time firstTimestamp = 6;
1131
1132 // The time at which the most recent occurrence of this event was recorded.
1133 // +optional
1134 optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastTimestamp = 7;
1135
1136 // The number of times this event has occurred.
1137 // +optional
1138 optional int32 count = 8;
1139
1140 // Type of this event (Normal, Warning), new types could be added in the future
1141 // +optional
1142 optional string type = 9;
1143
1144 // Time when this Event was first observed.
1145 // +optional
1146 optional k8s.io.apimachinery.pkg.apis.meta.v1.MicroTime eventTime = 10;
1147
1148 // Data about the Event series this event represents or nil if it's a singleton Event.
1149 // +optional
1150 optional EventSeries series = 11;
1151
1152 // What action was taken/failed regarding to the Regarding object.
1153 // +optional
1154 optional string action = 12;
1155
1156 // Optional secondary object for more complex actions.
1157 // +optional
1158 optional ObjectReference related = 13;
1159
1160 // Name of the controller that emitted this Event, e.g. `kubernetes.io/kubelet`.
1161 // +optional
1162 optional string reportingComponent = 14;
1163
1164 // ID of the controller instance, e.g. `kubelet-xyzf`.
1165 // +optional
1166 optional string reportingInstance = 15;
1167}
1168
1169// EventList is a list of events.
1170message EventList {
1171 // Standard list metadata.
1172 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds
1173 // +optional
1174 optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1;
1175
1176 // List of events
1177 repeated Event items = 2;
1178}
1179
1180// EventSeries contain information on series of events, i.e. thing that was/is happening
1181// continuously for some time.
1182message EventSeries {
1183 // Number of occurrences in this series up to the last heartbeat time
1184 optional int32 count = 1;
1185
1186 // Time of the last occurrence observed
1187 optional k8s.io.apimachinery.pkg.apis.meta.v1.MicroTime lastObservedTime = 2;
1188
1189 // State of this Series: Ongoing or Finished
1190 optional string state = 3;
1191}
1192
1193// EventSource contains information for an event.
1194message EventSource {
1195 // Component from which the event is generated.
1196 // +optional
1197 optional string component = 1;
1198
1199 // Node name on which the event is generated.
1200 // +optional
1201 optional string host = 2;
1202}
1203
1204// ExecAction describes a "run in container" action.
1205message ExecAction {
1206 // Command is the command line to execute inside the container, the working directory for the
1207 // command is root ('/') in the container's filesystem. The command is simply exec'd, it is
1208 // not run inside a shell, so traditional shell instructions ('|', etc) won't work. To use
1209 // a shell, you need to explicitly call out to that shell.
1210 // Exit status of 0 is treated as live/healthy and non-zero is unhealthy.
1211 // +optional
1212 repeated string command = 1;
1213}
1214
1215// Represents a Fibre Channel volume.
1216// Fibre Channel volumes can only be mounted as read/write once.
1217// Fibre Channel volumes support ownership management and SELinux relabeling.
1218message FCVolumeSource {
1219 // Optional: FC target worldwide names (WWNs)
1220 // +optional
1221 repeated string targetWWNs = 1;
1222
1223 // Optional: FC target lun number
1224 // +optional
1225 optional int32 lun = 2;
1226
1227 // Filesystem type to mount.
1228 // Must be a filesystem type supported by the host operating system.
1229 // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
1230 // TODO: how do we prevent errors in the filesystem from compromising the machine
1231 // +optional
1232 optional string fsType = 3;
1233
1234 // Optional: Defaults to false (read/write). ReadOnly here will force
1235 // the ReadOnly setting in VolumeMounts.
1236 // +optional
1237 optional bool readOnly = 4;
1238
1239 // Optional: FC volume world wide identifiers (wwids)
1240 // Either wwids or combination of targetWWNs and lun must be set, but not both simultaneously.
1241 // +optional
1242 repeated string wwids = 5;
1243}
1244
1245// FlexPersistentVolumeSource represents a generic persistent volume resource that is
1246// provisioned/attached using an exec based plugin.
1247message FlexPersistentVolumeSource {
1248 // Driver is the name of the driver to use for this volume.
1249 optional string driver = 1;
1250
1251 // Filesystem type to mount.
1252 // Must be a filesystem type supported by the host operating system.
1253 // Ex. "ext4", "xfs", "ntfs". The default filesystem depends on FlexVolume script.
1254 // +optional
1255 optional string fsType = 2;
1256
1257 // Optional: SecretRef is reference to the secret object containing
1258 // sensitive information to pass to the plugin scripts. This may be
1259 // empty if no secret object is specified. If the secret object
1260 // contains more than one secret, all secrets are passed to the plugin
1261 // scripts.
1262 // +optional
1263 optional SecretReference secretRef = 3;
1264
1265 // Optional: Defaults to false (read/write). ReadOnly here will force
1266 // the ReadOnly setting in VolumeMounts.
1267 // +optional
1268 optional bool readOnly = 4;
1269
1270 // Optional: Extra command options if any.
1271 // +optional
1272 map<string, string> options = 5;
1273}
1274
1275// FlexVolume represents a generic volume resource that is
1276// provisioned/attached using an exec based plugin.
1277message FlexVolumeSource {
1278 // Driver is the name of the driver to use for this volume.
1279 optional string driver = 1;
1280
1281 // Filesystem type to mount.
1282 // Must be a filesystem type supported by the host operating system.
1283 // Ex. "ext4", "xfs", "ntfs". The default filesystem depends on FlexVolume script.
1284 // +optional
1285 optional string fsType = 2;
1286
1287 // Optional: SecretRef is reference to the secret object containing
1288 // sensitive information to pass to the plugin scripts. This may be
1289 // empty if no secret object is specified. If the secret object
1290 // contains more than one secret, all secrets are passed to the plugin
1291 // scripts.
1292 // +optional
1293 optional LocalObjectReference secretRef = 3;
1294
1295 // Optional: Defaults to false (read/write). ReadOnly here will force
1296 // the ReadOnly setting in VolumeMounts.
1297 // +optional
1298 optional bool readOnly = 4;
1299
1300 // Optional: Extra command options if any.
1301 // +optional
1302 map<string, string> options = 5;
1303}
1304
1305// Represents a Flocker volume mounted by the Flocker agent.
1306// One and only one of datasetName and datasetUUID should be set.
1307// Flocker volumes do not support ownership management or SELinux relabeling.
1308message FlockerVolumeSource {
1309 // Name of the dataset stored as metadata -> name on the dataset for Flocker
1310 // should be considered as deprecated
1311 // +optional
1312 optional string datasetName = 1;
1313
1314 // UUID of the dataset. This is unique identifier of a Flocker dataset
1315 // +optional
1316 optional string datasetUUID = 2;
1317}
1318
1319// Represents a Persistent Disk resource in Google Compute Engine.
1320//
1321// A GCE PD must exist before mounting to a container. The disk must
1322// also be in the same GCE project and zone as the kubelet. A GCE PD
1323// can only be mounted as read/write once or read-only many times. GCE
1324// PDs support ownership management and SELinux relabeling.
1325message GCEPersistentDiskVolumeSource {
1326 // Unique name of the PD resource in GCE. Used to identify the disk in GCE.
1327 // More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk
1328 optional string pdName = 1;
1329
1330 // Filesystem type of the volume that you want to mount.
1331 // Tip: Ensure that the filesystem type is supported by the host operating system.
1332 // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
1333 // More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk
1334 // TODO: how do we prevent errors in the filesystem from compromising the machine
1335 // +optional
1336 optional string fsType = 2;
1337
1338 // The partition in the volume that you want to mount.
1339 // If omitted, the default is to mount by volume name.
1340 // Examples: For volume /dev/sda1, you specify the partition as "1".
1341 // Similarly, the volume partition for /dev/sda is "0" (or you can leave the property empty).
1342 // More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk
1343 // +optional
1344 optional int32 partition = 3;
1345
1346 // ReadOnly here will force the ReadOnly setting in VolumeMounts.
1347 // Defaults to false.
1348 // More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk
1349 // +optional
1350 optional bool readOnly = 4;
1351}
1352
1353// Represents a volume that is populated with the contents of a git repository.
1354// Git repo volumes do not support ownership management.
1355// Git repo volumes support SELinux relabeling.
1356//
1357// DEPRECATED: GitRepo is deprecated. To provision a container with a git repo, mount an
1358// EmptyDir into an InitContainer that clones the repo using git, then mount the EmptyDir
1359// into the Pod's container.
1360message GitRepoVolumeSource {
1361 // Repository URL
1362 optional string repository = 1;
1363
1364 // Commit hash for the specified revision.
1365 // +optional
1366 optional string revision = 2;
1367
1368 // Target directory name.
1369 // Must not contain or start with '..'. If '.' is supplied, the volume directory will be the
1370 // git repository. Otherwise, if specified, the volume will contain the git repository in
1371 // the subdirectory with the given name.
1372 // +optional
1373 optional string directory = 3;
1374}
1375
1376// Represents a Glusterfs mount that lasts the lifetime of a pod.
1377// Glusterfs volumes do not support ownership management or SELinux relabeling.
1378message GlusterfsPersistentVolumeSource {
1379 // EndpointsName is the endpoint name that details Glusterfs topology.
1380 // More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod
1381 optional string endpoints = 1;
1382
1383 // Path is the Glusterfs volume path.
1384 // More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod
1385 optional string path = 2;
1386
1387 // ReadOnly here will force the Glusterfs volume to be mounted with read-only permissions.
1388 // Defaults to false.
1389 // More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod
1390 // +optional
1391 optional bool readOnly = 3;
1392
1393 // EndpointsNamespace is the namespace that contains Glusterfs endpoint.
1394 // If this field is empty, the EndpointNamespace defaults to the same namespace as the bound PVC.
1395 // More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod
1396 // +optional
1397 optional string endpointsNamespace = 4;
1398}
1399
1400// Represents a Glusterfs mount that lasts the lifetime of a pod.
1401// Glusterfs volumes do not support ownership management or SELinux relabeling.
1402message GlusterfsVolumeSource {
1403 // EndpointsName is the endpoint name that details Glusterfs topology.
1404 // More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod
1405 optional string endpoints = 1;
1406
1407 // Path is the Glusterfs volume path.
1408 // More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod
1409 optional string path = 2;
1410
1411 // ReadOnly here will force the Glusterfs volume to be mounted with read-only permissions.
1412 // Defaults to false.
1413 // More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod
1414 // +optional
1415 optional bool readOnly = 3;
1416}
1417
1418// HTTPGetAction describes an action based on HTTP Get requests.
1419message HTTPGetAction {
1420 // Path to access on the HTTP server.
1421 // +optional
1422 optional string path = 1;
1423
1424 // Name or number of the port to access on the container.
1425 // Number must be in the range 1 to 65535.
1426 // Name must be an IANA_SVC_NAME.
1427 optional k8s.io.apimachinery.pkg.util.intstr.IntOrString port = 2;
1428
1429 // Host name to connect to, defaults to the pod IP. You probably want to set
1430 // "Host" in httpHeaders instead.
1431 // +optional
1432 optional string host = 3;
1433
1434 // Scheme to use for connecting to the host.
1435 // Defaults to HTTP.
1436 // +optional
1437 optional string scheme = 4;
1438
1439 // Custom headers to set in the request. HTTP allows repeated headers.
1440 // +optional
1441 repeated HTTPHeader httpHeaders = 5;
1442}
1443
1444// HTTPHeader describes a custom header to be used in HTTP probes
1445message HTTPHeader {
1446 // The header field name
1447 optional string name = 1;
1448
1449 // The header field value
1450 optional string value = 2;
1451}
1452
1453// Handler defines a specific action that should be taken
1454// TODO: pass structured data to these actions, and document that data here.
1455message Handler {
1456 // One and only one of the following should be specified.
1457 // Exec specifies the action to take.
1458 // +optional
1459 optional ExecAction exec = 1;
1460
1461 // HTTPGet specifies the http request to perform.
1462 // +optional
1463 optional HTTPGetAction httpGet = 2;
1464
1465 // TCPSocket specifies an action involving a TCP port.
1466 // TCP hooks not yet supported
1467 // TODO: implement a realistic TCP lifecycle hook
1468 // +optional
1469 optional TCPSocketAction tcpSocket = 3;
1470}
1471
1472// HostAlias holds the mapping between IP and hostnames that will be injected as an entry in the
1473// pod's hosts file.
1474message HostAlias {
1475 // IP address of the host file entry.
1476 optional string ip = 1;
1477
1478 // Hostnames for the above IP address.
1479 repeated string hostnames = 2;
1480}
1481
1482// Represents a host path mapped into a pod.
1483// Host path volumes do not support ownership management or SELinux relabeling.
1484message HostPathVolumeSource {
1485 // Path of the directory on the host.
1486 // If the path is a symlink, it will follow the link to the real path.
1487 // More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath
1488 optional string path = 1;
1489
1490 // Type for HostPath Volume
1491 // Defaults to ""
1492 // More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath
1493 // +optional
1494 optional string type = 2;
1495}
1496
1497// ISCSIPersistentVolumeSource represents an ISCSI disk.
1498// ISCSI volumes can only be mounted as read/write once.
1499// ISCSI volumes support ownership management and SELinux relabeling.
1500message ISCSIPersistentVolumeSource {
1501 // iSCSI Target Portal. The Portal is either an IP or ip_addr:port if the port
1502 // is other than default (typically TCP ports 860 and 3260).
1503 optional string targetPortal = 1;
1504
1505 // Target iSCSI Qualified Name.
1506 optional string iqn = 2;
1507
1508 // iSCSI Target Lun number.
1509 optional int32 lun = 3;
1510
1511 // iSCSI Interface Name that uses an iSCSI transport.
1512 // Defaults to 'default' (tcp).
1513 // +optional
1514 optional string iscsiInterface = 4;
1515
1516 // Filesystem type of the volume that you want to mount.
1517 // Tip: Ensure that the filesystem type is supported by the host operating system.
1518 // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
1519 // More info: https://kubernetes.io/docs/concepts/storage/volumes#iscsi
1520 // TODO: how do we prevent errors in the filesystem from compromising the machine
1521 // +optional
1522 optional string fsType = 5;
1523
1524 // ReadOnly here will force the ReadOnly setting in VolumeMounts.
1525 // Defaults to false.
1526 // +optional
1527 optional bool readOnly = 6;
1528
1529 // iSCSI Target Portal List. The Portal is either an IP or ip_addr:port if the port
1530 // is other than default (typically TCP ports 860 and 3260).
1531 // +optional
1532 repeated string portals = 7;
1533
1534 // whether support iSCSI Discovery CHAP authentication
1535 // +optional
1536 optional bool chapAuthDiscovery = 8;
1537
1538 // whether support iSCSI Session CHAP authentication
1539 // +optional
1540 optional bool chapAuthSession = 11;
1541
1542 // CHAP Secret for iSCSI target and initiator authentication
1543 // +optional
1544 optional SecretReference secretRef = 10;
1545
1546 // Custom iSCSI Initiator Name.
1547 // If initiatorName is specified with iscsiInterface simultaneously, new iSCSI interface
1548 // <target portal>:<volume name> will be created for the connection.
1549 // +optional
1550 optional string initiatorName = 12;
1551}
1552
1553// Represents an ISCSI disk.
1554// ISCSI volumes can only be mounted as read/write once.
1555// ISCSI volumes support ownership management and SELinux relabeling.
1556message ISCSIVolumeSource {
1557 // iSCSI Target Portal. The Portal is either an IP or ip_addr:port if the port
1558 // is other than default (typically TCP ports 860 and 3260).
1559 optional string targetPortal = 1;
1560
1561 // Target iSCSI Qualified Name.
1562 optional string iqn = 2;
1563
1564 // iSCSI Target Lun number.
1565 optional int32 lun = 3;
1566
1567 // iSCSI Interface Name that uses an iSCSI transport.
1568 // Defaults to 'default' (tcp).
1569 // +optional
1570 optional string iscsiInterface = 4;
1571
1572 // Filesystem type of the volume that you want to mount.
1573 // Tip: Ensure that the filesystem type is supported by the host operating system.
1574 // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
1575 // More info: https://kubernetes.io/docs/concepts/storage/volumes#iscsi
1576 // TODO: how do we prevent errors in the filesystem from compromising the machine
1577 // +optional
1578 optional string fsType = 5;
1579
1580 // ReadOnly here will force the ReadOnly setting in VolumeMounts.
1581 // Defaults to false.
1582 // +optional
1583 optional bool readOnly = 6;
1584
1585 // iSCSI Target Portal List. The portal is either an IP or ip_addr:port if the port
1586 // is other than default (typically TCP ports 860 and 3260).
1587 // +optional
1588 repeated string portals = 7;
1589
1590 // whether support iSCSI Discovery CHAP authentication
1591 // +optional
1592 optional bool chapAuthDiscovery = 8;
1593
1594 // whether support iSCSI Session CHAP authentication
1595 // +optional
1596 optional bool chapAuthSession = 11;
1597
1598 // CHAP Secret for iSCSI target and initiator authentication
1599 // +optional
1600 optional LocalObjectReference secretRef = 10;
1601
1602 // Custom iSCSI Initiator Name.
1603 // If initiatorName is specified with iscsiInterface simultaneously, new iSCSI interface
1604 // <target portal>:<volume name> will be created for the connection.
1605 // +optional
1606 optional string initiatorName = 12;
1607}
1608
1609// Maps a string key to a path within a volume.
1610message KeyToPath {
1611 // The key to project.
1612 optional string key = 1;
1613
1614 // The relative path of the file to map the key to.
1615 // May not be an absolute path.
1616 // May not contain the path element '..'.
1617 // May not start with the string '..'.
1618 optional string path = 2;
1619
1620 // Optional: mode bits to use on this file, must be a value between 0
1621 // and 0777. If not specified, the volume defaultMode will be used.
1622 // This might be in conflict with other options that affect the file
1623 // mode, like fsGroup, and the result can be other mode bits set.
1624 // +optional
1625 optional int32 mode = 3;
1626}
1627
1628// Lifecycle describes actions that the management system should take in response to container lifecycle
1629// events. For the PostStart and PreStop lifecycle handlers, management of the container blocks
1630// until the action is complete, unless the container process fails, in which case the handler is aborted.
1631message Lifecycle {
1632 // PostStart is called immediately after a container is created. If the handler fails,
1633 // the container is terminated and restarted according to its restart policy.
1634 // Other management of the container blocks until the hook completes.
1635 // More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks
1636 // +optional
1637 optional Handler postStart = 1;
1638
1639 // PreStop is called immediately before a container is terminated.
1640 // The container is terminated after the handler completes.
1641 // The reason for termination is passed to the handler.
1642 // Regardless of the outcome of the handler, the container is eventually terminated.
1643 // Other management of the container blocks until the hook completes.
1644 // More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks
1645 // +optional
1646 optional Handler preStop = 2;
1647}
1648
1649// LimitRange sets resource usage limits for each kind of resource in a Namespace.
1650message LimitRange {
1651 // Standard object's metadata.
1652 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata
1653 // +optional
1654 optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
1655
1656 // Spec defines the limits enforced.
1657 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status
1658 // +optional
1659 optional LimitRangeSpec spec = 2;
1660}
1661
1662// LimitRangeItem defines a min/max usage limit for any resource that matches on kind.
1663message LimitRangeItem {
1664 // Type of resource that this limit applies to.
1665 // +optional
1666 optional string type = 1;
1667
1668 // Max usage constraints on this kind by resource name.
1669 // +optional
1670 map<string, k8s.io.apimachinery.pkg.api.resource.Quantity> max = 2;
1671
1672 // Min usage constraints on this kind by resource name.
1673 // +optional
1674 map<string, k8s.io.apimachinery.pkg.api.resource.Quantity> min = 3;
1675
1676 // Default resource requirement limit value by resource name if resource limit is omitted.
1677 // +optional
1678 map<string, k8s.io.apimachinery.pkg.api.resource.Quantity> default = 4;
1679
1680 // DefaultRequest is the default resource requirement request value by resource name if resource request is omitted.
1681 // +optional
1682 map<string, k8s.io.apimachinery.pkg.api.resource.Quantity> defaultRequest = 5;
1683
1684 // MaxLimitRequestRatio if specified, the named resource must have a request and limit that are both non-zero where limit divided by request is less than or equal to the enumerated value; this represents the max burst for the named resource.
1685 // +optional
1686 map<string, k8s.io.apimachinery.pkg.api.resource.Quantity> maxLimitRequestRatio = 6;
1687}
1688
1689// LimitRangeList is a list of LimitRange items.
1690message LimitRangeList {
1691 // Standard list metadata.
1692 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds
1693 // +optional
1694 optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1;
1695
1696 // Items is a list of LimitRange objects.
1697 // More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/
1698 repeated LimitRange items = 2;
1699}
1700
1701// LimitRangeSpec defines a min/max usage limit for resources that match on kind.
1702message LimitRangeSpec {
1703 // Limits is the list of LimitRangeItem objects that are enforced.
1704 repeated LimitRangeItem limits = 1;
1705}
1706
1707// List holds a list of objects, which may not be known by the server.
1708message List {
1709 // Standard list metadata.
1710 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds
1711 // +optional
1712 optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1;
1713
1714 // List of objects
1715 repeated k8s.io.apimachinery.pkg.runtime.RawExtension items = 2;
1716}
1717
1718// LoadBalancerIngress represents the status of a load-balancer ingress point:
1719// traffic intended for the service should be sent to an ingress point.
1720message LoadBalancerIngress {
1721 // IP is set for load-balancer ingress points that are IP based
1722 // (typically GCE or OpenStack load-balancers)
1723 // +optional
1724 optional string ip = 1;
1725
1726 // Hostname is set for load-balancer ingress points that are DNS based
1727 // (typically AWS load-balancers)
1728 // +optional
1729 optional string hostname = 2;
1730}
1731
1732// LoadBalancerStatus represents the status of a load-balancer.
1733message LoadBalancerStatus {
1734 // Ingress is a list containing ingress points for the load-balancer.
1735 // Traffic intended for the service should be sent to these ingress points.
1736 // +optional
1737 repeated LoadBalancerIngress ingress = 1;
1738}
1739
1740// LocalObjectReference contains enough information to let you locate the
1741// referenced object inside the same namespace.
1742message LocalObjectReference {
1743 // Name of the referent.
1744 // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
1745 // TODO: Add other useful fields. apiVersion, kind, uid?
1746 // +optional
1747 optional string name = 1;
1748}
1749
1750// Local represents directly-attached storage with node affinity (Beta feature)
1751message LocalVolumeSource {
1752 // The full path to the volume on the node.
1753 // It can be either a directory or block device (disk, partition, ...).
1754 optional string path = 1;
1755
1756 // Filesystem type to mount.
1757 // It applies only when the Path is a block device.
1758 // Must be a filesystem type supported by the host operating system.
1759 // Ex. "ext4", "xfs", "ntfs". The default value is to auto-select a fileystem if unspecified.
1760 // +optional
1761 optional string fsType = 2;
1762}
1763
1764// Represents an NFS mount that lasts the lifetime of a pod.
1765// NFS volumes do not support ownership management or SELinux relabeling.
1766message NFSVolumeSource {
1767 // Server is the hostname or IP address of the NFS server.
1768 // More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs
1769 optional string server = 1;
1770
1771 // Path that is exported by the NFS server.
1772 // More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs
1773 optional string path = 2;
1774
1775 // ReadOnly here will force
1776 // the NFS export to be mounted with read-only permissions.
1777 // Defaults to false.
1778 // More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs
1779 // +optional
1780 optional bool readOnly = 3;
1781}
1782
1783// Namespace provides a scope for Names.
1784// Use of multiple namespaces is optional.
1785message Namespace {
1786 // Standard object's metadata.
1787 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata
1788 // +optional
1789 optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
1790
1791 // Spec defines the behavior of the Namespace.
1792 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status
1793 // +optional
1794 optional NamespaceSpec spec = 2;
1795
1796 // Status describes the current status of a Namespace.
1797 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status
1798 // +optional
1799 optional NamespaceStatus status = 3;
1800}
1801
1802// NamespaceList is a list of Namespaces.
1803message NamespaceList {
1804 // Standard list metadata.
1805 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds
1806 // +optional
1807 optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1;
1808
1809 // Items is the list of Namespace objects in the list.
1810 // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/
1811 repeated Namespace items = 2;
1812}
1813
1814// NamespaceSpec describes the attributes on a Namespace.
1815message NamespaceSpec {
1816 // Finalizers is an opaque list of values that must be empty to permanently remove object from storage.
1817 // More info: https://kubernetes.io/docs/tasks/administer-cluster/namespaces/
1818 // +optional
1819 repeated string finalizers = 1;
1820}
1821
1822// NamespaceStatus is information about the current status of a Namespace.
1823message NamespaceStatus {
1824 // Phase is the current lifecycle phase of the namespace.
1825 // More info: https://kubernetes.io/docs/tasks/administer-cluster/namespaces/
1826 // +optional
1827 optional string phase = 1;
1828}
1829
1830// Node is a worker node in Kubernetes.
1831// Each node will have a unique identifier in the cache (i.e. in etcd).
1832message Node {
1833 // Standard object's metadata.
1834 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata
1835 // +optional
1836 optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
1837
1838 // Spec defines the behavior of a node.
1839 // https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status
1840 // +optional
1841 optional NodeSpec spec = 2;
1842
1843 // Most recently observed status of the node.
1844 // Populated by the system.
1845 // Read-only.
1846 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status
1847 // +optional
1848 optional NodeStatus status = 3;
1849}
1850
1851// NodeAddress contains information for the node's address.
1852message NodeAddress {
1853 // Node address type, one of Hostname, ExternalIP or InternalIP.
1854 optional string type = 1;
1855
1856 // The node address.
1857 optional string address = 2;
1858}
1859
1860// Node affinity is a group of node affinity scheduling rules.
1861message NodeAffinity {
1862 // If the affinity requirements specified by this field are not met at
1863 // scheduling time, the pod will not be scheduled onto the node.
1864 // If the affinity requirements specified by this field cease to be met
1865 // at some point during pod execution (e.g. due to an update), the system
1866 // may or may not try to eventually evict the pod from its node.
1867 // +optional
1868 optional NodeSelector requiredDuringSchedulingIgnoredDuringExecution = 1;
1869
1870 // The scheduler will prefer to schedule pods to nodes that satisfy
1871 // the affinity expressions specified by this field, but it may choose
1872 // a node that violates one or more of the expressions. The node that is
1873 // most preferred is the one with the greatest sum of weights, i.e.
1874 // for each node that meets all of the scheduling requirements (resource
1875 // request, requiredDuringScheduling affinity expressions, etc.),
1876 // compute a sum by iterating through the elements of this field and adding
1877 // "weight" to the sum if the node matches the corresponding matchExpressions; the
1878 // node(s) with the highest sum are the most preferred.
1879 // +optional
1880 repeated PreferredSchedulingTerm preferredDuringSchedulingIgnoredDuringExecution = 2;
1881}
1882
1883// NodeCondition contains condition information for a node.
1884message NodeCondition {
1885 // Type of node condition.
1886 optional string type = 1;
1887
1888 // Status of the condition, one of True, False, Unknown.
1889 optional string status = 2;
1890
1891 // Last time we got an update on a given condition.
1892 // +optional
1893 optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastHeartbeatTime = 3;
1894
1895 // Last time the condition transit from one status to another.
1896 // +optional
1897 optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastTransitionTime = 4;
1898
1899 // (brief) reason for the condition's last transition.
1900 // +optional
1901 optional string reason = 5;
1902
1903 // Human readable message indicating details about last transition.
1904 // +optional
1905 optional string message = 6;
1906}
1907
1908// NodeConfigSource specifies a source of node configuration. Exactly one subfield (excluding metadata) must be non-nil.
1909message NodeConfigSource {
1910 // ConfigMap is a reference to a Node's ConfigMap
1911 optional ConfigMapNodeConfigSource configMap = 2;
1912}
1913
1914// NodeConfigStatus describes the status of the config assigned by Node.Spec.ConfigSource.
1915message NodeConfigStatus {
1916 // Assigned reports the checkpointed config the node will try to use.
1917 // When Node.Spec.ConfigSource is updated, the node checkpoints the associated
1918 // config payload to local disk, along with a record indicating intended
1919 // config. The node refers to this record to choose its config checkpoint, and
1920 // reports this record in Assigned. Assigned only updates in the status after
1921 // the record has been checkpointed to disk. When the Kubelet is restarted,
1922 // it tries to make the Assigned config the Active config by loading and
1923 // validating the checkpointed payload identified by Assigned.
1924 // +optional
1925 optional NodeConfigSource assigned = 1;
1926
1927 // Active reports the checkpointed config the node is actively using.
1928 // Active will represent either the current version of the Assigned config,
1929 // or the current LastKnownGood config, depending on whether attempting to use the
1930 // Assigned config results in an error.
1931 // +optional
1932 optional NodeConfigSource active = 2;
1933
1934 // LastKnownGood reports the checkpointed config the node will fall back to
1935 // when it encounters an error attempting to use the Assigned config.
1936 // The Assigned config becomes the LastKnownGood config when the node determines
1937 // that the Assigned config is stable and correct.
1938 // This is currently implemented as a 10-minute soak period starting when the local
1939 // record of Assigned config is updated. If the Assigned config is Active at the end
1940 // of this period, it becomes the LastKnownGood. Note that if Spec.ConfigSource is
1941 // reset to nil (use local defaults), the LastKnownGood is also immediately reset to nil,
1942 // because the local default config is always assumed good.
1943 // You should not make assumptions about the node's method of determining config stability
1944 // and correctness, as this may change or become configurable in the future.
1945 // +optional
1946 optional NodeConfigSource lastKnownGood = 3;
1947
1948 // Error describes any problems reconciling the Spec.ConfigSource to the Active config.
1949 // Errors may occur, for example, attempting to checkpoint Spec.ConfigSource to the local Assigned
1950 // record, attempting to checkpoint the payload associated with Spec.ConfigSource, attempting
1951 // to load or validate the Assigned config, etc.
1952 // Errors may occur at different points while syncing config. Earlier errors (e.g. download or
1953 // checkpointing errors) will not result in a rollback to LastKnownGood, and may resolve across
1954 // Kubelet retries. Later errors (e.g. loading or validating a checkpointed config) will result in
1955 // a rollback to LastKnownGood. In the latter case, it is usually possible to resolve the error
1956 // by fixing the config assigned in Spec.ConfigSource.
1957 // You can find additional information for debugging by searching the error message in the Kubelet log.
1958 // Error is a human-readable description of the error state; machines can check whether or not Error
1959 // is empty, but should not rely on the stability of the Error text across Kubelet versions.
1960 // +optional
1961 optional string error = 4;
1962}
1963
1964// NodeDaemonEndpoints lists ports opened by daemons running on the Node.
1965message NodeDaemonEndpoints {
1966 // Endpoint on which Kubelet is listening.
1967 // +optional
1968 optional DaemonEndpoint kubeletEndpoint = 1;
1969}
1970
1971// NodeList is the whole list of all Nodes which have been registered with master.
1972message NodeList {
1973 // Standard list metadata.
1974 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds
1975 // +optional
1976 optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1;
1977
1978 // List of nodes
1979 repeated Node items = 2;
1980}
1981
1982// NodeProxyOptions is the query options to a Node's proxy call.
1983message NodeProxyOptions {
1984 // Path is the URL path to use for the current proxy request to node.
1985 // +optional
1986 optional string path = 1;
1987}
1988
1989// NodeResources is an object for conveying resource information about a node.
1990// see http://releases.k8s.io/HEAD/docs/design/resources.md for more details.
1991message NodeResources {
1992 // Capacity represents the available resources of a node
1993 map<string, k8s.io.apimachinery.pkg.api.resource.Quantity> capacity = 1;
1994}
1995
1996// A node selector represents the union of the results of one or more label queries
1997// over a set of nodes; that is, it represents the OR of the selectors represented
1998// by the node selector terms.
1999message NodeSelector {
2000 // Required. A list of node selector terms. The terms are ORed.
2001 repeated NodeSelectorTerm nodeSelectorTerms = 1;
2002}
2003
2004// A node selector requirement is a selector that contains values, a key, and an operator
2005// that relates the key and values.
2006message NodeSelectorRequirement {
2007 // The label key that the selector applies to.
2008 optional string key = 1;
2009
2010 // Represents a key's relationship to a set of values.
2011 // Valid operators are In, NotIn, Exists, DoesNotExist. Gt, and Lt.
2012 optional string operator = 2;
2013
2014 // An array of string values. If the operator is In or NotIn,
2015 // the values array must be non-empty. If the operator is Exists or DoesNotExist,
2016 // the values array must be empty. If the operator is Gt or Lt, the values
2017 // array must have a single element, which will be interpreted as an integer.
2018 // This array is replaced during a strategic merge patch.
2019 // +optional
2020 repeated string values = 3;
2021}
2022
2023// A null or empty node selector term matches no objects. The requirements of
2024// them are ANDed.
2025// The TopologySelectorTerm type implements a subset of the NodeSelectorTerm.
2026message NodeSelectorTerm {
2027 // A list of node selector requirements by node's labels.
2028 // +optional
2029 repeated NodeSelectorRequirement matchExpressions = 1;
2030
2031 // A list of node selector requirements by node's fields.
2032 // +optional
2033 repeated NodeSelectorRequirement matchFields = 2;
2034}
2035
2036// NodeSpec describes the attributes that a node is created with.
2037message NodeSpec {
2038 // PodCIDR represents the pod IP range assigned to the node.
2039 // +optional
2040 optional string podCIDR = 1;
2041
2042 // ID of the node assigned by the cloud provider in the format: <ProviderName>://<ProviderSpecificNodeID>
2043 // +optional
2044 optional string providerID = 3;
2045
2046 // Unschedulable controls node schedulability of new pods. By default, node is schedulable.
2047 // More info: https://kubernetes.io/docs/concepts/nodes/node/#manual-node-administration
2048 // +optional
2049 optional bool unschedulable = 4;
2050
2051 // If specified, the node's taints.
2052 // +optional
2053 repeated Taint taints = 5;
2054
2055 // If specified, the source to get node configuration from
2056 // The DynamicKubeletConfig feature gate must be enabled for the Kubelet to use this field
2057 // +optional
2058 optional NodeConfigSource configSource = 6;
2059
2060 // Deprecated. Not all kubelets will set this field. Remove field after 1.13.
2061 // see: https://issues.k8s.io/61966
2062 // +optional
2063 optional string externalID = 2;
2064}
2065
2066// NodeStatus is information about the current status of a node.
2067message NodeStatus {
2068 // Capacity represents the total resources of a node.
2069 // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#capacity
2070 // +optional
2071 map<string, k8s.io.apimachinery.pkg.api.resource.Quantity> capacity = 1;
2072
2073 // Allocatable represents the resources of a node that are available for scheduling.
2074 // Defaults to Capacity.
2075 // +optional
2076 map<string, k8s.io.apimachinery.pkg.api.resource.Quantity> allocatable = 2;
2077
2078 // NodePhase is the recently observed lifecycle phase of the node.
2079 // More info: https://kubernetes.io/docs/concepts/nodes/node/#phase
2080 // The field is never populated, and now is deprecated.
2081 // +optional
2082 optional string phase = 3;
2083
2084 // Conditions is an array of current observed node conditions.
2085 // More info: https://kubernetes.io/docs/concepts/nodes/node/#condition
2086 // +optional
2087 // +patchMergeKey=type
2088 // +patchStrategy=merge
2089 repeated NodeCondition conditions = 4;
2090
2091 // List of addresses reachable to the node.
2092 // Queried from cloud provider, if available.
2093 // More info: https://kubernetes.io/docs/concepts/nodes/node/#addresses
2094 // +optional
2095 // +patchMergeKey=type
2096 // +patchStrategy=merge
2097 repeated NodeAddress addresses = 5;
2098
2099 // Endpoints of daemons running on the Node.
2100 // +optional
2101 optional NodeDaemonEndpoints daemonEndpoints = 6;
2102
2103 // Set of ids/uuids to uniquely identify the node.
2104 // More info: https://kubernetes.io/docs/concepts/nodes/node/#info
2105 // +optional
2106 optional NodeSystemInfo nodeInfo = 7;
2107
2108 // List of container images on this node
2109 // +optional
2110 repeated ContainerImage images = 8;
2111
2112 // List of attachable volumes in use (mounted) by the node.
2113 // +optional
2114 repeated string volumesInUse = 9;
2115
2116 // List of volumes that are attached to the node.
2117 // +optional
2118 repeated AttachedVolume volumesAttached = 10;
2119
2120 // Status of the config assigned to the node via the dynamic Kubelet config feature.
2121 // +optional
2122 optional NodeConfigStatus config = 11;
2123}
2124
2125// NodeSystemInfo is a set of ids/uuids to uniquely identify the node.
2126message NodeSystemInfo {
2127 // MachineID reported by the node. For unique machine identification
2128 // in the cluster this field is preferred. Learn more from man(5)
2129 // machine-id: http://man7.org/linux/man-pages/man5/machine-id.5.html
2130 optional string machineID = 1;
2131
2132 // SystemUUID reported by the node. For unique machine identification
2133 // MachineID is preferred. This field is specific to Red Hat hosts
2134 // https://access.redhat.com/documentation/en-US/Red_Hat_Subscription_Management/1/html/RHSM/getting-system-uuid.html
2135 optional string systemUUID = 2;
2136
2137 // Boot ID reported by the node.
2138 optional string bootID = 3;
2139
2140 // Kernel Version reported by the node from 'uname -r' (e.g. 3.16.0-0.bpo.4-amd64).
2141 optional string kernelVersion = 4;
2142
2143 // OS Image reported by the node from /etc/os-release (e.g. Debian GNU/Linux 7 (wheezy)).
2144 optional string osImage = 5;
2145
2146 // ContainerRuntime Version reported by the node through runtime remote API (e.g. docker://1.5.0).
2147 optional string containerRuntimeVersion = 6;
2148
2149 // Kubelet Version reported by the node.
2150 optional string kubeletVersion = 7;
2151
2152 // KubeProxy Version reported by the node.
2153 optional string kubeProxyVersion = 8;
2154
2155 // The Operating System reported by the node
2156 optional string operatingSystem = 9;
2157
2158 // The Architecture reported by the node
2159 optional string architecture = 10;
2160}
2161
2162// ObjectFieldSelector selects an APIVersioned field of an object.
2163message ObjectFieldSelector {
2164 // Version of the schema the FieldPath is written in terms of, defaults to "v1".
2165 // +optional
2166 optional string apiVersion = 1;
2167
2168 // Path of the field to select in the specified API version.
2169 optional string fieldPath = 2;
2170}
2171
2172// ObjectReference contains enough information to let you inspect or modify the referred object.
2173// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
2174message ObjectReference {
2175 // Kind of the referent.
2176 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds
2177 // +optional
2178 optional string kind = 1;
2179
2180 // Namespace of the referent.
2181 // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/
2182 // +optional
2183 optional string namespace = 2;
2184
2185 // Name of the referent.
2186 // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
2187 // +optional
2188 optional string name = 3;
2189
2190 // UID of the referent.
2191 // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids
2192 // +optional
2193 optional string uid = 4;
2194
2195 // API version of the referent.
2196 // +optional
2197 optional string apiVersion = 5;
2198
2199 // Specific resourceVersion to which this reference is made, if any.
2200 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency
2201 // +optional
2202 optional string resourceVersion = 6;
2203
2204 // If referring to a piece of an object instead of an entire object, this string
2205 // should contain a valid JSON/Go field access statement, such as desiredState.manifest.containers[2].
2206 // For example, if the object reference is to a container within a pod, this would take on a value like:
2207 // "spec.containers{name}" (where "name" refers to the name of the container that triggered
2208 // the event) or if no container name is specified "spec.containers[2]" (container with
2209 // index 2 in this pod). This syntax is chosen only to have some well-defined way of
2210 // referencing a part of an object.
2211 // TODO: this design is not final and this field is subject to change in the future.
2212 // +optional
2213 optional string fieldPath = 7;
2214}
2215
2216// PersistentVolume (PV) is a storage resource provisioned by an administrator.
2217// It is analogous to a node.
2218// More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes
2219message PersistentVolume {
2220 // Standard object's metadata.
2221 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata
2222 // +optional
2223 optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
2224
2225 // Spec defines a specification of a persistent volume owned by the cluster.
2226 // Provisioned by an administrator.
2227 // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistent-volumes
2228 // +optional
2229 optional PersistentVolumeSpec spec = 2;
2230
2231 // Status represents the current information/status for the persistent volume.
2232 // Populated by the system.
2233 // Read-only.
2234 // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistent-volumes
2235 // +optional
2236 optional PersistentVolumeStatus status = 3;
2237}
2238
2239// PersistentVolumeClaim is a user's request for and claim to a persistent volume
2240message PersistentVolumeClaim {
2241 // Standard object's metadata.
2242 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata
2243 // +optional
2244 optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
2245
2246 // Spec defines the desired characteristics of a volume requested by a pod author.
2247 // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims
2248 // +optional
2249 optional PersistentVolumeClaimSpec spec = 2;
2250
2251 // Status represents the current information/status of a persistent volume claim.
2252 // Read-only.
2253 // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims
2254 // +optional
2255 optional PersistentVolumeClaimStatus status = 3;
2256}
2257
2258// PersistentVolumeClaimCondition contails details about state of pvc
2259message PersistentVolumeClaimCondition {
2260 optional string type = 1;
2261
2262 optional string status = 2;
2263
2264 // Last time we probed the condition.
2265 // +optional
2266 optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastProbeTime = 3;
2267
2268 // Last time the condition transitioned from one status to another.
2269 // +optional
2270 optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastTransitionTime = 4;
2271
2272 // Unique, this should be a short, machine understandable string that gives the reason
2273 // for condition's last transition. If it reports "ResizeStarted" that means the underlying
2274 // persistent volume is being resized.
2275 // +optional
2276 optional string reason = 5;
2277
2278 // Human-readable message indicating details about last transition.
2279 // +optional
2280 optional string message = 6;
2281}
2282
2283// PersistentVolumeClaimList is a list of PersistentVolumeClaim items.
2284message PersistentVolumeClaimList {
2285 // Standard list metadata.
2286 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds
2287 // +optional
2288 optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1;
2289
2290 // A list of persistent volume claims.
2291 // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims
2292 repeated PersistentVolumeClaim items = 2;
2293}
2294
2295// PersistentVolumeClaimSpec describes the common attributes of storage devices
2296// and allows a Source for provider-specific attributes
2297message PersistentVolumeClaimSpec {
2298 // AccessModes contains the desired access modes the volume should have.
2299 // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes-1
2300 // +optional
2301 repeated string accessModes = 1;
2302
2303 // A label query over volumes to consider for binding.
2304 // +optional
2305 optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector selector = 4;
2306
2307 // Resources represents the minimum resources the volume should have.
2308 // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources
2309 // +optional
2310 optional ResourceRequirements resources = 2;
2311
2312 // VolumeName is the binding reference to the PersistentVolume backing this claim.
2313 // +optional
2314 optional string volumeName = 3;
2315
2316 // Name of the StorageClass required by the claim.
2317 // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#class-1
2318 // +optional
2319 optional string storageClassName = 5;
2320
2321 // volumeMode defines what type of volume is required by the claim.
2322 // Value of Filesystem is implied when not included in claim spec.
2323 // This is a beta feature.
2324 // +optional
2325 optional string volumeMode = 6;
2326
2327 // This field requires the VolumeSnapshotDataSource alpha feature gate to be
2328 // enabled and currently VolumeSnapshot is the only supported data source.
2329 // If the provisioner can support VolumeSnapshot data source, it will create
2330 // a new volume and data will be restored to the volume at the same time.
2331 // If the provisioner does not support VolumeSnapshot data source, volume will
2332 // not be created and the failure will be reported as an event.
2333 // In the future, we plan to support more data source types and the behavior
2334 // of the provisioner may change.
2335 // +optional
2336 optional TypedLocalObjectReference dataSource = 7;
2337}
2338
2339// PersistentVolumeClaimStatus is the current status of a persistent volume claim.
2340message PersistentVolumeClaimStatus {
2341 // Phase represents the current phase of PersistentVolumeClaim.
2342 // +optional
2343 optional string phase = 1;
2344
2345 // AccessModes contains the actual access modes the volume backing the PVC has.
2346 // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes-1
2347 // +optional
2348 repeated string accessModes = 2;
2349
2350 // Represents the actual resources of the underlying volume.
2351 // +optional
2352 map<string, k8s.io.apimachinery.pkg.api.resource.Quantity> capacity = 3;
2353
2354 // Current Condition of persistent volume claim. If underlying persistent volume is being
2355 // resized then the Condition will be set to 'ResizeStarted'.
2356 // +optional
2357 // +patchMergeKey=type
2358 // +patchStrategy=merge
2359 repeated PersistentVolumeClaimCondition conditions = 4;
2360}
2361
2362// PersistentVolumeClaimVolumeSource references the user's PVC in the same namespace.
2363// This volume finds the bound PV and mounts that volume for the pod. A
2364// PersistentVolumeClaimVolumeSource is, essentially, a wrapper around another
2365// type of volume that is owned by someone else (the system).
2366message PersistentVolumeClaimVolumeSource {
2367 // ClaimName is the name of a PersistentVolumeClaim in the same namespace as the pod using this volume.
2368 // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims
2369 optional string claimName = 1;
2370
2371 // Will force the ReadOnly setting in VolumeMounts.
2372 // Default false.
2373 // +optional
2374 optional bool readOnly = 2;
2375}
2376
2377// PersistentVolumeList is a list of PersistentVolume items.
2378message PersistentVolumeList {
2379 // Standard list metadata.
2380 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds
2381 // +optional
2382 optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1;
2383
2384 // List of persistent volumes.
2385 // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes
2386 repeated PersistentVolume items = 2;
2387}
2388
2389// PersistentVolumeSource is similar to VolumeSource but meant for the
2390// administrator who creates PVs. Exactly one of its members must be set.
2391message PersistentVolumeSource {
2392 // GCEPersistentDisk represents a GCE Disk resource that is attached to a
2393 // kubelet's host machine and then exposed to the pod. Provisioned by an admin.
2394 // More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk
2395 // +optional
2396 optional GCEPersistentDiskVolumeSource gcePersistentDisk = 1;
2397
2398 // AWSElasticBlockStore represents an AWS Disk resource that is attached to a
2399 // kubelet's host machine and then exposed to the pod.
2400 // More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore
2401 // +optional
2402 optional AWSElasticBlockStoreVolumeSource awsElasticBlockStore = 2;
2403
2404 // HostPath represents a directory on the host.
2405 // Provisioned by a developer or tester.
2406 // This is useful for single-node development and testing only!
2407 // On-host storage is not supported in any way and WILL NOT WORK in a multi-node cluster.
2408 // More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath
2409 // +optional
2410 optional HostPathVolumeSource hostPath = 3;
2411
2412 // Glusterfs represents a Glusterfs volume that is attached to a host and
2413 // exposed to the pod. Provisioned by an admin.
2414 // More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md
2415 // +optional
2416 optional GlusterfsPersistentVolumeSource glusterfs = 4;
2417
2418 // NFS represents an NFS mount on the host. Provisioned by an admin.
2419 // More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs
2420 // +optional
2421 optional NFSVolumeSource nfs = 5;
2422
2423 // RBD represents a Rados Block Device mount on the host that shares a pod's lifetime.
2424 // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md
2425 // +optional
2426 optional RBDPersistentVolumeSource rbd = 6;
2427
2428 // ISCSI represents an ISCSI Disk resource that is attached to a
2429 // kubelet's host machine and then exposed to the pod. Provisioned by an admin.
2430 // +optional
2431 optional ISCSIPersistentVolumeSource iscsi = 7;
2432
2433 // Cinder represents a cinder volume attached and mounted on kubelets host machine
2434 // More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md
2435 // +optional
2436 optional CinderPersistentVolumeSource cinder = 8;
2437
2438 // CephFS represents a Ceph FS mount on the host that shares a pod's lifetime
2439 // +optional
2440 optional CephFSPersistentVolumeSource cephfs = 9;
2441
2442 // FC represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod.
2443 // +optional
2444 optional FCVolumeSource fc = 10;
2445
2446 // Flocker represents a Flocker volume attached to a kubelet's host machine and exposed to the pod for its usage. This depends on the Flocker control service being running
2447 // +optional
2448 optional FlockerVolumeSource flocker = 11;
2449
2450 // FlexVolume represents a generic volume resource that is
2451 // provisioned/attached using an exec based plugin.
2452 // +optional
2453 optional FlexPersistentVolumeSource flexVolume = 12;
2454
2455 // AzureFile represents an Azure File Service mount on the host and bind mount to the pod.
2456 // +optional
2457 optional AzureFilePersistentVolumeSource azureFile = 13;
2458
2459 // VsphereVolume represents a vSphere volume attached and mounted on kubelets host machine
2460 // +optional
2461 optional VsphereVirtualDiskVolumeSource vsphereVolume = 14;
2462
2463 // Quobyte represents a Quobyte mount on the host that shares a pod's lifetime
2464 // +optional
2465 optional QuobyteVolumeSource quobyte = 15;
2466
2467 // AzureDisk represents an Azure Data Disk mount on the host and bind mount to the pod.
2468 // +optional
2469 optional AzureDiskVolumeSource azureDisk = 16;
2470
2471 // PhotonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine
2472 optional PhotonPersistentDiskVolumeSource photonPersistentDisk = 17;
2473
2474 // PortworxVolume represents a portworx volume attached and mounted on kubelets host machine
2475 // +optional
2476 optional PortworxVolumeSource portworxVolume = 18;
2477
2478 // ScaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes.
2479 // +optional
2480 optional ScaleIOPersistentVolumeSource scaleIO = 19;
2481
2482 // Local represents directly-attached storage with node affinity
2483 // +optional
2484 optional LocalVolumeSource local = 20;
2485
2486 // StorageOS represents a StorageOS volume that is attached to the kubelet's host machine and mounted into the pod
2487 // More info: https://releases.k8s.io/HEAD/examples/volumes/storageos/README.md
2488 // +optional
2489 optional StorageOSPersistentVolumeSource storageos = 21;
2490
2491 // CSI represents storage that handled by an external CSI driver (Beta feature).
2492 // +optional
2493 optional CSIPersistentVolumeSource csi = 22;
2494}
2495
2496// PersistentVolumeSpec is the specification of a persistent volume.
2497message PersistentVolumeSpec {
2498 // A description of the persistent volume's resources and capacity.
2499 // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#capacity
2500 // +optional
2501 map<string, k8s.io.apimachinery.pkg.api.resource.Quantity> capacity = 1;
2502
2503 // The actual volume backing the persistent volume.
2504 optional PersistentVolumeSource persistentVolumeSource = 2;
2505
2506 // AccessModes contains all ways the volume can be mounted.
2507 // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes
2508 // +optional
2509 repeated string accessModes = 3;
2510
2511 // ClaimRef is part of a bi-directional binding between PersistentVolume and PersistentVolumeClaim.
2512 // Expected to be non-nil when bound.
2513 // claim.VolumeName is the authoritative bind between PV and PVC.
2514 // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#binding
2515 // +optional
2516 optional ObjectReference claimRef = 4;
2517
2518 // What happens to a persistent volume when released from its claim.
2519 // Valid options are Retain (default for manually created PersistentVolumes), Delete (default
2520 // for dynamically provisioned PersistentVolumes), and Recycle (deprecated).
2521 // Recycle must be supported by the volume plugin underlying this PersistentVolume.
2522 // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#reclaiming
2523 // +optional
2524 optional string persistentVolumeReclaimPolicy = 5;
2525
2526 // Name of StorageClass to which this persistent volume belongs. Empty value
2527 // means that this volume does not belong to any StorageClass.
2528 // +optional
2529 optional string storageClassName = 6;
2530
2531 // A list of mount options, e.g. ["ro", "soft"]. Not validated - mount will
2532 // simply fail if one is invalid.
2533 // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes/#mount-options
2534 // +optional
2535 repeated string mountOptions = 7;
2536
2537 // volumeMode defines if a volume is intended to be used with a formatted filesystem
2538 // or to remain in raw block state. Value of Filesystem is implied when not included in spec.
2539 // This is a beta feature.
2540 // +optional
2541 optional string volumeMode = 8;
2542
2543 // NodeAffinity defines constraints that limit what nodes this volume can be accessed from.
2544 // This field influences the scheduling of pods that use this volume.
2545 // +optional
2546 optional VolumeNodeAffinity nodeAffinity = 9;
2547}
2548
2549// PersistentVolumeStatus is the current status of a persistent volume.
2550message PersistentVolumeStatus {
2551 // Phase indicates if a volume is available, bound to a claim, or released by a claim.
2552 // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#phase
2553 // +optional
2554 optional string phase = 1;
2555
2556 // A human-readable message indicating details about why the volume is in this state.
2557 // +optional
2558 optional string message = 2;
2559
2560 // Reason is a brief CamelCase string that describes any failure and is meant
2561 // for machine parsing and tidy display in the CLI.
2562 // +optional
2563 optional string reason = 3;
2564}
2565
2566// Represents a Photon Controller persistent disk resource.
2567message PhotonPersistentDiskVolumeSource {
2568 // ID that identifies Photon Controller persistent disk
2569 optional string pdID = 1;
2570
2571 // Filesystem type to mount.
2572 // Must be a filesystem type supported by the host operating system.
2573 // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
2574 optional string fsType = 2;
2575}
2576
2577// Pod is a collection of containers that can run on a host. This resource is created
2578// by clients and scheduled onto hosts.
2579message Pod {
2580 // Standard object's metadata.
2581 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata
2582 // +optional
2583 optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
2584
2585 // Specification of the desired behavior of the pod.
2586 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status
2587 // +optional
2588 optional PodSpec spec = 2;
2589
2590 // Most recently observed status of the pod.
2591 // This data may not be up to date.
2592 // Populated by the system.
2593 // Read-only.
2594 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status
2595 // +optional
2596 optional PodStatus status = 3;
2597}
2598
2599// Pod affinity is a group of inter pod affinity scheduling rules.
2600message PodAffinity {
2601 // If the affinity requirements specified by this field are not met at
2602 // scheduling time, the pod will not be scheduled onto the node.
2603 // If the affinity requirements specified by this field cease to be met
2604 // at some point during pod execution (e.g. due to a pod label update), the
2605 // system may or may not try to eventually evict the pod from its node.
2606 // When there are multiple elements, the lists of nodes corresponding to each
2607 // podAffinityTerm are intersected, i.e. all terms must be satisfied.
2608 // +optional
2609 repeated PodAffinityTerm requiredDuringSchedulingIgnoredDuringExecution = 1;
2610
2611 // The scheduler will prefer to schedule pods to nodes that satisfy
2612 // the affinity expressions specified by this field, but it may choose
2613 // a node that violates one or more of the expressions. The node that is
2614 // most preferred is the one with the greatest sum of weights, i.e.
2615 // for each node that meets all of the scheduling requirements (resource
2616 // request, requiredDuringScheduling affinity expressions, etc.),
2617 // compute a sum by iterating through the elements of this field and adding
2618 // "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the
2619 // node(s) with the highest sum are the most preferred.
2620 // +optional
2621 repeated WeightedPodAffinityTerm preferredDuringSchedulingIgnoredDuringExecution = 2;
2622}
2623
2624// Defines a set of pods (namely those matching the labelSelector
2625// relative to the given namespace(s)) that this pod should be
2626// co-located (affinity) or not co-located (anti-affinity) with,
2627// where co-located is defined as running on a node whose value of
2628// the label with key <topologyKey> matches that of any node on which
2629// a pod of the set of pods is running
2630message PodAffinityTerm {
2631 // A label query over a set of resources, in this case pods.
2632 // +optional
2633 optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector labelSelector = 1;
2634
2635 // namespaces specifies which namespaces the labelSelector applies to (matches against);
2636 // null or empty list means "this pod's namespace"
2637 // +optional
2638 repeated string namespaces = 2;
2639
2640 // This pod should be co-located (affinity) or not co-located (anti-affinity) with the pods matching
2641 // the labelSelector in the specified namespaces, where co-located is defined as running on a node
2642 // whose value of the label with key topologyKey matches that of any node on which any of the
2643 // selected pods is running.
2644 // Empty topologyKey is not allowed.
2645 optional string topologyKey = 3;
2646}
2647
2648// Pod anti affinity is a group of inter pod anti affinity scheduling rules.
2649message PodAntiAffinity {
2650 // If the anti-affinity requirements specified by this field are not met at
2651 // scheduling time, the pod will not be scheduled onto the node.
2652 // If the anti-affinity requirements specified by this field cease to be met
2653 // at some point during pod execution (e.g. due to a pod label update), the
2654 // system may or may not try to eventually evict the pod from its node.
2655 // When there are multiple elements, the lists of nodes corresponding to each
2656 // podAffinityTerm are intersected, i.e. all terms must be satisfied.
2657 // +optional
2658 repeated PodAffinityTerm requiredDuringSchedulingIgnoredDuringExecution = 1;
2659
2660 // The scheduler will prefer to schedule pods to nodes that satisfy
2661 // the anti-affinity expressions specified by this field, but it may choose
2662 // a node that violates one or more of the expressions. The node that is
2663 // most preferred is the one with the greatest sum of weights, i.e.
2664 // for each node that meets all of the scheduling requirements (resource
2665 // request, requiredDuringScheduling anti-affinity expressions, etc.),
2666 // compute a sum by iterating through the elements of this field and adding
2667 // "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the
2668 // node(s) with the highest sum are the most preferred.
2669 // +optional
2670 repeated WeightedPodAffinityTerm preferredDuringSchedulingIgnoredDuringExecution = 2;
2671}
2672
2673// PodAttachOptions is the query options to a Pod's remote attach call.
2674// ---
2675// TODO: merge w/ PodExecOptions below for stdin, stdout, etc
2676// and also when we cut V2, we should export a "StreamOptions" or somesuch that contains Stdin, Stdout, Stder and TTY
2677message PodAttachOptions {
2678 // Stdin if true, redirects the standard input stream of the pod for this call.
2679 // Defaults to false.
2680 // +optional
2681 optional bool stdin = 1;
2682
2683 // Stdout if true indicates that stdout is to be redirected for the attach call.
2684 // Defaults to true.
2685 // +optional
2686 optional bool stdout = 2;
2687
2688 // Stderr if true indicates that stderr is to be redirected for the attach call.
2689 // Defaults to true.
2690 // +optional
2691 optional bool stderr = 3;
2692
2693 // TTY if true indicates that a tty will be allocated for the attach call.
2694 // This is passed through the container runtime so the tty
2695 // is allocated on the worker node by the container runtime.
2696 // Defaults to false.
2697 // +optional
2698 optional bool tty = 4;
2699
2700 // The container in which to execute the command.
2701 // Defaults to only container if there is only one container in the pod.
2702 // +optional
2703 optional string container = 5;
2704}
2705
2706// PodCondition contains details for the current condition of this pod.
2707message PodCondition {
2708 // Type is the type of the condition.
2709 // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-conditions
2710 optional string type = 1;
2711
2712 // Status is the status of the condition.
2713 // Can be True, False, Unknown.
2714 // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-conditions
2715 optional string status = 2;
2716
2717 // Last time we probed the condition.
2718 // +optional
2719 optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastProbeTime = 3;
2720
2721 // Last time the condition transitioned from one status to another.
2722 // +optional
2723 optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastTransitionTime = 4;
2724
2725 // Unique, one-word, CamelCase reason for the condition's last transition.
2726 // +optional
2727 optional string reason = 5;
2728
2729 // Human-readable message indicating details about last transition.
2730 // +optional
2731 optional string message = 6;
2732}
2733
2734// PodDNSConfig defines the DNS parameters of a pod in addition to
2735// those generated from DNSPolicy.
2736message PodDNSConfig {
2737 // A list of DNS name server IP addresses.
2738 // This will be appended to the base nameservers generated from DNSPolicy.
2739 // Duplicated nameservers will be removed.
2740 // +optional
2741 repeated string nameservers = 1;
2742
2743 // A list of DNS search domains for host-name lookup.
2744 // This will be appended to the base search paths generated from DNSPolicy.
2745 // Duplicated search paths will be removed.
2746 // +optional
2747 repeated string searches = 2;
2748
2749 // A list of DNS resolver options.
2750 // This will be merged with the base options generated from DNSPolicy.
2751 // Duplicated entries will be removed. Resolution options given in Options
2752 // will override those that appear in the base DNSPolicy.
2753 // +optional
2754 repeated PodDNSConfigOption options = 3;
2755}
2756
2757// PodDNSConfigOption defines DNS resolver options of a pod.
2758message PodDNSConfigOption {
2759 // Required.
2760 optional string name = 1;
2761
2762 // +optional
2763 optional string value = 2;
2764}
2765
2766// PodExecOptions is the query options to a Pod's remote exec call.
2767// ---
2768// TODO: This is largely identical to PodAttachOptions above, make sure they stay in sync and see about merging
2769// and also when we cut V2, we should export a "StreamOptions" or somesuch that contains Stdin, Stdout, Stder and TTY
2770message PodExecOptions {
2771 // Redirect the standard input stream of the pod for this call.
2772 // Defaults to false.
2773 // +optional
2774 optional bool stdin = 1;
2775
2776 // Redirect the standard output stream of the pod for this call.
2777 // Defaults to true.
2778 // +optional
2779 optional bool stdout = 2;
2780
2781 // Redirect the standard error stream of the pod for this call.
2782 // Defaults to true.
2783 // +optional
2784 optional bool stderr = 3;
2785
2786 // TTY if true indicates that a tty will be allocated for the exec call.
2787 // Defaults to false.
2788 // +optional
2789 optional bool tty = 4;
2790
2791 // Container in which to execute the command.
2792 // Defaults to only container if there is only one container in the pod.
2793 // +optional
2794 optional string container = 5;
2795
2796 // Command is the remote command to execute. argv array. Not executed within a shell.
2797 repeated string command = 6;
2798}
2799
2800// PodList is a list of Pods.
2801message PodList {
2802 // Standard list metadata.
2803 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds
2804 // +optional
2805 optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1;
2806
2807 // List of pods.
2808 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md
2809 repeated Pod items = 2;
2810}
2811
2812// PodLogOptions is the query options for a Pod's logs REST call.
2813message PodLogOptions {
2814 // The container for which to stream logs. Defaults to only container if there is one container in the pod.
2815 // +optional
2816 optional string container = 1;
2817
2818 // Follow the log stream of the pod. Defaults to false.
2819 // +optional
2820 optional bool follow = 2;
2821
2822 // Return previous terminated container logs. Defaults to false.
2823 // +optional
2824 optional bool previous = 3;
2825
2826 // A relative time in seconds before the current time from which to show logs. If this value
2827 // precedes the time a pod was started, only logs since the pod start will be returned.
2828 // If this value is in the future, no logs will be returned.
2829 // Only one of sinceSeconds or sinceTime may be specified.
2830 // +optional
2831 optional int64 sinceSeconds = 4;
2832
2833 // An RFC3339 timestamp from which to show logs. If this value
2834 // precedes the time a pod was started, only logs since the pod start will be returned.
2835 // If this value is in the future, no logs will be returned.
2836 // Only one of sinceSeconds or sinceTime may be specified.
2837 // +optional
2838 optional k8s.io.apimachinery.pkg.apis.meta.v1.Time sinceTime = 5;
2839
2840 // If true, add an RFC3339 or RFC3339Nano timestamp at the beginning of every line
2841 // of log output. Defaults to false.
2842 // +optional
2843 optional bool timestamps = 6;
2844
2845 // If set, the number of lines from the end of the logs to show. If not specified,
2846 // logs are shown from the creation of the container or sinceSeconds or sinceTime
2847 // +optional
2848 optional int64 tailLines = 7;
2849
2850 // If set, the number of bytes to read from the server before terminating the
2851 // log output. This may not display a complete final line of logging, and may return
2852 // slightly more or slightly less than the specified limit.
2853 // +optional
2854 optional int64 limitBytes = 8;
2855}
2856
2857// PodPortForwardOptions is the query options to a Pod's port forward call
2858// when using WebSockets.
2859// The `port` query parameter must specify the port or
2860// ports (comma separated) to forward over.
2861// Port forwarding over SPDY does not use these options. It requires the port
2862// to be passed in the `port` header as part of request.
2863message PodPortForwardOptions {
2864 // List of ports to forward
2865 // Required when using WebSockets
2866 // +optional
2867 repeated int32 ports = 1;
2868}
2869
2870// PodProxyOptions is the query options to a Pod's proxy call.
2871message PodProxyOptions {
2872 // Path is the URL path to use for the current proxy request to pod.
2873 // +optional
2874 optional string path = 1;
2875}
2876
2877// PodReadinessGate contains the reference to a pod condition
2878message PodReadinessGate {
2879 // ConditionType refers to a condition in the pod's condition list with matching type.
2880 optional string conditionType = 1;
2881}
2882
2883// PodSecurityContext holds pod-level security attributes and common container settings.
2884// Some fields are also present in container.securityContext. Field values of
2885// container.securityContext take precedence over field values of PodSecurityContext.
2886message PodSecurityContext {
2887 // The SELinux context to be applied to all containers.
2888 // If unspecified, the container runtime will allocate a random SELinux context for each
2889 // container. May also be set in SecurityContext. If set in
2890 // both SecurityContext and PodSecurityContext, the value specified in SecurityContext
2891 // takes precedence for that container.
2892 // +optional
2893 optional SELinuxOptions seLinuxOptions = 1;
2894
2895 // The UID to run the entrypoint of the container process.
2896 // Defaults to user specified in image metadata if unspecified.
2897 // May also be set in SecurityContext. If set in both SecurityContext and
2898 // PodSecurityContext, the value specified in SecurityContext takes precedence
2899 // for that container.
2900 // +optional
2901 optional int64 runAsUser = 2;
2902
2903 // The GID to run the entrypoint of the container process.
2904 // Uses runtime default if unset.
2905 // May also be set in SecurityContext. If set in both SecurityContext and
2906 // PodSecurityContext, the value specified in SecurityContext takes precedence
2907 // for that container.
2908 // +optional
2909 optional int64 runAsGroup = 6;
2910
2911 // Indicates that the container must run as a non-root user.
2912 // If true, the Kubelet will validate the image at runtime to ensure that it
2913 // does not run as UID 0 (root) and fail to start the container if it does.
2914 // If unset or false, no such validation will be performed.
2915 // May also be set in SecurityContext. If set in both SecurityContext and
2916 // PodSecurityContext, the value specified in SecurityContext takes precedence.
2917 // +optional
2918 optional bool runAsNonRoot = 3;
2919
2920 // A list of groups applied to the first process run in each container, in addition
2921 // to the container's primary GID. If unspecified, no groups will be added to
2922 // any container.
2923 // +optional
2924 repeated int64 supplementalGroups = 4;
2925
2926 // A special supplemental group that applies to all containers in a pod.
2927 // Some volume types allow the Kubelet to change the ownership of that volume
2928 // to be owned by the pod:
2929 //
2930 // 1. The owning GID will be the FSGroup
2931 // 2. The setgid bit is set (new files created in the volume will be owned by FSGroup)
2932 // 3. The permission bits are OR'd with rw-rw----
2933 //
2934 // If unset, the Kubelet will not modify the ownership and permissions of any volume.
2935 // +optional
2936 optional int64 fsGroup = 5;
2937
2938 // Sysctls hold a list of namespaced sysctls used for the pod. Pods with unsupported
2939 // sysctls (by the container runtime) might fail to launch.
2940 // +optional
2941 repeated Sysctl sysctls = 7;
2942}
2943
2944// Describes the class of pods that should avoid this node.
2945// Exactly one field should be set.
2946message PodSignature {
2947 // Reference to controller whose pods should avoid this node.
2948 // +optional
2949 optional k8s.io.apimachinery.pkg.apis.meta.v1.OwnerReference podController = 1;
2950}
2951
2952// PodSpec is a description of a pod.
2953message PodSpec {
2954 // List of volumes that can be mounted by containers belonging to the pod.
2955 // More info: https://kubernetes.io/docs/concepts/storage/volumes
2956 // +optional
2957 // +patchMergeKey=name
2958 // +patchStrategy=merge,retainKeys
2959 repeated Volume volumes = 1;
2960
2961 // List of initialization containers belonging to the pod.
2962 // Init containers are executed in order prior to containers being started. If any
2963 // init container fails, the pod is considered to have failed and is handled according
2964 // to its restartPolicy. The name for an init container or normal container must be
2965 // unique among all containers.
2966 // Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes.
2967 // The resourceRequirements of an init container are taken into account during scheduling
2968 // by finding the highest request/limit for each resource type, and then using the max of
2969 // of that value or the sum of the normal containers. Limits are applied to init containers
2970 // in a similar fashion.
2971 // Init containers cannot currently be added or removed.
2972 // Cannot be updated.
2973 // More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/
2974 // +patchMergeKey=name
2975 // +patchStrategy=merge
2976 repeated Container initContainers = 20;
2977
2978 // List of containers belonging to the pod.
2979 // Containers cannot currently be added or removed.
2980 // There must be at least one container in a Pod.
2981 // Cannot be updated.
2982 // +patchMergeKey=name
2983 // +patchStrategy=merge
2984 repeated Container containers = 2;
2985
2986 // Restart policy for all containers within the pod.
2987 // One of Always, OnFailure, Never.
2988 // Default to Always.
2989 // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy
2990 // +optional
2991 optional string restartPolicy = 3;
2992
2993 // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request.
2994 // Value must be non-negative integer. The value zero indicates delete immediately.
2995 // If this value is nil, the default grace period will be used instead.
2996 // The grace period is the duration in seconds after the processes running in the pod are sent
2997 // a termination signal and the time when the processes are forcibly halted with a kill signal.
2998 // Set this value longer than the expected cleanup time for your process.
2999 // Defaults to 30 seconds.
3000 // +optional
3001 optional int64 terminationGracePeriodSeconds = 4;
3002
3003 // Optional duration in seconds the pod may be active on the node relative to
3004 // StartTime before the system will actively try to mark it failed and kill associated containers.
3005 // Value must be a positive integer.
3006 // +optional
3007 optional int64 activeDeadlineSeconds = 5;
3008
3009 // Set DNS policy for the pod.
3010 // Defaults to "ClusterFirst".
3011 // Valid values are 'ClusterFirstWithHostNet', 'ClusterFirst', 'Default' or 'None'.
3012 // DNS parameters given in DNSConfig will be merged with the policy selected with DNSPolicy.
3013 // To have DNS options set along with hostNetwork, you have to specify DNS policy
3014 // explicitly to 'ClusterFirstWithHostNet'.
3015 // +optional
3016 optional string dnsPolicy = 6;
3017
3018 // NodeSelector is a selector which must be true for the pod to fit on a node.
3019 // Selector which must match a node's labels for the pod to be scheduled on that node.
3020 // More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/
3021 // +optional
3022 map<string, string> nodeSelector = 7;
3023
3024 // ServiceAccountName is the name of the ServiceAccount to use to run this pod.
3025 // More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/
3026 // +optional
3027 optional string serviceAccountName = 8;
3028
3029 // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName.
3030 // Deprecated: Use serviceAccountName instead.
3031 // +k8s:conversion-gen=false
3032 // +optional
3033 optional string serviceAccount = 9;
3034
3035 // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted.
3036 // +optional
3037 optional bool automountServiceAccountToken = 21;
3038
3039 // NodeName is a request to schedule this pod onto a specific node. If it is non-empty,
3040 // the scheduler simply schedules this pod onto that node, assuming that it fits resource
3041 // requirements.
3042 // +optional
3043 optional string nodeName = 10;
3044
3045 // Host networking requested for this pod. Use the host's network namespace.
3046 // If this option is set, the ports that will be used must be specified.
3047 // Default to false.
3048 // +k8s:conversion-gen=false
3049 // +optional
3050 optional bool hostNetwork = 11;
3051
3052 // Use the host's pid namespace.
3053 // Optional: Default to false.
3054 // +k8s:conversion-gen=false
3055 // +optional
3056 optional bool hostPID = 12;
3057
3058 // Use the host's ipc namespace.
3059 // Optional: Default to false.
3060 // +k8s:conversion-gen=false
3061 // +optional
3062 optional bool hostIPC = 13;
3063
3064 // Share a single process namespace between all of the containers in a pod.
3065 // When this is set containers will be able to view and signal processes from other containers
3066 // in the same pod, and the first process in each container will not be assigned PID 1.
3067 // HostPID and ShareProcessNamespace cannot both be set.
3068 // Optional: Default to false.
3069 // This field is beta-level and may be disabled with the PodShareProcessNamespace feature.
3070 // +k8s:conversion-gen=false
3071 // +optional
3072 optional bool shareProcessNamespace = 27;
3073
3074 // SecurityContext holds pod-level security attributes and common container settings.
3075 // Optional: Defaults to empty. See type description for default values of each field.
3076 // +optional
3077 optional PodSecurityContext securityContext = 14;
3078
3079 // ImagePullSecrets is an optional list of references to secrets in the same namespace to use for pulling any of the images used by this PodSpec.
3080 // If specified, these secrets will be passed to individual puller implementations for them to use. For example,
3081 // in the case of docker, only DockerConfig type secrets are honored.
3082 // More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod
3083 // +optional
3084 // +patchMergeKey=name
3085 // +patchStrategy=merge
3086 repeated LocalObjectReference imagePullSecrets = 15;
3087
3088 // Specifies the hostname of the Pod
3089 // If not specified, the pod's hostname will be set to a system-defined value.
3090 // +optional
3091 optional string hostname = 16;
3092
3093 // If specified, the fully qualified Pod hostname will be "<hostname>.<subdomain>.<pod namespace>.svc.<cluster domain>".
3094 // If not specified, the pod will not have a domainname at all.
3095 // +optional
3096 optional string subdomain = 17;
3097
3098 // If specified, the pod's scheduling constraints
3099 // +optional
3100 optional Affinity affinity = 18;
3101
3102 // If specified, the pod will be dispatched by specified scheduler.
3103 // If not specified, the pod will be dispatched by default scheduler.
3104 // +optional
3105 optional string schedulerName = 19;
3106
3107 // If specified, the pod's tolerations.
3108 // +optional
3109 repeated Toleration tolerations = 22;
3110
3111 // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts
3112 // file if specified. This is only valid for non-hostNetwork pods.
3113 // +optional
3114 // +patchMergeKey=ip
3115 // +patchStrategy=merge
3116 repeated HostAlias hostAliases = 23;
3117
3118 // If specified, indicates the pod's priority. "system-node-critical" and
3119 // "system-cluster-critical" are two special keywords which indicate the
3120 // highest priorities with the former being the highest priority. Any other
3121 // name must be defined by creating a PriorityClass object with that name.
3122 // If not specified, the pod priority will be default or zero if there is no
3123 // default.
3124 // +optional
3125 optional string priorityClassName = 24;
3126
3127 // The priority value. Various system components use this field to find the
3128 // priority of the pod. When Priority Admission Controller is enabled, it
3129 // prevents users from setting this field. The admission controller populates
3130 // this field from PriorityClassName.
3131 // The higher the value, the higher the priority.
3132 // +optional
3133 optional int32 priority = 25;
3134
3135 // Specifies the DNS parameters of a pod.
3136 // Parameters specified here will be merged to the generated DNS
3137 // configuration based on DNSPolicy.
3138 // +optional
3139 optional PodDNSConfig dnsConfig = 26;
3140
3141 // If specified, all readiness gates will be evaluated for pod readiness.
3142 // A pod is ready when all its containers are ready AND
3143 // all conditions specified in the readiness gates have status equal to "True"
3144 // More info: https://github.com/kubernetes/community/blob/master/keps/sig-network/0007-pod-ready%2B%2B.md
3145 // +optional
3146 repeated PodReadinessGate readinessGates = 28;
3147
3148 // RuntimeClassName refers to a RuntimeClass object in the node.k8s.io group, which should be used
3149 // to run this pod. If no RuntimeClass resource matches the named class, the pod will not be run.
3150 // If unset or empty, the "legacy" RuntimeClass will be used, which is an implicit class with an
3151 // empty definition that uses the default runtime handler.
3152 // More info: https://github.com/kubernetes/community/blob/master/keps/sig-node/0014-runtime-class.md
3153 // This is an alpha feature and may change in the future.
3154 // +optional
3155 optional string runtimeClassName = 29;
3156
3157 // EnableServiceLinks indicates whether information about services should be injected into pod's
3158 // environment variables, matching the syntax of Docker links.
William Kurkiandaa6bb22019-03-07 12:26:28 -05003159 // Optional: Defaults to true.
sslobodrd046be82019-01-16 10:02:22 -05003160 // +optional
3161 optional bool enableServiceLinks = 30;
3162}
3163
3164// PodStatus represents information about the status of a pod. Status may trail the actual
3165// state of a system, especially if the node that hosts the pod cannot contact the control
3166// plane.
3167message PodStatus {
3168 // The phase of a Pod is a simple, high-level summary of where the Pod is in its lifecycle.
3169 // The conditions array, the reason and message fields, and the individual container status
3170 // arrays contain more detail about the pod's status.
3171 // There are five possible phase values:
3172 //
3173 // Pending: The pod has been accepted by the Kubernetes system, but one or more of the
3174 // container images has not been created. This includes time before being scheduled as
3175 // well as time spent downloading images over the network, which could take a while.
3176 // Running: The pod has been bound to a node, and all of the containers have been created.
3177 // At least one container is still running, or is in the process of starting or restarting.
3178 // Succeeded: All containers in the pod have terminated in success, and will not be restarted.
3179 // Failed: All containers in the pod have terminated, and at least one container has
3180 // terminated in failure. The container either exited with non-zero status or was terminated
3181 // by the system.
3182 // Unknown: For some reason the state of the pod could not be obtained, typically due to an
3183 // error in communicating with the host of the pod.
3184 //
3185 // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-phase
3186 // +optional
3187 optional string phase = 1;
3188
3189 // Current service state of pod.
3190 // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-conditions
3191 // +optional
3192 // +patchMergeKey=type
3193 // +patchStrategy=merge
3194 repeated PodCondition conditions = 2;
3195
3196 // A human readable message indicating details about why the pod is in this condition.
3197 // +optional
3198 optional string message = 3;
3199
3200 // A brief CamelCase message indicating details about why the pod is in this state.
3201 // e.g. 'Evicted'
3202 // +optional
3203 optional string reason = 4;
3204
3205 // nominatedNodeName is set only when this pod preempts other pods on the node, but it cannot be
3206 // scheduled right away as preemption victims receive their graceful termination periods.
3207 // This field does not guarantee that the pod will be scheduled on this node. Scheduler may decide
3208 // to place the pod elsewhere if other nodes become available sooner. Scheduler may also decide to
3209 // give the resources on this node to a higher priority pod that is created after preemption.
3210 // As a result, this field may be different than PodSpec.nodeName when the pod is
3211 // scheduled.
3212 // +optional
3213 optional string nominatedNodeName = 11;
3214
3215 // IP address of the host to which the pod is assigned. Empty if not yet scheduled.
3216 // +optional
3217 optional string hostIP = 5;
3218
3219 // IP address allocated to the pod. Routable at least within the cluster.
3220 // Empty if not yet allocated.
3221 // +optional
3222 optional string podIP = 6;
3223
3224 // RFC 3339 date and time at which the object was acknowledged by the Kubelet.
3225 // This is before the Kubelet pulled the container image(s) for the pod.
3226 // +optional
3227 optional k8s.io.apimachinery.pkg.apis.meta.v1.Time startTime = 7;
3228
3229 // The list has one entry per init container in the manifest. The most recent successful
3230 // init container will have ready = true, the most recently started container will have
3231 // startTime set.
3232 // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-and-container-status
3233 repeated ContainerStatus initContainerStatuses = 10;
3234
3235 // The list has one entry per container in the manifest. Each entry is currently the output
3236 // of `docker inspect`.
3237 // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-and-container-status
3238 // +optional
3239 repeated ContainerStatus containerStatuses = 8;
3240
3241 // The Quality of Service (QOS) classification assigned to the pod based on resource requirements
3242 // See PodQOSClass type for available QOS classes
3243 // More info: https://git.k8s.io/community/contributors/design-proposals/node/resource-qos.md
3244 // +optional
3245 optional string qosClass = 9;
3246}
3247
3248// PodStatusResult is a wrapper for PodStatus returned by kubelet that can be encode/decoded
3249message PodStatusResult {
3250 // Standard object's metadata.
3251 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata
3252 // +optional
3253 optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
3254
3255 // Most recently observed status of the pod.
3256 // This data may not be up to date.
3257 // Populated by the system.
3258 // Read-only.
3259 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status
3260 // +optional
3261 optional PodStatus status = 2;
3262}
3263
3264// PodTemplate describes a template for creating copies of a predefined pod.
3265message PodTemplate {
3266 // Standard object's metadata.
3267 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata
3268 // +optional
3269 optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
3270
3271 // Template defines the pods that will be created from this pod template.
3272 // https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status
3273 // +optional
3274 optional PodTemplateSpec template = 2;
3275}
3276
3277// PodTemplateList is a list of PodTemplates.
3278message PodTemplateList {
3279 // Standard list metadata.
3280 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds
3281 // +optional
3282 optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1;
3283
3284 // List of pod templates
3285 repeated PodTemplate items = 2;
3286}
3287
3288// PodTemplateSpec describes the data a pod should have when created from a template
3289message PodTemplateSpec {
3290 // Standard object's metadata.
3291 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata
3292 // +optional
3293 optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
3294
3295 // Specification of the desired behavior of the pod.
3296 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status
3297 // +optional
3298 optional PodSpec spec = 2;
3299}
3300
3301// PortworxVolumeSource represents a Portworx volume resource.
3302message PortworxVolumeSource {
3303 // VolumeID uniquely identifies a Portworx volume
3304 optional string volumeID = 1;
3305
3306 // FSType represents the filesystem type to mount
3307 // Must be a filesystem type supported by the host operating system.
3308 // Ex. "ext4", "xfs". Implicitly inferred to be "ext4" if unspecified.
3309 optional string fsType = 2;
3310
3311 // Defaults to false (read/write). ReadOnly here will force
3312 // the ReadOnly setting in VolumeMounts.
3313 // +optional
3314 optional bool readOnly = 3;
3315}
3316
3317// Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out.
3318// +k8s:openapi-gen=false
3319message Preconditions {
3320 // Specifies the target UID.
3321 // +optional
3322 optional string uid = 1;
3323}
3324
3325// Describes a class of pods that should avoid this node.
3326message PreferAvoidPodsEntry {
3327 // The class of pods.
3328 optional PodSignature podSignature = 1;
3329
3330 // Time at which this entry was added to the list.
3331 // +optional
3332 optional k8s.io.apimachinery.pkg.apis.meta.v1.Time evictionTime = 2;
3333
3334 // (brief) reason why this entry was added to the list.
3335 // +optional
3336 optional string reason = 3;
3337
3338 // Human readable message indicating why this entry was added to the list.
3339 // +optional
3340 optional string message = 4;
3341}
3342
3343// An empty preferred scheduling term matches all objects with implicit weight 0
3344// (i.e. it's a no-op). A null preferred scheduling term matches no objects (i.e. is also a no-op).
3345message PreferredSchedulingTerm {
3346 // Weight associated with matching the corresponding nodeSelectorTerm, in the range 1-100.
3347 optional int32 weight = 1;
3348
3349 // A node selector term, associated with the corresponding weight.
3350 optional NodeSelectorTerm preference = 2;
3351}
3352
3353// Probe describes a health check to be performed against a container to determine whether it is
3354// alive or ready to receive traffic.
3355message Probe {
3356 // The action taken to determine the health of a container
3357 optional Handler handler = 1;
3358
3359 // Number of seconds after the container has started before liveness probes are initiated.
3360 // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes
3361 // +optional
3362 optional int32 initialDelaySeconds = 2;
3363
3364 // Number of seconds after which the probe times out.
3365 // Defaults to 1 second. Minimum value is 1.
3366 // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes
3367 // +optional
3368 optional int32 timeoutSeconds = 3;
3369
3370 // How often (in seconds) to perform the probe.
3371 // Default to 10 seconds. Minimum value is 1.
3372 // +optional
3373 optional int32 periodSeconds = 4;
3374
3375 // Minimum consecutive successes for the probe to be considered successful after having failed.
3376 // Defaults to 1. Must be 1 for liveness. Minimum value is 1.
3377 // +optional
3378 optional int32 successThreshold = 5;
3379
3380 // Minimum consecutive failures for the probe to be considered failed after having succeeded.
3381 // Defaults to 3. Minimum value is 1.
3382 // +optional
3383 optional int32 failureThreshold = 6;
3384}
3385
3386// Represents a projected volume source
3387message ProjectedVolumeSource {
3388 // list of volume projections
3389 repeated VolumeProjection sources = 1;
3390
3391 // Mode bits to use on created files by default. Must be a value between
3392 // 0 and 0777.
3393 // Directories within the path are not affected by this setting.
3394 // This might be in conflict with other options that affect the file
3395 // mode, like fsGroup, and the result can be other mode bits set.
3396 // +optional
3397 optional int32 defaultMode = 2;
3398}
3399
3400// Represents a Quobyte mount that lasts the lifetime of a pod.
3401// Quobyte volumes do not support ownership management or SELinux relabeling.
3402message QuobyteVolumeSource {
3403 // Registry represents a single or multiple Quobyte Registry services
3404 // specified as a string as host:port pair (multiple entries are separated with commas)
3405 // which acts as the central registry for volumes
3406 optional string registry = 1;
3407
3408 // Volume is a string that references an already created Quobyte volume by name.
3409 optional string volume = 2;
3410
3411 // ReadOnly here will force the Quobyte volume to be mounted with read-only permissions.
3412 // Defaults to false.
3413 // +optional
3414 optional bool readOnly = 3;
3415
3416 // User to map volume access to
3417 // Defaults to serivceaccount user
3418 // +optional
3419 optional string user = 4;
3420
3421 // Group to map volume access to
3422 // Default is no group
3423 // +optional
3424 optional string group = 5;
3425}
3426
3427// Represents a Rados Block Device mount that lasts the lifetime of a pod.
3428// RBD volumes support ownership management and SELinux relabeling.
3429message RBDPersistentVolumeSource {
3430 // A collection of Ceph monitors.
3431 // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
3432 repeated string monitors = 1;
3433
3434 // The rados image name.
3435 // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
3436 optional string image = 2;
3437
3438 // Filesystem type of the volume that you want to mount.
3439 // Tip: Ensure that the filesystem type is supported by the host operating system.
3440 // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
3441 // More info: https://kubernetes.io/docs/concepts/storage/volumes#rbd
3442 // TODO: how do we prevent errors in the filesystem from compromising the machine
3443 // +optional
3444 optional string fsType = 3;
3445
3446 // The rados pool name.
3447 // Default is rbd.
3448 // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
3449 // +optional
3450 optional string pool = 4;
3451
3452 // The rados user name.
3453 // Default is admin.
3454 // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
3455 // +optional
3456 optional string user = 5;
3457
3458 // Keyring is the path to key ring for RBDUser.
3459 // Default is /etc/ceph/keyring.
3460 // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
3461 // +optional
3462 optional string keyring = 6;
3463
3464 // SecretRef is name of the authentication secret for RBDUser. If provided
3465 // overrides keyring.
3466 // Default is nil.
3467 // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
3468 // +optional
3469 optional SecretReference secretRef = 7;
3470
3471 // ReadOnly here will force the ReadOnly setting in VolumeMounts.
3472 // Defaults to false.
3473 // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
3474 // +optional
3475 optional bool readOnly = 8;
3476}
3477
3478// Represents a Rados Block Device mount that lasts the lifetime of a pod.
3479// RBD volumes support ownership management and SELinux relabeling.
3480message RBDVolumeSource {
3481 // A collection of Ceph monitors.
3482 // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
3483 repeated string monitors = 1;
3484
3485 // The rados image name.
3486 // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
3487 optional string image = 2;
3488
3489 // Filesystem type of the volume that you want to mount.
3490 // Tip: Ensure that the filesystem type is supported by the host operating system.
3491 // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
3492 // More info: https://kubernetes.io/docs/concepts/storage/volumes#rbd
3493 // TODO: how do we prevent errors in the filesystem from compromising the machine
3494 // +optional
3495 optional string fsType = 3;
3496
3497 // The rados pool name.
3498 // Default is rbd.
3499 // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
3500 // +optional
3501 optional string pool = 4;
3502
3503 // The rados user name.
3504 // Default is admin.
3505 // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
3506 // +optional
3507 optional string user = 5;
3508
3509 // Keyring is the path to key ring for RBDUser.
3510 // Default is /etc/ceph/keyring.
3511 // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
3512 // +optional
3513 optional string keyring = 6;
3514
3515 // SecretRef is name of the authentication secret for RBDUser. If provided
3516 // overrides keyring.
3517 // Default is nil.
3518 // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
3519 // +optional
3520 optional LocalObjectReference secretRef = 7;
3521
3522 // ReadOnly here will force the ReadOnly setting in VolumeMounts.
3523 // Defaults to false.
3524 // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
3525 // +optional
3526 optional bool readOnly = 8;
3527}
3528
3529// RangeAllocation is not a public type.
3530message RangeAllocation {
3531 // Standard object's metadata.
3532 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata
3533 // +optional
3534 optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
3535
3536 // Range is string that identifies the range represented by 'data'.
3537 optional string range = 2;
3538
3539 // Data is a bit array containing all allocated addresses in the previous segment.
3540 optional bytes data = 3;
3541}
3542
3543// ReplicationController represents the configuration of a replication controller.
3544message ReplicationController {
3545 // If the Labels of a ReplicationController are empty, they are defaulted to
3546 // be the same as the Pod(s) that the replication controller manages.
3547 // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata
3548 // +optional
3549 optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
3550
3551 // Spec defines the specification of the desired behavior of the replication controller.
3552 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status
3553 // +optional
3554 optional ReplicationControllerSpec spec = 2;
3555
3556 // Status is the most recently observed status of the replication controller.
3557 // This data may be out of date by some window of time.
3558 // Populated by the system.
3559 // Read-only.
3560 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status
3561 // +optional
3562 optional ReplicationControllerStatus status = 3;
3563}
3564
3565// ReplicationControllerCondition describes the state of a replication controller at a certain point.
3566message ReplicationControllerCondition {
3567 // Type of replication controller condition.
3568 optional string type = 1;
3569
3570 // Status of the condition, one of True, False, Unknown.
3571 optional string status = 2;
3572
3573 // The last time the condition transitioned from one status to another.
3574 // +optional
3575 optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastTransitionTime = 3;
3576
3577 // The reason for the condition's last transition.
3578 // +optional
3579 optional string reason = 4;
3580
3581 // A human readable message indicating details about the transition.
3582 // +optional
3583 optional string message = 5;
3584}
3585
3586// ReplicationControllerList is a collection of replication controllers.
3587message ReplicationControllerList {
3588 // Standard list metadata.
3589 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds
3590 // +optional
3591 optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1;
3592
3593 // List of replication controllers.
3594 // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller
3595 repeated ReplicationController items = 2;
3596}
3597
3598// ReplicationControllerSpec is the specification of a replication controller.
3599message ReplicationControllerSpec {
3600 // Replicas is the number of desired replicas.
3601 // This is a pointer to distinguish between explicit zero and unspecified.
3602 // Defaults to 1.
3603 // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#what-is-a-replicationcontroller
3604 // +optional
3605 optional int32 replicas = 1;
3606
3607 // Minimum number of seconds for which a newly created pod should be ready
3608 // without any of its container crashing, for it to be considered available.
3609 // Defaults to 0 (pod will be considered available as soon as it is ready)
3610 // +optional
3611 optional int32 minReadySeconds = 4;
3612
3613 // Selector is a label query over pods that should match the Replicas count.
3614 // If Selector is empty, it is defaulted to the labels present on the Pod template.
3615 // Label keys and values that must match in order to be controlled by this replication
3616 // controller, if empty defaulted to labels on Pod template.
3617 // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors
3618 // +optional
3619 map<string, string> selector = 2;
3620
3621 // Template is the object that describes the pod that will be created if
3622 // insufficient replicas are detected. This takes precedence over a TemplateRef.
3623 // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#pod-template
3624 // +optional
3625 optional PodTemplateSpec template = 3;
3626}
3627
3628// ReplicationControllerStatus represents the current status of a replication
3629// controller.
3630message ReplicationControllerStatus {
3631 // Replicas is the most recently oberved number of replicas.
3632 // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#what-is-a-replicationcontroller
3633 optional int32 replicas = 1;
3634
3635 // The number of pods that have labels matching the labels of the pod template of the replication controller.
3636 // +optional
3637 optional int32 fullyLabeledReplicas = 2;
3638
3639 // The number of ready replicas for this replication controller.
3640 // +optional
3641 optional int32 readyReplicas = 4;
3642
3643 // The number of available replicas (ready for at least minReadySeconds) for this replication controller.
3644 // +optional
3645 optional int32 availableReplicas = 5;
3646
3647 // ObservedGeneration reflects the generation of the most recently observed replication controller.
3648 // +optional
3649 optional int64 observedGeneration = 3;
3650
3651 // Represents the latest available observations of a replication controller's current state.
3652 // +optional
3653 // +patchMergeKey=type
3654 // +patchStrategy=merge
3655 repeated ReplicationControllerCondition conditions = 6;
3656}
3657
3658// ResourceFieldSelector represents container resources (cpu, memory) and their output format
3659message ResourceFieldSelector {
3660 // Container name: required for volumes, optional for env vars
3661 // +optional
3662 optional string containerName = 1;
3663
3664 // Required: resource to select
3665 optional string resource = 2;
3666
3667 // Specifies the output format of the exposed resources, defaults to "1"
3668 // +optional
3669 optional k8s.io.apimachinery.pkg.api.resource.Quantity divisor = 3;
3670}
3671
3672// ResourceQuota sets aggregate quota restrictions enforced per namespace
3673message ResourceQuota {
3674 // Standard object's metadata.
3675 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata
3676 // +optional
3677 optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
3678
3679 // Spec defines the desired quota.
3680 // https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status
3681 // +optional
3682 optional ResourceQuotaSpec spec = 2;
3683
3684 // Status defines the actual enforced quota and its current usage.
3685 // https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status
3686 // +optional
3687 optional ResourceQuotaStatus status = 3;
3688}
3689
3690// ResourceQuotaList is a list of ResourceQuota items.
3691message ResourceQuotaList {
3692 // Standard list metadata.
3693 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds
3694 // +optional
3695 optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1;
3696
3697 // Items is a list of ResourceQuota objects.
3698 // More info: https://kubernetes.io/docs/concepts/policy/resource-quotas/
3699 repeated ResourceQuota items = 2;
3700}
3701
3702// ResourceQuotaSpec defines the desired hard limits to enforce for Quota.
3703message ResourceQuotaSpec {
3704 // hard is the set of desired hard limits for each named resource.
3705 // More info: https://kubernetes.io/docs/concepts/policy/resource-quotas/
3706 // +optional
3707 map<string, k8s.io.apimachinery.pkg.api.resource.Quantity> hard = 1;
3708
3709 // A collection of filters that must match each object tracked by a quota.
3710 // If not specified, the quota matches all objects.
3711 // +optional
3712 repeated string scopes = 2;
3713
3714 // scopeSelector is also a collection of filters like scopes that must match each object tracked by a quota
3715 // but expressed using ScopeSelectorOperator in combination with possible values.
3716 // For a resource to match, both scopes AND scopeSelector (if specified in spec), must be matched.
3717 // +optional
3718 optional ScopeSelector scopeSelector = 3;
3719}
3720
3721// ResourceQuotaStatus defines the enforced hard limits and observed use.
3722message ResourceQuotaStatus {
3723 // Hard is the set of enforced hard limits for each named resource.
3724 // More info: https://kubernetes.io/docs/concepts/policy/resource-quotas/
3725 // +optional
3726 map<string, k8s.io.apimachinery.pkg.api.resource.Quantity> hard = 1;
3727
3728 // Used is the current observed total usage of the resource in the namespace.
3729 // +optional
3730 map<string, k8s.io.apimachinery.pkg.api.resource.Quantity> used = 2;
3731}
3732
3733// ResourceRequirements describes the compute resource requirements.
3734message ResourceRequirements {
3735 // Limits describes the maximum amount of compute resources allowed.
3736 // More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/
3737 // +optional
3738 map<string, k8s.io.apimachinery.pkg.api.resource.Quantity> limits = 1;
3739
3740 // Requests describes the minimum amount of compute resources required.
3741 // If Requests is omitted for a container, it defaults to Limits if that is explicitly specified,
3742 // otherwise to an implementation-defined value.
3743 // More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/
3744 // +optional
3745 map<string, k8s.io.apimachinery.pkg.api.resource.Quantity> requests = 2;
3746}
3747
3748// SELinuxOptions are the labels to be applied to the container
3749message SELinuxOptions {
3750 // User is a SELinux user label that applies to the container.
3751 // +optional
3752 optional string user = 1;
3753
3754 // Role is a SELinux role label that applies to the container.
3755 // +optional
3756 optional string role = 2;
3757
3758 // Type is a SELinux type label that applies to the container.
3759 // +optional
3760 optional string type = 3;
3761
3762 // Level is SELinux level label that applies to the container.
3763 // +optional
3764 optional string level = 4;
3765}
3766
3767// ScaleIOPersistentVolumeSource represents a persistent ScaleIO volume
3768message ScaleIOPersistentVolumeSource {
3769 // The host address of the ScaleIO API Gateway.
3770 optional string gateway = 1;
3771
3772 // The name of the storage system as configured in ScaleIO.
3773 optional string system = 2;
3774
3775 // SecretRef references to the secret for ScaleIO user and other
3776 // sensitive information. If this is not provided, Login operation will fail.
3777 optional SecretReference secretRef = 3;
3778
3779 // Flag to enable/disable SSL communication with Gateway, default false
3780 // +optional
3781 optional bool sslEnabled = 4;
3782
3783 // The name of the ScaleIO Protection Domain for the configured storage.
3784 // +optional
3785 optional string protectionDomain = 5;
3786
3787 // The ScaleIO Storage Pool associated with the protection domain.
3788 // +optional
3789 optional string storagePool = 6;
3790
3791 // Indicates whether the storage for a volume should be ThickProvisioned or ThinProvisioned.
3792 // Default is ThinProvisioned.
3793 // +optional
3794 optional string storageMode = 7;
3795
3796 // The name of a volume already created in the ScaleIO system
3797 // that is associated with this volume source.
3798 optional string volumeName = 8;
3799
3800 // Filesystem type to mount.
3801 // Must be a filesystem type supported by the host operating system.
3802 // Ex. "ext4", "xfs", "ntfs".
3803 // Default is "xfs"
3804 // +optional
3805 optional string fsType = 9;
3806
3807 // Defaults to false (read/write). ReadOnly here will force
3808 // the ReadOnly setting in VolumeMounts.
3809 // +optional
3810 optional bool readOnly = 10;
3811}
3812
3813// ScaleIOVolumeSource represents a persistent ScaleIO volume
3814message ScaleIOVolumeSource {
3815 // The host address of the ScaleIO API Gateway.
3816 optional string gateway = 1;
3817
3818 // The name of the storage system as configured in ScaleIO.
3819 optional string system = 2;
3820
3821 // SecretRef references to the secret for ScaleIO user and other
3822 // sensitive information. If this is not provided, Login operation will fail.
3823 optional LocalObjectReference secretRef = 3;
3824
3825 // Flag to enable/disable SSL communication with Gateway, default false
3826 // +optional
3827 optional bool sslEnabled = 4;
3828
3829 // The name of the ScaleIO Protection Domain for the configured storage.
3830 // +optional
3831 optional string protectionDomain = 5;
3832
3833 // The ScaleIO Storage Pool associated with the protection domain.
3834 // +optional
3835 optional string storagePool = 6;
3836
3837 // Indicates whether the storage for a volume should be ThickProvisioned or ThinProvisioned.
3838 // Default is ThinProvisioned.
3839 // +optional
3840 optional string storageMode = 7;
3841
3842 // The name of a volume already created in the ScaleIO system
3843 // that is associated with this volume source.
3844 optional string volumeName = 8;
3845
3846 // Filesystem type to mount.
3847 // Must be a filesystem type supported by the host operating system.
3848 // Ex. "ext4", "xfs", "ntfs".
3849 // Default is "xfs".
3850 // +optional
3851 optional string fsType = 9;
3852
3853 // Defaults to false (read/write). ReadOnly here will force
3854 // the ReadOnly setting in VolumeMounts.
3855 // +optional
3856 optional bool readOnly = 10;
3857}
3858
3859// A scope selector represents the AND of the selectors represented
3860// by the scoped-resource selector requirements.
3861message ScopeSelector {
3862 // A list of scope selector requirements by scope of the resources.
3863 // +optional
3864 repeated ScopedResourceSelectorRequirement matchExpressions = 1;
3865}
3866
3867// A scoped-resource selector requirement is a selector that contains values, a scope name, and an operator
3868// that relates the scope name and values.
3869message ScopedResourceSelectorRequirement {
3870 // The name of the scope that the selector applies to.
3871 optional string scopeName = 1;
3872
3873 // Represents a scope's relationship to a set of values.
3874 // Valid operators are In, NotIn, Exists, DoesNotExist.
3875 optional string operator = 2;
3876
3877 // An array of string values. If the operator is In or NotIn,
3878 // the values array must be non-empty. If the operator is Exists or DoesNotExist,
3879 // the values array must be empty.
3880 // This array is replaced during a strategic merge patch.
3881 // +optional
3882 repeated string values = 3;
3883}
3884
3885// Secret holds secret data of a certain type. The total bytes of the values in
3886// the Data field must be less than MaxSecretSize bytes.
3887message Secret {
3888 // Standard object's metadata.
3889 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata
3890 // +optional
3891 optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
3892
3893 // Data contains the secret data. Each key must consist of alphanumeric
3894 // characters, '-', '_' or '.'. The serialized form of the secret data is a
3895 // base64 encoded string, representing the arbitrary (possibly non-string)
3896 // data value here. Described in https://tools.ietf.org/html/rfc4648#section-4
3897 // +optional
3898 map<string, bytes> data = 2;
3899
3900 // stringData allows specifying non-binary secret data in string form.
3901 // It is provided as a write-only convenience method.
3902 // All keys and values are merged into the data field on write, overwriting any existing values.
3903 // It is never output when reading from the API.
3904 // +k8s:conversion-gen=false
3905 // +optional
3906 map<string, string> stringData = 4;
3907
3908 // Used to facilitate programmatic handling of secret data.
3909 // +optional
3910 optional string type = 3;
3911}
3912
3913// SecretEnvSource selects a Secret to populate the environment
3914// variables with.
3915//
3916// The contents of the target Secret's Data field will represent the
3917// key-value pairs as environment variables.
3918message SecretEnvSource {
3919 // The Secret to select from.
3920 optional LocalObjectReference localObjectReference = 1;
3921
3922 // Specify whether the Secret must be defined
3923 // +optional
3924 optional bool optional = 2;
3925}
3926
3927// SecretKeySelector selects a key of a Secret.
3928message SecretKeySelector {
3929 // The name of the secret in the pod's namespace to select from.
3930 optional LocalObjectReference localObjectReference = 1;
3931
3932 // The key of the secret to select from. Must be a valid secret key.
3933 optional string key = 2;
3934
3935 // Specify whether the Secret or it's key must be defined
3936 // +optional
3937 optional bool optional = 3;
3938}
3939
3940// SecretList is a list of Secret.
3941message SecretList {
3942 // Standard list metadata.
3943 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds
3944 // +optional
3945 optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1;
3946
3947 // Items is a list of secret objects.
3948 // More info: https://kubernetes.io/docs/concepts/configuration/secret
3949 repeated Secret items = 2;
3950}
3951
3952// Adapts a secret into a projected volume.
3953//
3954// The contents of the target Secret's Data field will be presented in a
3955// projected volume as files using the keys in the Data field as the file names.
3956// Note that this is identical to a secret volume source without the default
3957// mode.
3958message SecretProjection {
3959 optional LocalObjectReference localObjectReference = 1;
3960
3961 // If unspecified, each key-value pair in the Data field of the referenced
3962 // Secret will be projected into the volume as a file whose name is the
3963 // key and content is the value. If specified, the listed keys will be
3964 // projected into the specified paths, and unlisted keys will not be
3965 // present. If a key is specified which is not present in the Secret,
3966 // the volume setup will error unless it is marked optional. Paths must be
3967 // relative and may not contain the '..' path or start with '..'.
3968 // +optional
3969 repeated KeyToPath items = 2;
3970
3971 // Specify whether the Secret or its key must be defined
3972 // +optional
3973 optional bool optional = 4;
3974}
3975
3976// SecretReference represents a Secret Reference. It has enough information to retrieve secret
3977// in any namespace
3978message SecretReference {
3979 // Name is unique within a namespace to reference a secret resource.
3980 // +optional
3981 optional string name = 1;
3982
3983 // Namespace defines the space within which the secret name must be unique.
3984 // +optional
3985 optional string namespace = 2;
3986}
3987
3988// Adapts a Secret into a volume.
3989//
3990// The contents of the target Secret's Data field will be presented in a volume
3991// as files using the keys in the Data field as the file names.
3992// Secret volumes support ownership management and SELinux relabeling.
3993message SecretVolumeSource {
3994 // Name of the secret in the pod's namespace to use.
3995 // More info: https://kubernetes.io/docs/concepts/storage/volumes#secret
3996 // +optional
3997 optional string secretName = 1;
3998
3999 // If unspecified, each key-value pair in the Data field of the referenced
4000 // Secret will be projected into the volume as a file whose name is the
4001 // key and content is the value. If specified, the listed keys will be
4002 // projected into the specified paths, and unlisted keys will not be
4003 // present. If a key is specified which is not present in the Secret,
4004 // the volume setup will error unless it is marked optional. Paths must be
4005 // relative and may not contain the '..' path or start with '..'.
4006 // +optional
4007 repeated KeyToPath items = 2;
4008
4009 // Optional: mode bits to use on created files by default. Must be a
4010 // value between 0 and 0777. Defaults to 0644.
4011 // Directories within the path are not affected by this setting.
4012 // This might be in conflict with other options that affect the file
4013 // mode, like fsGroup, and the result can be other mode bits set.
4014 // +optional
4015 optional int32 defaultMode = 3;
4016
4017 // Specify whether the Secret or it's keys must be defined
4018 // +optional
4019 optional bool optional = 4;
4020}
4021
4022// SecurityContext holds security configuration that will be applied to a container.
4023// Some fields are present in both SecurityContext and PodSecurityContext. When both
4024// are set, the values in SecurityContext take precedence.
4025message SecurityContext {
4026 // The capabilities to add/drop when running containers.
4027 // Defaults to the default set of capabilities granted by the container runtime.
4028 // +optional
4029 optional Capabilities capabilities = 1;
4030
4031 // Run container in privileged mode.
4032 // Processes in privileged containers are essentially equivalent to root on the host.
4033 // Defaults to false.
4034 // +optional
4035 optional bool privileged = 2;
4036
4037 // The SELinux context to be applied to the container.
4038 // If unspecified, the container runtime will allocate a random SELinux context for each
4039 // container. May also be set in PodSecurityContext. If set in both SecurityContext and
4040 // PodSecurityContext, the value specified in SecurityContext takes precedence.
4041 // +optional
4042 optional SELinuxOptions seLinuxOptions = 3;
4043
4044 // The UID to run the entrypoint of the container process.
4045 // Defaults to user specified in image metadata if unspecified.
4046 // May also be set in PodSecurityContext. If set in both SecurityContext and
4047 // PodSecurityContext, the value specified in SecurityContext takes precedence.
4048 // +optional
4049 optional int64 runAsUser = 4;
4050
4051 // The GID to run the entrypoint of the container process.
4052 // Uses runtime default if unset.
4053 // May also be set in PodSecurityContext. If set in both SecurityContext and
4054 // PodSecurityContext, the value specified in SecurityContext takes precedence.
4055 // +optional
4056 optional int64 runAsGroup = 8;
4057
4058 // Indicates that the container must run as a non-root user.
4059 // If true, the Kubelet will validate the image at runtime to ensure that it
4060 // does not run as UID 0 (root) and fail to start the container if it does.
4061 // If unset or false, no such validation will be performed.
4062 // May also be set in PodSecurityContext. If set in both SecurityContext and
4063 // PodSecurityContext, the value specified in SecurityContext takes precedence.
4064 // +optional
4065 optional bool runAsNonRoot = 5;
4066
4067 // Whether this container has a read-only root filesystem.
4068 // Default is false.
4069 // +optional
4070 optional bool readOnlyRootFilesystem = 6;
4071
4072 // AllowPrivilegeEscalation controls whether a process can gain more
4073 // privileges than its parent process. This bool directly controls if
4074 // the no_new_privs flag will be set on the container process.
4075 // AllowPrivilegeEscalation is true always when the container is:
4076 // 1) run as Privileged
4077 // 2) has CAP_SYS_ADMIN
4078 // +optional
4079 optional bool allowPrivilegeEscalation = 7;
4080
4081 // procMount denotes the type of proc mount to use for the containers.
4082 // The default is DefaultProcMount which uses the container runtime defaults for
4083 // readonly paths and masked paths.
4084 // This requires the ProcMountType feature flag to be enabled.
4085 // +optional
4086 optional string procMount = 9;
4087}
4088
4089// SerializedReference is a reference to serialized object.
4090message SerializedReference {
4091 // The reference to an object in the system.
4092 // +optional
4093 optional ObjectReference reference = 1;
4094}
4095
4096// Service is a named abstraction of software service (for example, mysql) consisting of local port
4097// (for example 3306) that the proxy listens on, and the selector that determines which pods
4098// will answer requests sent through the proxy.
4099message Service {
4100 // Standard object's metadata.
4101 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata
4102 // +optional
4103 optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
4104
4105 // Spec defines the behavior of a service.
4106 // https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status
4107 // +optional
4108 optional ServiceSpec spec = 2;
4109
4110 // Most recently observed status of the service.
4111 // Populated by the system.
4112 // Read-only.
4113 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status
4114 // +optional
4115 optional ServiceStatus status = 3;
4116}
4117
4118// ServiceAccount binds together:
4119// * a name, understood by users, and perhaps by peripheral systems, for an identity
4120// * a principal that can be authenticated and authorized
4121// * a set of secrets
4122message ServiceAccount {
4123 // Standard object's metadata.
4124 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata
4125 // +optional
4126 optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
4127
4128 // Secrets is the list of secrets allowed to be used by pods running using this ServiceAccount.
4129 // More info: https://kubernetes.io/docs/concepts/configuration/secret
4130 // +optional
4131 // +patchMergeKey=name
4132 // +patchStrategy=merge
4133 repeated ObjectReference secrets = 2;
4134
4135 // ImagePullSecrets is a list of references to secrets in the same namespace to use for pulling any images
4136 // in pods that reference this ServiceAccount. ImagePullSecrets are distinct from Secrets because Secrets
4137 // can be mounted in the pod, but ImagePullSecrets are only accessed by the kubelet.
4138 // More info: https://kubernetes.io/docs/concepts/containers/images/#specifying-imagepullsecrets-on-a-pod
4139 // +optional
4140 repeated LocalObjectReference imagePullSecrets = 3;
4141
4142 // AutomountServiceAccountToken indicates whether pods running as this service account should have an API token automatically mounted.
4143 // Can be overridden at the pod level.
4144 // +optional
4145 optional bool automountServiceAccountToken = 4;
4146}
4147
4148// ServiceAccountList is a list of ServiceAccount objects
4149message ServiceAccountList {
4150 // Standard list metadata.
4151 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds
4152 // +optional
4153 optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1;
4154
4155 // List of ServiceAccounts.
4156 // More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/
4157 repeated ServiceAccount items = 2;
4158}
4159
4160// ServiceAccountTokenProjection represents a projected service account token
4161// volume. This projection can be used to insert a service account token into
4162// the pods runtime filesystem for use against APIs (Kubernetes API Server or
4163// otherwise).
4164message ServiceAccountTokenProjection {
4165 // Audience is the intended audience of the token. A recipient of a token
4166 // must identify itself with an identifier specified in the audience of the
4167 // token, and otherwise should reject the token. The audience defaults to the
4168 // identifier of the apiserver.
4169 // +optional
4170 optional string audience = 1;
4171
4172 // ExpirationSeconds is the requested duration of validity of the service
4173 // account token. As the token approaches expiration, the kubelet volume
4174 // plugin will proactively rotate the service account token. The kubelet will
4175 // start trying to rotate the token if the token is older than 80 percent of
4176 // its time to live or if the token is older than 24 hours.Defaults to 1 hour
4177 // and must be at least 10 minutes.
4178 // +optional
4179 optional int64 expirationSeconds = 2;
4180
4181 // Path is the path relative to the mount point of the file to project the
4182 // token into.
4183 optional string path = 3;
4184}
4185
4186// ServiceList holds a list of services.
4187message ServiceList {
4188 // Standard list metadata.
4189 // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds
4190 // +optional
4191 optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1;
4192
4193 // List of services
4194 repeated Service items = 2;
4195}
4196
4197// ServicePort contains information on service's port.
4198message ServicePort {
4199 // The name of this port within the service. This must be a DNS_LABEL.
4200 // All ports within a ServiceSpec must have unique names. This maps to
4201 // the 'Name' field in EndpointPort objects.
4202 // Optional if only one ServicePort is defined on this service.
4203 // +optional
4204 optional string name = 1;
4205
4206 // The IP protocol for this port. Supports "TCP", "UDP", and "SCTP".
4207 // Default is TCP.
4208 // +optional
4209 optional string protocol = 2;
4210
4211 // The port that will be exposed by this service.
4212 optional int32 port = 3;
4213
4214 // Number or name of the port to access on the pods targeted by the service.
4215 // Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME.
4216 // If this is a string, it will be looked up as a named port in the
4217 // target Pod's container ports. If this is not specified, the value
4218 // of the 'port' field is used (an identity map).
4219 // This field is ignored for services with clusterIP=None, and should be
4220 // omitted or set equal to the 'port' field.
4221 // More info: https://kubernetes.io/docs/concepts/services-networking/service/#defining-a-service
4222 // +optional
4223 optional k8s.io.apimachinery.pkg.util.intstr.IntOrString targetPort = 4;
4224
4225 // The port on each node on which this service is exposed when type=NodePort or LoadBalancer.
4226 // Usually assigned by the system. If specified, it will be allocated to the service
4227 // if unused or else creation of the service will fail.
4228 // Default is to auto-allocate a port if the ServiceType of this Service requires one.
4229 // More info: https://kubernetes.io/docs/concepts/services-networking/service/#type-nodeport
4230 // +optional
4231 optional int32 nodePort = 5;
4232}
4233
4234// ServiceProxyOptions is the query options to a Service's proxy call.
4235message ServiceProxyOptions {
4236 // Path is the part of URLs that include service endpoints, suffixes,
4237 // and parameters to use for the current proxy request to service.
4238 // For example, the whole request URL is
4239 // http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy.
4240 // Path is _search?q=user:kimchy.
4241 // +optional
4242 optional string path = 1;
4243}
4244
4245// ServiceSpec describes the attributes that a user creates on a service.
4246message ServiceSpec {
4247 // The list of ports that are exposed by this service.
4248 // More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies
4249 // +patchMergeKey=port
4250 // +patchStrategy=merge
4251 repeated ServicePort ports = 1;
4252
4253 // Route service traffic to pods with label keys and values matching this
4254 // selector. If empty or not present, the service is assumed to have an
4255 // external process managing its endpoints, which Kubernetes will not
4256 // modify. Only applies to types ClusterIP, NodePort, and LoadBalancer.
4257 // Ignored if type is ExternalName.
4258 // More info: https://kubernetes.io/docs/concepts/services-networking/service/
4259 // +optional
4260 map<string, string> selector = 2;
4261
4262 // clusterIP is the IP address of the service and is usually assigned
4263 // randomly by the master. If an address is specified manually and is not in
4264 // use by others, it will be allocated to the service; otherwise, creation
4265 // of the service will fail. This field can not be changed through updates.
4266 // Valid values are "None", empty string (""), or a valid IP address. "None"
4267 // can be specified for headless services when proxying is not required.
4268 // Only applies to types ClusterIP, NodePort, and LoadBalancer. Ignored if
4269 // type is ExternalName.
4270 // More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies
4271 // +optional
4272 optional string clusterIP = 3;
4273
4274 // type determines how the Service is exposed. Defaults to ClusterIP. Valid
4275 // options are ExternalName, ClusterIP, NodePort, and LoadBalancer.
4276 // "ExternalName" maps to the specified externalName.
4277 // "ClusterIP" allocates a cluster-internal IP address for load-balancing to
4278 // endpoints. Endpoints are determined by the selector or if that is not
4279 // specified, by manual construction of an Endpoints object. If clusterIP is
4280 // "None", no virtual IP is allocated and the endpoints are published as a
4281 // set of endpoints rather than a stable IP.
4282 // "NodePort" builds on ClusterIP and allocates a port on every node which
4283 // routes to the clusterIP.
4284 // "LoadBalancer" builds on NodePort and creates an
4285 // external load-balancer (if supported in the current cloud) which routes
4286 // to the clusterIP.
4287 // More info: https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services---service-types
4288 // +optional
4289 optional string type = 4;
4290
4291 // externalIPs is a list of IP addresses for which nodes in the cluster
4292 // will also accept traffic for this service. These IPs are not managed by
4293 // Kubernetes. The user is responsible for ensuring that traffic arrives
4294 // at a node with this IP. A common example is external load-balancers
4295 // that are not part of the Kubernetes system.
4296 // +optional
4297 repeated string externalIPs = 5;
4298
4299 // Supports "ClientIP" and "None". Used to maintain session affinity.
4300 // Enable client IP based session affinity.
4301 // Must be ClientIP or None.
4302 // Defaults to None.
4303 // More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies
4304 // +optional
4305 optional string sessionAffinity = 7;
4306
4307 // Only applies to Service Type: LoadBalancer
4308 // LoadBalancer will get created with the IP specified in this field.
4309 // This feature depends on whether the underlying cloud-provider supports specifying
4310 // the loadBalancerIP when a load balancer is created.
4311 // This field will be ignored if the cloud-provider does not support the feature.
4312 // +optional
4313 optional string loadBalancerIP = 8;
4314
4315 // If specified and supported by the platform, this will restrict traffic through the cloud-provider
4316 // load-balancer will be restricted to the specified client IPs. This field will be ignored if the
4317 // cloud-provider does not support the feature."
4318 // More info: https://kubernetes.io/docs/tasks/access-application-cluster/configure-cloud-provider-firewall/
4319 // +optional
4320 repeated string loadBalancerSourceRanges = 9;
4321
4322 // externalName is the external reference that kubedns or equivalent will
4323 // return as a CNAME record for this service. No proxying will be involved.
4324 // Must be a valid RFC-1123 hostname (https://tools.ietf.org/html/rfc1123)
4325 // and requires Type to be ExternalName.
4326 // +optional
4327 optional string externalName = 10;
4328
4329 // externalTrafficPolicy denotes if this Service desires to route external
4330 // traffic to node-local or cluster-wide endpoints. "Local" preserves the
4331 // client source IP and avoids a second hop for LoadBalancer and Nodeport
4332 // type services, but risks potentially imbalanced traffic spreading.
4333 // "Cluster" obscures the client source IP and may cause a second hop to
4334 // another node, but should have good overall load-spreading.
4335 // +optional
4336 optional string externalTrafficPolicy = 11;
4337
4338 // healthCheckNodePort specifies the healthcheck nodePort for the service.
4339 // If not specified, HealthCheckNodePort is created by the service api
4340 // backend with the allocated nodePort. Will use user-specified nodePort value
4341 // if specified by the client. Only effects when Type is set to LoadBalancer
4342 // and ExternalTrafficPolicy is set to Local.
4343 // +optional
4344 optional int32 healthCheckNodePort = 12;
4345
4346 // publishNotReadyAddresses, when set to true, indicates that DNS implementations
4347 // must publish the notReadyAddresses of subsets for the Endpoints associated with
4348 // the Service. The default value is false.
4349 // The primary use case for setting this field is to use a StatefulSet's Headless Service
4350 // to propagate SRV records for its Pods without respect to their readiness for purpose
4351 // of peer discovery.
4352 // +optional
4353 optional bool publishNotReadyAddresses = 13;
4354
4355 // sessionAffinityConfig contains the configurations of session affinity.
4356 // +optional
4357 optional SessionAffinityConfig sessionAffinityConfig = 14;
4358}
4359
4360// ServiceStatus represents the current status of a service.
4361message ServiceStatus {
4362 // LoadBalancer contains the current status of the load-balancer,
4363 // if one is present.
4364 // +optional
4365 optional LoadBalancerStatus loadBalancer = 1;
4366}
4367
4368// SessionAffinityConfig represents the configurations of session affinity.
4369message SessionAffinityConfig {
4370 // clientIP contains the configurations of Client IP based session affinity.
4371 // +optional
4372 optional ClientIPConfig clientIP = 1;
4373}
4374
4375// Represents a StorageOS persistent volume resource.
4376message StorageOSPersistentVolumeSource {
4377 // VolumeName is the human-readable name of the StorageOS volume. Volume
4378 // names are only unique within a namespace.
4379 optional string volumeName = 1;
4380
4381 // VolumeNamespace specifies the scope of the volume within StorageOS. If no
4382 // namespace is specified then the Pod's namespace will be used. This allows the
4383 // Kubernetes name scoping to be mirrored within StorageOS for tighter integration.
4384 // Set VolumeName to any name to override the default behaviour.
4385 // Set to "default" if you are not using namespaces within StorageOS.
4386 // Namespaces that do not pre-exist within StorageOS will be created.
4387 // +optional
4388 optional string volumeNamespace = 2;
4389
4390 // Filesystem type to mount.
4391 // Must be a filesystem type supported by the host operating system.
4392 // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
4393 // +optional
4394 optional string fsType = 3;
4395
4396 // Defaults to false (read/write). ReadOnly here will force
4397 // the ReadOnly setting in VolumeMounts.
4398 // +optional
4399 optional bool readOnly = 4;
4400
4401 // SecretRef specifies the secret to use for obtaining the StorageOS API
4402 // credentials. If not specified, default values will be attempted.
4403 // +optional
4404 optional ObjectReference secretRef = 5;
4405}
4406
4407// Represents a StorageOS persistent volume resource.
4408message StorageOSVolumeSource {
4409 // VolumeName is the human-readable name of the StorageOS volume. Volume
4410 // names are only unique within a namespace.
4411 optional string volumeName = 1;
4412
4413 // VolumeNamespace specifies the scope of the volume within StorageOS. If no
4414 // namespace is specified then the Pod's namespace will be used. This allows the
4415 // Kubernetes name scoping to be mirrored within StorageOS for tighter integration.
4416 // Set VolumeName to any name to override the default behaviour.
4417 // Set to "default" if you are not using namespaces within StorageOS.
4418 // Namespaces that do not pre-exist within StorageOS will be created.
4419 // +optional
4420 optional string volumeNamespace = 2;
4421
4422 // Filesystem type to mount.
4423 // Must be a filesystem type supported by the host operating system.
4424 // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
4425 // +optional
4426 optional string fsType = 3;
4427
4428 // Defaults to false (read/write). ReadOnly here will force
4429 // the ReadOnly setting in VolumeMounts.
4430 // +optional
4431 optional bool readOnly = 4;
4432
4433 // SecretRef specifies the secret to use for obtaining the StorageOS API
4434 // credentials. If not specified, default values will be attempted.
4435 // +optional
4436 optional LocalObjectReference secretRef = 5;
4437}
4438
4439// Sysctl defines a kernel parameter to be set
4440message Sysctl {
4441 // Name of a property to set
4442 optional string name = 1;
4443
4444 // Value of a property to set
4445 optional string value = 2;
4446}
4447
4448// TCPSocketAction describes an action based on opening a socket
4449message TCPSocketAction {
4450 // Number or name of the port to access on the container.
4451 // Number must be in the range 1 to 65535.
4452 // Name must be an IANA_SVC_NAME.
4453 optional k8s.io.apimachinery.pkg.util.intstr.IntOrString port = 1;
4454
4455 // Optional: Host name to connect to, defaults to the pod IP.
4456 // +optional
4457 optional string host = 2;
4458}
4459
4460// The node this Taint is attached to has the "effect" on
4461// any pod that does not tolerate the Taint.
4462message Taint {
4463 // Required. The taint key to be applied to a node.
4464 optional string key = 1;
4465
4466 // Required. The taint value corresponding to the taint key.
4467 // +optional
4468 optional string value = 2;
4469
4470 // Required. The effect of the taint on pods
4471 // that do not tolerate the taint.
4472 // Valid effects are NoSchedule, PreferNoSchedule and NoExecute.
4473 optional string effect = 3;
4474
4475 // TimeAdded represents the time at which the taint was added.
4476 // It is only written for NoExecute taints.
4477 // +optional
4478 optional k8s.io.apimachinery.pkg.apis.meta.v1.Time timeAdded = 4;
4479}
4480
4481// The pod this Toleration is attached to tolerates any taint that matches
4482// the triple <key,value,effect> using the matching operator <operator>.
4483message Toleration {
4484 // Key is the taint key that the toleration applies to. Empty means match all taint keys.
4485 // If the key is empty, operator must be Exists; this combination means to match all values and all keys.
4486 // +optional
4487 optional string key = 1;
4488
4489 // Operator represents a key's relationship to the value.
4490 // Valid operators are Exists and Equal. Defaults to Equal.
4491 // Exists is equivalent to wildcard for value, so that a pod can
4492 // tolerate all taints of a particular category.
4493 // +optional
4494 optional string operator = 2;
4495
4496 // Value is the taint value the toleration matches to.
4497 // If the operator is Exists, the value should be empty, otherwise just a regular string.
4498 // +optional
4499 optional string value = 3;
4500
4501 // Effect indicates the taint effect to match. Empty means match all taint effects.
4502 // When specified, allowed values are NoSchedule, PreferNoSchedule and NoExecute.
4503 // +optional
4504 optional string effect = 4;
4505
4506 // TolerationSeconds represents the period of time the toleration (which must be
4507 // of effect NoExecute, otherwise this field is ignored) tolerates the taint. By default,
4508 // it is not set, which means tolerate the taint forever (do not evict). Zero and
4509 // negative values will be treated as 0 (evict immediately) by the system.
4510 // +optional
4511 optional int64 tolerationSeconds = 5;
4512}
4513
4514// A topology selector requirement is a selector that matches given label.
4515// This is an alpha feature and may change in the future.
4516message TopologySelectorLabelRequirement {
4517 // The label key that the selector applies to.
4518 optional string key = 1;
4519
4520 // An array of string values. One value must match the label to be selected.
4521 // Each entry in Values is ORed.
4522 repeated string values = 2;
4523}
4524
4525// A topology selector term represents the result of label queries.
4526// A null or empty topology selector term matches no objects.
4527// The requirements of them are ANDed.
4528// It provides a subset of functionality as NodeSelectorTerm.
4529// This is an alpha feature and may change in the future.
4530message TopologySelectorTerm {
4531 // A list of topology selector requirements by labels.
4532 // +optional
4533 repeated TopologySelectorLabelRequirement matchLabelExpressions = 1;
4534}
4535
4536// TypedLocalObjectReference contains enough information to let you locate the
4537// typed referenced object inside the same namespace.
4538message TypedLocalObjectReference {
4539 // APIGroup is the group for the resource being referenced.
4540 // If APIGroup is not specified, the specified Kind must be in the core API group.
4541 // For any other third-party types, APIGroup is required.
4542 // +optional
4543 optional string apiGroup = 1;
4544
4545 // Kind is the type of resource being referenced
4546 optional string kind = 2;
4547
4548 // Name is the name of resource being referenced
4549 optional string name = 3;
4550}
4551
4552// Volume represents a named volume in a pod that may be accessed by any container in the pod.
4553message Volume {
4554 // Volume's name.
4555 // Must be a DNS_LABEL and unique within the pod.
4556 // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
4557 optional string name = 1;
4558
4559 // VolumeSource represents the location and type of the mounted volume.
4560 // If not specified, the Volume is implied to be an EmptyDir.
4561 // This implied behavior is deprecated and will be removed in a future version.
4562 optional VolumeSource volumeSource = 2;
4563}
4564
4565// volumeDevice describes a mapping of a raw block device within a container.
4566message VolumeDevice {
4567 // name must match the name of a persistentVolumeClaim in the pod
4568 optional string name = 1;
4569
4570 // devicePath is the path inside of the container that the device will be mapped to.
4571 optional string devicePath = 2;
4572}
4573
4574// VolumeMount describes a mounting of a Volume within a container.
4575message VolumeMount {
4576 // This must match the Name of a Volume.
4577 optional string name = 1;
4578
4579 // Mounted read-only if true, read-write otherwise (false or unspecified).
4580 // Defaults to false.
4581 // +optional
4582 optional bool readOnly = 2;
4583
4584 // Path within the container at which the volume should be mounted. Must
4585 // not contain ':'.
4586 optional string mountPath = 3;
4587
4588 // Path within the volume from which the container's volume should be mounted.
4589 // Defaults to "" (volume's root).
4590 // +optional
4591 optional string subPath = 4;
4592
4593 // mountPropagation determines how mounts are propagated from the host
4594 // to container and the other way around.
4595 // When not set, MountPropagationNone is used.
4596 // This field is beta in 1.10.
4597 // +optional
4598 optional string mountPropagation = 5;
4599}
4600
4601// VolumeNodeAffinity defines constraints that limit what nodes this volume can be accessed from.
4602message VolumeNodeAffinity {
4603 // Required specifies hard node constraints that must be met.
4604 optional NodeSelector required = 1;
4605}
4606
4607// Projection that may be projected along with other supported volume types
4608message VolumeProjection {
4609 // information about the secret data to project
4610 // +optional
4611 optional SecretProjection secret = 1;
4612
4613 // information about the downwardAPI data to project
4614 // +optional
4615 optional DownwardAPIProjection downwardAPI = 2;
4616
4617 // information about the configMap data to project
4618 // +optional
4619 optional ConfigMapProjection configMap = 3;
4620
4621 // information about the serviceAccountToken data to project
4622 // +optional
4623 optional ServiceAccountTokenProjection serviceAccountToken = 4;
4624}
4625
4626// Represents the source of a volume to mount.
4627// Only one of its members may be specified.
4628message VolumeSource {
4629 // HostPath represents a pre-existing file or directory on the host
4630 // machine that is directly exposed to the container. This is generally
4631 // used for system agents or other privileged things that are allowed
4632 // to see the host machine. Most containers will NOT need this.
4633 // More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath
4634 // ---
4635 // TODO(jonesdl) We need to restrict who can use host directory mounts and who can/can not
4636 // mount host directories as read/write.
4637 // +optional
4638 optional HostPathVolumeSource hostPath = 1;
4639
4640 // EmptyDir represents a temporary directory that shares a pod's lifetime.
4641 // More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir
4642 // +optional
4643 optional EmptyDirVolumeSource emptyDir = 2;
4644
4645 // GCEPersistentDisk represents a GCE Disk resource that is attached to a
4646 // kubelet's host machine and then exposed to the pod.
4647 // More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk
4648 // +optional
4649 optional GCEPersistentDiskVolumeSource gcePersistentDisk = 3;
4650
4651 // AWSElasticBlockStore represents an AWS Disk resource that is attached to a
4652 // kubelet's host machine and then exposed to the pod.
4653 // More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore
4654 // +optional
4655 optional AWSElasticBlockStoreVolumeSource awsElasticBlockStore = 4;
4656
4657 // GitRepo represents a git repository at a particular revision.
4658 // DEPRECATED: GitRepo is deprecated. To provision a container with a git repo, mount an
4659 // EmptyDir into an InitContainer that clones the repo using git, then mount the EmptyDir
4660 // into the Pod's container.
4661 // +optional
4662 optional GitRepoVolumeSource gitRepo = 5;
4663
4664 // Secret represents a secret that should populate this volume.
4665 // More info: https://kubernetes.io/docs/concepts/storage/volumes#secret
4666 // +optional
4667 optional SecretVolumeSource secret = 6;
4668
4669 // NFS represents an NFS mount on the host that shares a pod's lifetime
4670 // More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs
4671 // +optional
4672 optional NFSVolumeSource nfs = 7;
4673
4674 // ISCSI represents an ISCSI Disk resource that is attached to a
4675 // kubelet's host machine and then exposed to the pod.
4676 // More info: https://releases.k8s.io/HEAD/examples/volumes/iscsi/README.md
4677 // +optional
4678 optional ISCSIVolumeSource iscsi = 8;
4679
4680 // Glusterfs represents a Glusterfs mount on the host that shares a pod's lifetime.
4681 // More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md
4682 // +optional
4683 optional GlusterfsVolumeSource glusterfs = 9;
4684
4685 // PersistentVolumeClaimVolumeSource represents a reference to a
4686 // PersistentVolumeClaim in the same namespace.
4687 // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims
4688 // +optional
4689 optional PersistentVolumeClaimVolumeSource persistentVolumeClaim = 10;
4690
4691 // RBD represents a Rados Block Device mount on the host that shares a pod's lifetime.
4692 // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md
4693 // +optional
4694 optional RBDVolumeSource rbd = 11;
4695
4696 // FlexVolume represents a generic volume resource that is
4697 // provisioned/attached using an exec based plugin.
4698 // +optional
4699 optional FlexVolumeSource flexVolume = 12;
4700
4701 // Cinder represents a cinder volume attached and mounted on kubelets host machine
4702 // More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md
4703 // +optional
4704 optional CinderVolumeSource cinder = 13;
4705
4706 // CephFS represents a Ceph FS mount on the host that shares a pod's lifetime
4707 // +optional
4708 optional CephFSVolumeSource cephfs = 14;
4709
4710 // Flocker represents a Flocker volume attached to a kubelet's host machine. This depends on the Flocker control service being running
4711 // +optional
4712 optional FlockerVolumeSource flocker = 15;
4713
4714 // DownwardAPI represents downward API about the pod that should populate this volume
4715 // +optional
4716 optional DownwardAPIVolumeSource downwardAPI = 16;
4717
4718 // FC represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod.
4719 // +optional
4720 optional FCVolumeSource fc = 17;
4721
4722 // AzureFile represents an Azure File Service mount on the host and bind mount to the pod.
4723 // +optional
4724 optional AzureFileVolumeSource azureFile = 18;
4725
4726 // ConfigMap represents a configMap that should populate this volume
4727 // +optional
4728 optional ConfigMapVolumeSource configMap = 19;
4729
4730 // VsphereVolume represents a vSphere volume attached and mounted on kubelets host machine
4731 // +optional
4732 optional VsphereVirtualDiskVolumeSource vsphereVolume = 20;
4733
4734 // Quobyte represents a Quobyte mount on the host that shares a pod's lifetime
4735 // +optional
4736 optional QuobyteVolumeSource quobyte = 21;
4737
4738 // AzureDisk represents an Azure Data Disk mount on the host and bind mount to the pod.
4739 // +optional
4740 optional AzureDiskVolumeSource azureDisk = 22;
4741
4742 // PhotonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine
4743 optional PhotonPersistentDiskVolumeSource photonPersistentDisk = 23;
4744
4745 // Items for all in one resources secrets, configmaps, and downward API
4746 optional ProjectedVolumeSource projected = 26;
4747
4748 // PortworxVolume represents a portworx volume attached and mounted on kubelets host machine
4749 // +optional
4750 optional PortworxVolumeSource portworxVolume = 24;
4751
4752 // ScaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes.
4753 // +optional
4754 optional ScaleIOVolumeSource scaleIO = 25;
4755
4756 // StorageOS represents a StorageOS volume attached and mounted on Kubernetes nodes.
4757 // +optional
4758 optional StorageOSVolumeSource storageos = 27;
4759}
4760
4761// Represents a vSphere volume resource.
4762message VsphereVirtualDiskVolumeSource {
4763 // Path that identifies vSphere volume vmdk
4764 optional string volumePath = 1;
4765
4766 // Filesystem type to mount.
4767 // Must be a filesystem type supported by the host operating system.
4768 // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
4769 // +optional
4770 optional string fsType = 2;
4771
4772 // Storage Policy Based Management (SPBM) profile name.
4773 // +optional
4774 optional string storagePolicyName = 3;
4775
4776 // Storage Policy Based Management (SPBM) profile ID associated with the StoragePolicyName.
4777 // +optional
4778 optional string storagePolicyID = 4;
4779}
4780
4781// The weights of all of the matched WeightedPodAffinityTerm fields are added per-node to find the most preferred node(s)
4782message WeightedPodAffinityTerm {
4783 // weight associated with matching the corresponding podAffinityTerm,
4784 // in the range 1-100.
4785 optional int32 weight = 1;
4786
4787 // Required. A pod affinity term, associated with the corresponding weight.
4788 optional PodAffinityTerm podAffinityTerm = 2;
4789}
4790