// AUTOGENERATED from the Kubernetes OpenAPI specification. DO NOT MODIFY. // Kubernetes version: v1.7.0 // SHA of ksonnet-lib HEAD: 16cce978067ba5ab7dc94e69ec2186976ff9b60e // SHA of Kubernetes HEAD OpenAPI spec is generated from: d3ada0119e776222f11ec7945e6d860061339aad { admissionregistration:: { v1alpha1:: { local apiVersion = {apiVersion: "admissionregistration.k8s.io/v1alpha1"}, // ExternalAdmissionHookConfiguration describes the configuration of initializers. externalAdmissionHookConfiguration:: { local kind = {kind: "ExternalAdmissionHookConfiguration"}, new():: apiVersion + kind, // ExternalAdmissionHooks is a list of external admission webhooks and the affected resources and operations. externalAdmissionHooks(externalAdmissionHooks):: if std.type(externalAdmissionHooks) == "array" then {externalAdmissionHooks+: externalAdmissionHooks} else {externalAdmissionHooks+: [externalAdmissionHooks]}, externalAdmissionHooksType:: hidden.admissionregistration.v1alpha1.externalAdmissionHook, mixin:: { // Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata. metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, }, }, // ExternalAdmissionHookConfigurationList is a list of ExternalAdmissionHookConfiguration. externalAdmissionHookConfigurationList:: { local kind = {kind: "ExternalAdmissionHookConfigurationList"}, new():: apiVersion + kind, // List of ExternalAdmissionHookConfiguration. items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.admissionregistration.v1alpha1.externalAdmissionHookConfiguration, mixin:: { // Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // String that identifies the server's internal version of this object that can be used by clients to determine when objects have changed. Value must be treated as opaque by clients and passed unmodified back to the server. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency resourceVersion(resourceVersion):: __metadataMixin({resourceVersion: resourceVersion}), // SelfLink is a URL representing this object. Populated by the system. Read-only. selfLink(selfLink):: __metadataMixin({selfLink: selfLink}), }, metadataType:: hidden.meta.v1.listMeta, }, }, // InitializerConfiguration describes the configuration of initializers. initializerConfiguration:: { local kind = {kind: "InitializerConfiguration"}, new():: apiVersion + kind, // Initializers is a list of resources and their default initializers Order-sensitive. When merging multiple InitializerConfigurations, we sort the initializers from different InitializerConfigurations by the name of the InitializerConfigurations; the order of the initializers from the same InitializerConfiguration is preserved. initializers(initializers):: if std.type(initializers) == "array" then {initializers+: initializers} else {initializers+: [initializers]}, initializersType:: hidden.admissionregistration.v1alpha1.initializer, mixin:: { // Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata. metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, }, }, // InitializerConfigurationList is a list of InitializerConfiguration. initializerConfigurationList:: { local kind = {kind: "InitializerConfigurationList"}, new():: apiVersion + kind, // List of InitializerConfiguration. items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.admissionregistration.v1alpha1.initializerConfiguration, mixin:: { // Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // String that identifies the server's internal version of this object that can be used by clients to determine when objects have changed. Value must be treated as opaque by clients and passed unmodified back to the server. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency resourceVersion(resourceVersion):: __metadataMixin({resourceVersion: resourceVersion}), // SelfLink is a URL representing this object. Populated by the system. Read-only. selfLink(selfLink):: __metadataMixin({selfLink: selfLink}), }, metadataType:: hidden.meta.v1.listMeta, }, }, }, }, apps:: { v1beta1:: { local apiVersion = {apiVersion: "apps/v1beta1"}, // ControllerRevision implements an immutable snapshot of state data. Clients are responsible for serializing and deserializing the objects that contain their internal state. Once a ControllerRevision has been successfully created, it can not be updated. The API Server will fail validation of all requests that attempt to mutate the Data field. ControllerRevisions may, however, be deleted. Note that, due to its use by both the DaemonSet and StatefulSet controllers for update and rollback, this object is beta. However, it may be subject to name and representation changes in future releases, and clients should not depend on its stability. It is primarily for internal use by controllers. controllerRevision:: { local kind = {kind: "ControllerRevision"}, new():: apiVersion + kind, // Revision indicates the revision of the state represented by Data. revision(revision):: {revision: revision}, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, }, }, // ControllerRevisionList is a resource containing a list of ControllerRevision objects. controllerRevisionList:: { local kind = {kind: "ControllerRevisionList"}, new():: apiVersion + kind, // Items is the list of ControllerRevisions items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.apps.v1beta1.controllerRevision, mixin:: { // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // String that identifies the server's internal version of this object that can be used by clients to determine when objects have changed. Value must be treated as opaque by clients and passed unmodified back to the server. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency resourceVersion(resourceVersion):: __metadataMixin({resourceVersion: resourceVersion}), // SelfLink is a URL representing this object. Populated by the system. Read-only. selfLink(selfLink):: __metadataMixin({selfLink: selfLink}), }, metadataType:: hidden.meta.v1.listMeta, }, }, // Deployment enables declarative updates for Pods and ReplicaSets. deployment:: { local kind = {kind: "Deployment"}, new(name, replicas, containers, podLabels={}):: apiVersion + kind + self.mixin.metadata.name(name) + self.mixin.spec.replicas(replicas) + self.mixin.spec.template.spec.containers(containers) + self.mixin.spec.template.metadata.labels(podLabels), mixin:: { // Standard object metadata. metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the Deployment. spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // Minimum number of seconds for which a newly created pod should be ready without any of its container crashing, for it to be considered available. Defaults to 0 (pod will be considered available as soon as it is ready) minReadySeconds(minReadySeconds):: __specMixin({minReadySeconds: minReadySeconds}), // Indicates that the deployment is paused. paused(paused):: __specMixin({paused: paused}), // The maximum time in seconds for a deployment to make progress before it is considered to be failed. The deployment controller will continue to process failed deployments and a condition with a ProgressDeadlineExceeded reason will be surfaced in the deployment status. Once autoRollback is implemented, the deployment controller will automatically rollback failed deployments. Note that progress will not be estimated during the time a deployment is paused. Defaults to 600s. progressDeadlineSeconds(progressDeadlineSeconds):: __specMixin({progressDeadlineSeconds: progressDeadlineSeconds}), // Number of desired pods. This is a pointer to distinguish between explicit zero and not specified. Defaults to 1. replicas(replicas):: __specMixin({replicas: replicas}), // The number of old ReplicaSets to retain to allow rollback. This is a pointer to distinguish between explicit zero and not specified. Defaults to 2. revisionHistoryLimit(revisionHistoryLimit):: __specMixin({revisionHistoryLimit: revisionHistoryLimit}), // The config this deployment is rolling back to. Will be cleared after rollback is done. rollbackTo:: { local __rollbackToMixin(rollbackTo) = __specMixin({rollbackTo+: rollbackTo}), mixinInstance(rollbackTo):: __rollbackToMixin(rollbackTo), // The revision to rollback to. If set to 0, rollback to the last revision. revision(revision):: __rollbackToMixin({revision: revision}), }, rollbackToType:: hidden.apps.v1beta1.rollbackConfig, // Label selector for pods. Existing ReplicaSets whose pods are selected by this will be the ones affected by this deployment. selector:: { local __selectorMixin(selector) = __specMixin({selector+: selector}), mixinInstance(selector):: __selectorMixin(selector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __selectorMixin({matchExpressions+: matchExpressions}) else __selectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __selectorMixin({matchLabels+: matchLabels}), }, selectorType:: hidden.meta.v1.labelSelector, // The deployment strategy to use to replace existing pods with new ones. strategy:: { local __strategyMixin(strategy) = __specMixin({strategy+: strategy}), mixinInstance(strategy):: __strategyMixin(strategy), // Rolling update config params. Present only if DeploymentStrategyType = RollingUpdate. rollingUpdate:: { local __rollingUpdateMixin(rollingUpdate) = __strategyMixin({rollingUpdate+: rollingUpdate}), mixinInstance(rollingUpdate):: __rollingUpdateMixin(rollingUpdate), // The maximum number of pods that can be scheduled above the desired number of pods. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). This can not be 0 if MaxUnavailable is 0. Absolute number is calculated from percentage by rounding up. Defaults to 25%. Example: when this is set to 30%, the new RC can be scaled up immediately when the rolling update starts, such that the total number of old and new pods do not exceed 130% of desired pods. Once old pods have been killed, new RC can be scaled up further, ensuring that total number of pods running at any time during the update is atmost 130% of desired pods. maxSurge(maxSurge):: __rollingUpdateMixin({maxSurge: maxSurge}), // The maximum number of pods that can be unavailable during the update. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). Absolute number is calculated from percentage by rounding down. This can not be 0 if MaxSurge is 0. Defaults to 25%. Example: when this is set to 30%, the old RC can be scaled down to 70% of desired pods immediately when the rolling update starts. Once new pods are ready, old RC can be scaled down further, followed by scaling up the new RC, ensuring that the total number of pods available at all times during the update is at least 70% of desired pods. maxUnavailable(maxUnavailable):: __rollingUpdateMixin({maxUnavailable: maxUnavailable}), }, rollingUpdateType:: hidden.apps.v1beta1.rollingUpdateDeployment, // Type of deployment. Can be "Recreate" or "RollingUpdate". Default is RollingUpdate. type(type):: __strategyMixin({type: type}), }, strategyType:: hidden.apps.v1beta1.deploymentStrategy, // Template describes the pods that will be created. template:: { local __templateMixin(template) = __specMixin({template+: template}), mixinInstance(template):: __templateMixin(template), // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = __templateMixin({metadata+: metadata}), mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = __templateMixin({spec+: spec}), mixinInstance(spec):: __specMixin(spec), // Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer. activeDeadlineSeconds(activeDeadlineSeconds):: __specMixin({activeDeadlineSeconds: activeDeadlineSeconds}), // If specified, the pod's scheduling constraints affinity:: { local __affinityMixin(affinity) = __specMixin({affinity+: affinity}), mixinInstance(affinity):: __affinityMixin(affinity), // Describes node affinity scheduling rules for the pod. nodeAffinity:: { local __nodeAffinityMixin(nodeAffinity) = __affinityMixin({nodeAffinity+: nodeAffinity}), mixinInstance(nodeAffinity):: __nodeAffinityMixin(nodeAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.preferredSchedulingTerm, // If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node. requiredDuringSchedulingIgnoredDuringExecution:: { local __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution) = __nodeAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}), mixinInstance(requiredDuringSchedulingIgnoredDuringExecution):: __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution), // Required. A list of node selector terms. The terms are ORed. nodeSelectorTerms(nodeSelectorTerms):: if std.type(nodeSelectorTerms) == "array" then __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: nodeSelectorTerms}) else __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: [nodeSelectorTerms]}), nodeSelectorTermsType:: hidden.core.v1.nodeSelectorTerm, }, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.nodeSelector, }, nodeAffinityType:: hidden.core.v1.nodeAffinity, // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)). podAffinity:: { local __podAffinityMixin(podAffinity) = __affinityMixin({podAffinity+: podAffinity}), mixinInstance(podAffinity):: __podAffinityMixin(podAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAffinityType:: hidden.core.v1.podAffinity, // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)). podAntiAffinity:: { local __podAntiAffinityMixin(podAntiAffinity) = __affinityMixin({podAntiAffinity+: podAntiAffinity}), mixinInstance(podAntiAffinity):: __podAntiAffinityMixin(podAntiAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAntiAffinityType:: hidden.core.v1.podAntiAffinity, }, affinityType:: hidden.core.v1.affinity, // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted. automountServiceAccountToken(automountServiceAccountToken):: __specMixin({automountServiceAccountToken: automountServiceAccountToken}), // List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated. containers(containers):: if std.type(containers) == "array" then __specMixin({containers+: containers}) else __specMixin({containers+: [containers]}), containersType:: hidden.core.v1.container, // Set DNS policy for containers within the pod. One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. Defaults to "ClusterFirst". To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. dnsPolicy(dnsPolicy):: __specMixin({dnsPolicy: dnsPolicy}), // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts file if specified. This is only valid for non-hostNetwork pods. hostAliases(hostAliases):: if std.type(hostAliases) == "array" then __specMixin({hostAliases+: hostAliases}) else __specMixin({hostAliases+: [hostAliases]}), hostAliasesType:: hidden.core.v1.hostAlias, // Use the host's ipc namespace. Optional: Default to false. hostIpc(hostIpc):: __specMixin({hostIPC: hostIpc}), // Host networking requested for this pod. Use the host's network namespace. If this option is set, the ports that will be used must be specified. Default to false. hostNetwork(hostNetwork):: __specMixin({hostNetwork: hostNetwork}), // Use the host's pid namespace. Optional: Default to false. hostPid(hostPid):: __specMixin({hostPID: hostPid}), // Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value. hostname(hostname):: __specMixin({hostname: hostname}), // 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. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod imagePullSecrets(imagePullSecrets):: if std.type(imagePullSecrets) == "array" then __specMixin({imagePullSecrets+: imagePullSecrets}) else __specMixin({imagePullSecrets+: [imagePullSecrets]}), imagePullSecretsType:: hidden.core.v1.localObjectReference, // List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ initContainers(initContainers):: if std.type(initContainers) == "array" then __specMixin({initContainers+: initContainers}) else __specMixin({initContainers+: [initContainers]}), initContainersType:: hidden.core.v1.container, // NodeName is a request to schedule this pod onto a specific node. If it is non-empty, the scheduler simply schedules this pod onto that node, assuming that it fits resource requirements. nodeName(nodeName):: __specMixin({nodeName: nodeName}), // NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ nodeSelector(nodeSelector):: __specMixin({nodeSelector+: nodeSelector}), // Restart policy for all containers within the pod. One of Always, OnFailure, Never. Default to Always. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy restartPolicy(restartPolicy):: __specMixin({restartPolicy: restartPolicy}), // If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler. schedulerName(schedulerName):: __specMixin({schedulerName: schedulerName}), // SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field. securityContext:: { local __securityContextMixin(securityContext) = __specMixin({securityContext+: securityContext}), mixinInstance(securityContext):: __securityContextMixin(securityContext), // A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod: // // 1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw---- // // If unset, the Kubelet will not modify the ownership and permissions of any volume. fsGroup(fsGroup):: __securityContextMixin({fsGroup: fsGroup}), // Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsNonRoot(runAsNonRoot):: __securityContextMixin({runAsNonRoot: runAsNonRoot}), // The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. runAsUser(runAsUser):: __securityContextMixin({runAsUser: runAsUser}), // The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = __securityContextMixin({seLinuxOptions+: seLinuxOptions}), mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, // A list of groups applied to the first process run in each container, in addition to the container's primary GID. If unspecified, no groups will be added to any container. supplementalGroups(supplementalGroups):: if std.type(supplementalGroups) == "array" then __securityContextMixin({supplementalGroups+: supplementalGroups}) else __securityContextMixin({supplementalGroups+: [supplementalGroups]}), }, securityContextType:: hidden.core.v1.podSecurityContext, // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead. serviceAccount(serviceAccount):: __specMixin({serviceAccount: serviceAccount}), // ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ serviceAccountName(serviceAccountName):: __specMixin({serviceAccountName: serviceAccountName}), // If specified, the fully qualified Pod hostname will be "...svc.". If not specified, the pod will not have a domainname at all. subdomain(subdomain):: __specMixin({subdomain: subdomain}), // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds. terminationGracePeriodSeconds(terminationGracePeriodSeconds):: __specMixin({terminationGracePeriodSeconds: terminationGracePeriodSeconds}), // If specified, the pod's tolerations. tolerations(tolerations):: if std.type(tolerations) == "array" then __specMixin({tolerations+: tolerations}) else __specMixin({tolerations+: [tolerations]}), tolerationsType:: hidden.core.v1.toleration, // List of volumes that can be mounted by containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes volumes(volumes):: if std.type(volumes) == "array" then __specMixin({volumes+: volumes}) else __specMixin({volumes+: [volumes]}), volumesType:: hidden.core.v1.volume, }, specType:: hidden.core.v1.podSpec, }, templateType:: hidden.core.v1.podTemplateSpec, }, specType:: hidden.apps.v1beta1.deploymentSpec, }, }, // DeploymentList is a list of Deployments. deploymentList:: { local kind = {kind: "DeploymentList"}, new():: apiVersion + kind, // Items is the list of Deployments. items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.apps.v1beta1.deployment, mixin:: { }, }, // DeploymentRollback stores the information required to rollback a deployment. deploymentRollback:: { local kind = {kind: "DeploymentRollback"}, new():: apiVersion + kind, // Required: This must match the Name of a deployment. name(name):: {name: name}, // The annotations to be updated to a deployment updatedAnnotations(updatedAnnotations):: {updatedAnnotations+: updatedAnnotations}, mixin:: { // The config of this deployment rollback. rollbackTo:: { local __rollbackToMixin(rollbackTo) = {rollbackTo+: rollbackTo}, mixinInstance(rollbackTo):: __rollbackToMixin(rollbackTo), // The revision to rollback to. If set to 0, rollback to the last revision. revision(revision):: __rollbackToMixin({revision: revision}), }, rollbackToType:: hidden.apps.v1beta1.rollbackConfig, }, }, // Scale represents a scaling request for a resource. scale:: { local kind = {kind: "Scale"}, new():: apiVersion + kind, mixin:: { // Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata. metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // defines the behavior of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // desired number of instances for the scaled object. replicas(replicas):: __specMixin({replicas: replicas}), }, specType:: hidden.apps.v1beta1.scaleSpec, }, }, // StatefulSet represents a set of pods with consistent identities. Identities are defined as: // - Network: A single stable DNS and hostname. // - Storage: As many VolumeClaims as requested. // The StatefulSet guarantees that a given network identity will always map to the same storage identity. statefulSet:: { local kind = {kind: "StatefulSet"}, new():: apiVersion + kind, mixin:: { // metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Spec defines the desired identities of pods in this set. spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // podManagementPolicy controls how pods are created during initial scale up, when replacing pods on nodes, or when scaling down. The default policy is `OrderedReady`, where pods are created in increasing order (pod-0, then pod-1, etc) and the controller will wait until each pod is ready before continuing. When scaling down, the pods are removed in the opposite order. The alternative policy is `Parallel` which will create pods in parallel to match the desired scale without waiting, and on scale down will delete all pods at once. podManagementPolicy(podManagementPolicy):: __specMixin({podManagementPolicy: podManagementPolicy}), // replicas is the desired number of replicas of the given Template. These are replicas in the sense that they are instantiations of the same Template, but individual replicas also have a consistent identity. If unspecified, defaults to 1. replicas(replicas):: __specMixin({replicas: replicas}), // revisionHistoryLimit is the maximum number of revisions that will be maintained in the StatefulSet's revision history. The revision history consists of all revisions not represented by a currently applied StatefulSetSpec version. The default value is 10. revisionHistoryLimit(revisionHistoryLimit):: __specMixin({revisionHistoryLimit: revisionHistoryLimit}), // selector is a label query over pods that should match the replica count. If empty, defaulted to labels on the pod template. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors selector:: { local __selectorMixin(selector) = __specMixin({selector+: selector}), mixinInstance(selector):: __selectorMixin(selector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __selectorMixin({matchExpressions+: matchExpressions}) else __selectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __selectorMixin({matchLabels+: matchLabels}), }, selectorType:: hidden.meta.v1.labelSelector, // serviceName is the name of the service that governs this StatefulSet. This service must exist before the StatefulSet, and is responsible for the network identity of the set. Pods get DNS/hostnames that follow the pattern: pod-specific-string.serviceName.default.svc.cluster.local where "pod-specific-string" is managed by the StatefulSet controller. serviceName(serviceName):: __specMixin({serviceName: serviceName}), // template is the object that describes the pod that will be created if insufficient replicas are detected. Each pod stamped out by the StatefulSet will fulfill this Template, but have a unique identity from the rest of the StatefulSet. template:: { local __templateMixin(template) = __specMixin({template+: template}), mixinInstance(template):: __templateMixin(template), // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = __templateMixin({metadata+: metadata}), mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = __templateMixin({spec+: spec}), mixinInstance(spec):: __specMixin(spec), // Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer. activeDeadlineSeconds(activeDeadlineSeconds):: __specMixin({activeDeadlineSeconds: activeDeadlineSeconds}), // If specified, the pod's scheduling constraints affinity:: { local __affinityMixin(affinity) = __specMixin({affinity+: affinity}), mixinInstance(affinity):: __affinityMixin(affinity), // Describes node affinity scheduling rules for the pod. nodeAffinity:: { local __nodeAffinityMixin(nodeAffinity) = __affinityMixin({nodeAffinity+: nodeAffinity}), mixinInstance(nodeAffinity):: __nodeAffinityMixin(nodeAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.preferredSchedulingTerm, // If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node. requiredDuringSchedulingIgnoredDuringExecution:: { local __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution) = __nodeAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}), mixinInstance(requiredDuringSchedulingIgnoredDuringExecution):: __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution), // Required. A list of node selector terms. The terms are ORed. nodeSelectorTerms(nodeSelectorTerms):: if std.type(nodeSelectorTerms) == "array" then __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: nodeSelectorTerms}) else __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: [nodeSelectorTerms]}), nodeSelectorTermsType:: hidden.core.v1.nodeSelectorTerm, }, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.nodeSelector, }, nodeAffinityType:: hidden.core.v1.nodeAffinity, // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)). podAffinity:: { local __podAffinityMixin(podAffinity) = __affinityMixin({podAffinity+: podAffinity}), mixinInstance(podAffinity):: __podAffinityMixin(podAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAffinityType:: hidden.core.v1.podAffinity, // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)). podAntiAffinity:: { local __podAntiAffinityMixin(podAntiAffinity) = __affinityMixin({podAntiAffinity+: podAntiAffinity}), mixinInstance(podAntiAffinity):: __podAntiAffinityMixin(podAntiAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAntiAffinityType:: hidden.core.v1.podAntiAffinity, }, affinityType:: hidden.core.v1.affinity, // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted. automountServiceAccountToken(automountServiceAccountToken):: __specMixin({automountServiceAccountToken: automountServiceAccountToken}), // List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated. containers(containers):: if std.type(containers) == "array" then __specMixin({containers+: containers}) else __specMixin({containers+: [containers]}), containersType:: hidden.core.v1.container, // Set DNS policy for containers within the pod. One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. Defaults to "ClusterFirst". To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. dnsPolicy(dnsPolicy):: __specMixin({dnsPolicy: dnsPolicy}), // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts file if specified. This is only valid for non-hostNetwork pods. hostAliases(hostAliases):: if std.type(hostAliases) == "array" then __specMixin({hostAliases+: hostAliases}) else __specMixin({hostAliases+: [hostAliases]}), hostAliasesType:: hidden.core.v1.hostAlias, // Use the host's ipc namespace. Optional: Default to false. hostIpc(hostIpc):: __specMixin({hostIPC: hostIpc}), // Host networking requested for this pod. Use the host's network namespace. If this option is set, the ports that will be used must be specified. Default to false. hostNetwork(hostNetwork):: __specMixin({hostNetwork: hostNetwork}), // Use the host's pid namespace. Optional: Default to false. hostPid(hostPid):: __specMixin({hostPID: hostPid}), // Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value. hostname(hostname):: __specMixin({hostname: hostname}), // 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. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod imagePullSecrets(imagePullSecrets):: if std.type(imagePullSecrets) == "array" then __specMixin({imagePullSecrets+: imagePullSecrets}) else __specMixin({imagePullSecrets+: [imagePullSecrets]}), imagePullSecretsType:: hidden.core.v1.localObjectReference, // List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ initContainers(initContainers):: if std.type(initContainers) == "array" then __specMixin({initContainers+: initContainers}) else __specMixin({initContainers+: [initContainers]}), initContainersType:: hidden.core.v1.container, // NodeName is a request to schedule this pod onto a specific node. If it is non-empty, the scheduler simply schedules this pod onto that node, assuming that it fits resource requirements. nodeName(nodeName):: __specMixin({nodeName: nodeName}), // NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ nodeSelector(nodeSelector):: __specMixin({nodeSelector+: nodeSelector}), // Restart policy for all containers within the pod. One of Always, OnFailure, Never. Default to Always. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy restartPolicy(restartPolicy):: __specMixin({restartPolicy: restartPolicy}), // If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler. schedulerName(schedulerName):: __specMixin({schedulerName: schedulerName}), // SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field. securityContext:: { local __securityContextMixin(securityContext) = __specMixin({securityContext+: securityContext}), mixinInstance(securityContext):: __securityContextMixin(securityContext), // A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod: // // 1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw---- // // If unset, the Kubelet will not modify the ownership and permissions of any volume. fsGroup(fsGroup):: __securityContextMixin({fsGroup: fsGroup}), // Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsNonRoot(runAsNonRoot):: __securityContextMixin({runAsNonRoot: runAsNonRoot}), // The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. runAsUser(runAsUser):: __securityContextMixin({runAsUser: runAsUser}), // The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = __securityContextMixin({seLinuxOptions+: seLinuxOptions}), mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, // A list of groups applied to the first process run in each container, in addition to the container's primary GID. If unspecified, no groups will be added to any container. supplementalGroups(supplementalGroups):: if std.type(supplementalGroups) == "array" then __securityContextMixin({supplementalGroups+: supplementalGroups}) else __securityContextMixin({supplementalGroups+: [supplementalGroups]}), }, securityContextType:: hidden.core.v1.podSecurityContext, // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead. serviceAccount(serviceAccount):: __specMixin({serviceAccount: serviceAccount}), // ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ serviceAccountName(serviceAccountName):: __specMixin({serviceAccountName: serviceAccountName}), // If specified, the fully qualified Pod hostname will be "...svc.". If not specified, the pod will not have a domainname at all. subdomain(subdomain):: __specMixin({subdomain: subdomain}), // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds. terminationGracePeriodSeconds(terminationGracePeriodSeconds):: __specMixin({terminationGracePeriodSeconds: terminationGracePeriodSeconds}), // If specified, the pod's tolerations. tolerations(tolerations):: if std.type(tolerations) == "array" then __specMixin({tolerations+: tolerations}) else __specMixin({tolerations+: [tolerations]}), tolerationsType:: hidden.core.v1.toleration, // List of volumes that can be mounted by containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes volumes(volumes):: if std.type(volumes) == "array" then __specMixin({volumes+: volumes}) else __specMixin({volumes+: [volumes]}), volumesType:: hidden.core.v1.volume, }, specType:: hidden.core.v1.podSpec, }, templateType:: hidden.core.v1.podTemplateSpec, // updateStrategy indicates the StatefulSetUpdateStrategy that will be employed to update Pods in the StatefulSet when a revision is made to Template. updateStrategy:: { local __updateStrategyMixin(updateStrategy) = __specMixin({updateStrategy+: updateStrategy}), mixinInstance(updateStrategy):: __updateStrategyMixin(updateStrategy), // RollingUpdate is used to communicate parameters when Type is RollingUpdateStatefulSetStrategyType. rollingUpdate:: { local __rollingUpdateMixin(rollingUpdate) = __updateStrategyMixin({rollingUpdate+: rollingUpdate}), mixinInstance(rollingUpdate):: __rollingUpdateMixin(rollingUpdate), // Partition indicates the ordinal at which the StatefulSet should be partitioned. partition(partition):: __rollingUpdateMixin({partition: partition}), }, rollingUpdateType:: hidden.apps.v1beta1.rollingUpdateStatefulSetStrategy, // Type indicates the type of the StatefulSetUpdateStrategy. type(type):: __updateStrategyMixin({type: type}), }, updateStrategyType:: hidden.apps.v1beta1.statefulSetUpdateStrategy, // volumeClaimTemplates is a list of claims that pods are allowed to reference. The StatefulSet controller is responsible for mapping network identities to claims in a way that maintains the identity of a pod. Every claim in this list must have at least one matching (by name) volumeMount in one container in the template. A claim in this list takes precedence over any volumes in the template, with the same name. volumeClaimTemplates(volumeClaimTemplates):: if std.type(volumeClaimTemplates) == "array" then __specMixin({volumeClaimTemplates+: volumeClaimTemplates}) else __specMixin({volumeClaimTemplates+: [volumeClaimTemplates]}), volumeClaimTemplatesType:: hidden.core.v1.persistentVolumeClaim, }, specType:: hidden.apps.v1beta1.statefulSetSpec, }, }, // StatefulSetList is a collection of StatefulSets. statefulSetList:: { local kind = {kind: "StatefulSetList"}, new():: apiVersion + kind, // items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.apps.v1beta1.statefulSet, mixin:: { }, }, }, }, authentication:: { v1:: { local apiVersion = {apiVersion: "authentication.k8s.io/v1"}, // TokenReview attempts to authenticate a token to a known user. Note: TokenReview requests may be cached by the webhook token authenticator plugin in the kube-apiserver. tokenReview:: { local kind = {kind: "TokenReview"}, new():: apiVersion + kind, mixin:: { // metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Spec holds information about the request being evaluated spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // Token is the opaque bearer token. token(token):: __specMixin({token: token}), }, specType:: hidden.authentication.v1.tokenReviewSpec, }, }, }, v1beta1:: { local apiVersion = {apiVersion: "authentication.k8s.io/v1beta1"}, // TokenReview attempts to authenticate a token to a known user. Note: TokenReview requests may be cached by the webhook token authenticator plugin in the kube-apiserver. tokenReview:: { local kind = {kind: "TokenReview"}, new():: apiVersion + kind, mixin:: { // metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Spec holds information about the request being evaluated spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // Token is the opaque bearer token. token(token):: __specMixin({token: token}), }, specType:: hidden.authentication.v1beta1.tokenReviewSpec, }, }, }, }, authorization:: { v1:: { local apiVersion = {apiVersion: "authorization.k8s.io/v1"}, // LocalSubjectAccessReview checks whether or not a user or group can perform an action in a given namespace. Having a namespace scoped resource makes it much easier to grant namespace scoped policy that includes permissions checking. localSubjectAccessReview:: { local kind = {kind: "LocalSubjectAccessReview"}, new():: apiVersion + kind, mixin:: { // metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Spec holds information about the request being evaluated. spec.namespace must be equal to the namespace you made the request against. If empty, it is defaulted. spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // Extra corresponds to the user.Info.GetExtra() method from the authenticator. Since that is input to the authorizer it needs a reflection here. extra(extra):: __specMixin({extra+: extra}), // Groups is the groups you're testing for. groups(groups):: if std.type(groups) == "array" then __specMixin({groups+: groups}) else __specMixin({groups+: [groups]}), // NonResourceAttributes describes information for a non-resource access request nonResourceAttributes:: { local __nonResourceAttributesMixin(nonResourceAttributes) = __specMixin({nonResourceAttributes+: nonResourceAttributes}), mixinInstance(nonResourceAttributes):: __nonResourceAttributesMixin(nonResourceAttributes), // Path is the URL path of the request path(path):: __nonResourceAttributesMixin({path: path}), // Verb is the standard HTTP verb verb(verb):: __nonResourceAttributesMixin({verb: verb}), }, nonResourceAttributesType:: hidden.authorization.v1.nonResourceAttributes, // ResourceAuthorizationAttributes describes information for a resource access request resourceAttributes:: { local __resourceAttributesMixin(resourceAttributes) = __specMixin({resourceAttributes+: resourceAttributes}), mixinInstance(resourceAttributes):: __resourceAttributesMixin(resourceAttributes), // Group is the API Group of the Resource. "*" means all. group(group):: __resourceAttributesMixin({group: group}), // Name is the name of the resource being requested for a "get" or deleted for a "delete". "" (empty) means all. name(name):: __resourceAttributesMixin({name: name}), // Namespace is the namespace of the action being requested. Currently, there is no distinction between no namespace and all namespaces "" (empty) is defaulted for LocalSubjectAccessReviews "" (empty) is empty for cluster-scoped resources "" (empty) means "all" for namespace scoped resources from a SubjectAccessReview or SelfSubjectAccessReview namespace(namespace):: __resourceAttributesMixin({namespace: namespace}), // Resource is one of the existing resource types. "*" means all. resource(resource):: __resourceAttributesMixin({resource: resource}), // Subresource is one of the existing resource types. "" means none. subresource(subresource):: __resourceAttributesMixin({subresource: subresource}), // Verb is a kubernetes resource API verb, like: get, list, watch, create, update, delete, proxy. "*" means all. verb(verb):: __resourceAttributesMixin({verb: verb}), // Version is the API Version of the Resource. "*" means all. version(version):: __resourceAttributesMixin({version: version}), }, resourceAttributesType:: hidden.authorization.v1.resourceAttributes, // User is the user you're testing for. If you specify "User" but not "Groups", then is it interpreted as "What if User were not a member of any groups user(user):: __specMixin({user: user}), }, specType:: hidden.authorization.v1.subjectAccessReviewSpec, }, }, // SelfSubjectAccessReview checks whether or the current user can perform an action. Not filling in a spec.namespace means "in all namespaces". Self is a special case, because users should always be able to check whether they can perform an action selfSubjectAccessReview:: { local kind = {kind: "SelfSubjectAccessReview"}, new():: apiVersion + kind, mixin:: { // metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Spec holds information about the request being evaluated. user and groups must be empty spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // NonResourceAttributes describes information for a non-resource access request nonResourceAttributes:: { local __nonResourceAttributesMixin(nonResourceAttributes) = __specMixin({nonResourceAttributes+: nonResourceAttributes}), mixinInstance(nonResourceAttributes):: __nonResourceAttributesMixin(nonResourceAttributes), // Path is the URL path of the request path(path):: __nonResourceAttributesMixin({path: path}), // Verb is the standard HTTP verb verb(verb):: __nonResourceAttributesMixin({verb: verb}), }, nonResourceAttributesType:: hidden.authorization.v1.nonResourceAttributes, // ResourceAuthorizationAttributes describes information for a resource access request resourceAttributes:: { local __resourceAttributesMixin(resourceAttributes) = __specMixin({resourceAttributes+: resourceAttributes}), mixinInstance(resourceAttributes):: __resourceAttributesMixin(resourceAttributes), // Group is the API Group of the Resource. "*" means all. group(group):: __resourceAttributesMixin({group: group}), // Name is the name of the resource being requested for a "get" or deleted for a "delete". "" (empty) means all. name(name):: __resourceAttributesMixin({name: name}), // Namespace is the namespace of the action being requested. Currently, there is no distinction between no namespace and all namespaces "" (empty) is defaulted for LocalSubjectAccessReviews "" (empty) is empty for cluster-scoped resources "" (empty) means "all" for namespace scoped resources from a SubjectAccessReview or SelfSubjectAccessReview namespace(namespace):: __resourceAttributesMixin({namespace: namespace}), // Resource is one of the existing resource types. "*" means all. resource(resource):: __resourceAttributesMixin({resource: resource}), // Subresource is one of the existing resource types. "" means none. subresource(subresource):: __resourceAttributesMixin({subresource: subresource}), // Verb is a kubernetes resource API verb, like: get, list, watch, create, update, delete, proxy. "*" means all. verb(verb):: __resourceAttributesMixin({verb: verb}), // Version is the API Version of the Resource. "*" means all. version(version):: __resourceAttributesMixin({version: version}), }, resourceAttributesType:: hidden.authorization.v1.resourceAttributes, }, specType:: hidden.authorization.v1.selfSubjectAccessReviewSpec, }, }, // SubjectAccessReview checks whether or not a user or group can perform an action. subjectAccessReview:: { local kind = {kind: "SubjectAccessReview"}, new():: apiVersion + kind, mixin:: { // metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Spec holds information about the request being evaluated spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // Extra corresponds to the user.Info.GetExtra() method from the authenticator. Since that is input to the authorizer it needs a reflection here. extra(extra):: __specMixin({extra+: extra}), // Groups is the groups you're testing for. groups(groups):: if std.type(groups) == "array" then __specMixin({groups+: groups}) else __specMixin({groups+: [groups]}), // NonResourceAttributes describes information for a non-resource access request nonResourceAttributes:: { local __nonResourceAttributesMixin(nonResourceAttributes) = __specMixin({nonResourceAttributes+: nonResourceAttributes}), mixinInstance(nonResourceAttributes):: __nonResourceAttributesMixin(nonResourceAttributes), // Path is the URL path of the request path(path):: __nonResourceAttributesMixin({path: path}), // Verb is the standard HTTP verb verb(verb):: __nonResourceAttributesMixin({verb: verb}), }, nonResourceAttributesType:: hidden.authorization.v1.nonResourceAttributes, // ResourceAuthorizationAttributes describes information for a resource access request resourceAttributes:: { local __resourceAttributesMixin(resourceAttributes) = __specMixin({resourceAttributes+: resourceAttributes}), mixinInstance(resourceAttributes):: __resourceAttributesMixin(resourceAttributes), // Group is the API Group of the Resource. "*" means all. group(group):: __resourceAttributesMixin({group: group}), // Name is the name of the resource being requested for a "get" or deleted for a "delete". "" (empty) means all. name(name):: __resourceAttributesMixin({name: name}), // Namespace is the namespace of the action being requested. Currently, there is no distinction between no namespace and all namespaces "" (empty) is defaulted for LocalSubjectAccessReviews "" (empty) is empty for cluster-scoped resources "" (empty) means "all" for namespace scoped resources from a SubjectAccessReview or SelfSubjectAccessReview namespace(namespace):: __resourceAttributesMixin({namespace: namespace}), // Resource is one of the existing resource types. "*" means all. resource(resource):: __resourceAttributesMixin({resource: resource}), // Subresource is one of the existing resource types. "" means none. subresource(subresource):: __resourceAttributesMixin({subresource: subresource}), // Verb is a kubernetes resource API verb, like: get, list, watch, create, update, delete, proxy. "*" means all. verb(verb):: __resourceAttributesMixin({verb: verb}), // Version is the API Version of the Resource. "*" means all. version(version):: __resourceAttributesMixin({version: version}), }, resourceAttributesType:: hidden.authorization.v1.resourceAttributes, // User is the user you're testing for. If you specify "User" but not "Groups", then is it interpreted as "What if User were not a member of any groups user(user):: __specMixin({user: user}), }, specType:: hidden.authorization.v1.subjectAccessReviewSpec, }, }, }, v1beta1:: { local apiVersion = {apiVersion: "authorization.k8s.io/v1beta1"}, // LocalSubjectAccessReview checks whether or not a user or group can perform an action in a given namespace. Having a namespace scoped resource makes it much easier to grant namespace scoped policy that includes permissions checking. localSubjectAccessReview:: { local kind = {kind: "LocalSubjectAccessReview"}, new():: apiVersion + kind, mixin:: { // metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Spec holds information about the request being evaluated. spec.namespace must be equal to the namespace you made the request against. If empty, it is defaulted. spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // Extra corresponds to the user.Info.GetExtra() method from the authenticator. Since that is input to the authorizer it needs a reflection here. extra(extra):: __specMixin({extra+: extra}), // Groups is the groups you're testing for. group(group):: if std.type(group) == "array" then __specMixin({group+: group}) else __specMixin({group+: [group]}), // NonResourceAttributes describes information for a non-resource access request nonResourceAttributes:: { local __nonResourceAttributesMixin(nonResourceAttributes) = __specMixin({nonResourceAttributes+: nonResourceAttributes}), mixinInstance(nonResourceAttributes):: __nonResourceAttributesMixin(nonResourceAttributes), // Path is the URL path of the request path(path):: __nonResourceAttributesMixin({path: path}), // Verb is the standard HTTP verb verb(verb):: __nonResourceAttributesMixin({verb: verb}), }, nonResourceAttributesType:: hidden.authorization.v1beta1.nonResourceAttributes, // ResourceAuthorizationAttributes describes information for a resource access request resourceAttributes:: { local __resourceAttributesMixin(resourceAttributes) = __specMixin({resourceAttributes+: resourceAttributes}), mixinInstance(resourceAttributes):: __resourceAttributesMixin(resourceAttributes), // Group is the API Group of the Resource. "*" means all. group(group):: __resourceAttributesMixin({group: group}), // Name is the name of the resource being requested for a "get" or deleted for a "delete". "" (empty) means all. name(name):: __resourceAttributesMixin({name: name}), // Namespace is the namespace of the action being requested. Currently, there is no distinction between no namespace and all namespaces "" (empty) is defaulted for LocalSubjectAccessReviews "" (empty) is empty for cluster-scoped resources "" (empty) means "all" for namespace scoped resources from a SubjectAccessReview or SelfSubjectAccessReview namespace(namespace):: __resourceAttributesMixin({namespace: namespace}), // Resource is one of the existing resource types. "*" means all. resource(resource):: __resourceAttributesMixin({resource: resource}), // Subresource is one of the existing resource types. "" means none. subresource(subresource):: __resourceAttributesMixin({subresource: subresource}), // Verb is a kubernetes resource API verb, like: get, list, watch, create, update, delete, proxy. "*" means all. verb(verb):: __resourceAttributesMixin({verb: verb}), // Version is the API Version of the Resource. "*" means all. version(version):: __resourceAttributesMixin({version: version}), }, resourceAttributesType:: hidden.authorization.v1beta1.resourceAttributes, // User is the user you're testing for. If you specify "User" but not "Group", then is it interpreted as "What if User were not a member of any groups user(user):: __specMixin({user: user}), }, specType:: hidden.authorization.v1beta1.subjectAccessReviewSpec, }, }, // SelfSubjectAccessReview checks whether or the current user can perform an action. Not filling in a spec.namespace means "in all namespaces". Self is a special case, because users should always be able to check whether they can perform an action selfSubjectAccessReview:: { local kind = {kind: "SelfSubjectAccessReview"}, new():: apiVersion + kind, mixin:: { // metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Spec holds information about the request being evaluated. user and groups must be empty spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // NonResourceAttributes describes information for a non-resource access request nonResourceAttributes:: { local __nonResourceAttributesMixin(nonResourceAttributes) = __specMixin({nonResourceAttributes+: nonResourceAttributes}), mixinInstance(nonResourceAttributes):: __nonResourceAttributesMixin(nonResourceAttributes), // Path is the URL path of the request path(path):: __nonResourceAttributesMixin({path: path}), // Verb is the standard HTTP verb verb(verb):: __nonResourceAttributesMixin({verb: verb}), }, nonResourceAttributesType:: hidden.authorization.v1beta1.nonResourceAttributes, // ResourceAuthorizationAttributes describes information for a resource access request resourceAttributes:: { local __resourceAttributesMixin(resourceAttributes) = __specMixin({resourceAttributes+: resourceAttributes}), mixinInstance(resourceAttributes):: __resourceAttributesMixin(resourceAttributes), // Group is the API Group of the Resource. "*" means all. group(group):: __resourceAttributesMixin({group: group}), // Name is the name of the resource being requested for a "get" or deleted for a "delete". "" (empty) means all. name(name):: __resourceAttributesMixin({name: name}), // Namespace is the namespace of the action being requested. Currently, there is no distinction between no namespace and all namespaces "" (empty) is defaulted for LocalSubjectAccessReviews "" (empty) is empty for cluster-scoped resources "" (empty) means "all" for namespace scoped resources from a SubjectAccessReview or SelfSubjectAccessReview namespace(namespace):: __resourceAttributesMixin({namespace: namespace}), // Resource is one of the existing resource types. "*" means all. resource(resource):: __resourceAttributesMixin({resource: resource}), // Subresource is one of the existing resource types. "" means none. subresource(subresource):: __resourceAttributesMixin({subresource: subresource}), // Verb is a kubernetes resource API verb, like: get, list, watch, create, update, delete, proxy. "*" means all. verb(verb):: __resourceAttributesMixin({verb: verb}), // Version is the API Version of the Resource. "*" means all. version(version):: __resourceAttributesMixin({version: version}), }, resourceAttributesType:: hidden.authorization.v1beta1.resourceAttributes, }, specType:: hidden.authorization.v1beta1.selfSubjectAccessReviewSpec, }, }, // SubjectAccessReview checks whether or not a user or group can perform an action. subjectAccessReview:: { local kind = {kind: "SubjectAccessReview"}, new():: apiVersion + kind, mixin:: { // metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Spec holds information about the request being evaluated spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // Extra corresponds to the user.Info.GetExtra() method from the authenticator. Since that is input to the authorizer it needs a reflection here. extra(extra):: __specMixin({extra+: extra}), // Groups is the groups you're testing for. group(group):: if std.type(group) == "array" then __specMixin({group+: group}) else __specMixin({group+: [group]}), // NonResourceAttributes describes information for a non-resource access request nonResourceAttributes:: { local __nonResourceAttributesMixin(nonResourceAttributes) = __specMixin({nonResourceAttributes+: nonResourceAttributes}), mixinInstance(nonResourceAttributes):: __nonResourceAttributesMixin(nonResourceAttributes), // Path is the URL path of the request path(path):: __nonResourceAttributesMixin({path: path}), // Verb is the standard HTTP verb verb(verb):: __nonResourceAttributesMixin({verb: verb}), }, nonResourceAttributesType:: hidden.authorization.v1beta1.nonResourceAttributes, // ResourceAuthorizationAttributes describes information for a resource access request resourceAttributes:: { local __resourceAttributesMixin(resourceAttributes) = __specMixin({resourceAttributes+: resourceAttributes}), mixinInstance(resourceAttributes):: __resourceAttributesMixin(resourceAttributes), // Group is the API Group of the Resource. "*" means all. group(group):: __resourceAttributesMixin({group: group}), // Name is the name of the resource being requested for a "get" or deleted for a "delete". "" (empty) means all. name(name):: __resourceAttributesMixin({name: name}), // Namespace is the namespace of the action being requested. Currently, there is no distinction between no namespace and all namespaces "" (empty) is defaulted for LocalSubjectAccessReviews "" (empty) is empty for cluster-scoped resources "" (empty) means "all" for namespace scoped resources from a SubjectAccessReview or SelfSubjectAccessReview namespace(namespace):: __resourceAttributesMixin({namespace: namespace}), // Resource is one of the existing resource types. "*" means all. resource(resource):: __resourceAttributesMixin({resource: resource}), // Subresource is one of the existing resource types. "" means none. subresource(subresource):: __resourceAttributesMixin({subresource: subresource}), // Verb is a kubernetes resource API verb, like: get, list, watch, create, update, delete, proxy. "*" means all. verb(verb):: __resourceAttributesMixin({verb: verb}), // Version is the API Version of the Resource. "*" means all. version(version):: __resourceAttributesMixin({version: version}), }, resourceAttributesType:: hidden.authorization.v1beta1.resourceAttributes, // User is the user you're testing for. If you specify "User" but not "Group", then is it interpreted as "What if User were not a member of any groups user(user):: __specMixin({user: user}), }, specType:: hidden.authorization.v1beta1.subjectAccessReviewSpec, }, }, }, }, autoscaling:: { v1:: { local apiVersion = {apiVersion: "autoscaling/v1"}, // configuration of a horizontal pod autoscaler. horizontalPodAutoscaler:: { local kind = {kind: "HorizontalPodAutoscaler"}, new():: apiVersion + kind, mixin:: { // Standard object metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // behaviour of autoscaler. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // upper limit for the number of pods that can be set by the autoscaler; cannot be smaller than MinReplicas. maxReplicas(maxReplicas):: __specMixin({maxReplicas: maxReplicas}), // lower limit for the number of pods that can be set by the autoscaler, default 1. minReplicas(minReplicas):: __specMixin({minReplicas: minReplicas}), // reference to scaled resource; horizontal pod autoscaler will learn the current resource consumption and will set the desired number of pods by using its Scale subresource. scaleTargetRef:: { local __scaleTargetRefMixin(scaleTargetRef) = __specMixin({scaleTargetRef+: scaleTargetRef}), mixinInstance(scaleTargetRef):: __scaleTargetRefMixin(scaleTargetRef), // Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __scaleTargetRefMixin({name: name}), }, scaleTargetRefType:: hidden.autoscaling.v1.crossVersionObjectReference, // target average CPU utilization (represented as a percentage of requested CPU) over all the pods; if not specified the default autoscaling policy will be used. targetCpuUtilizationPercentage(targetCpuUtilizationPercentage):: __specMixin({targetCPUUtilizationPercentage: targetCpuUtilizationPercentage}), }, specType:: hidden.autoscaling.v1.horizontalPodAutoscalerSpec, }, }, // list of horizontal pod autoscaler objects. horizontalPodAutoscalerList:: { local kind = {kind: "HorizontalPodAutoscalerList"}, new():: apiVersion + kind, // list of horizontal pod autoscaler objects. items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.autoscaling.v1.horizontalPodAutoscaler, mixin:: { }, }, // Scale represents a scaling request for a resource. scale:: { local kind = {kind: "Scale"}, new():: apiVersion + kind, mixin:: { // Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata. metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // defines the behavior of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // desired number of instances for the scaled object. replicas(replicas):: __specMixin({replicas: replicas}), }, specType:: hidden.autoscaling.v1.scaleSpec, }, }, }, v2alpha1:: { local apiVersion = {apiVersion: "autoscaling/v2alpha1"}, // HorizontalPodAutoscaler is the configuration for a horizontal pod autoscaler, which automatically manages the replica count of any resource implementing the scale subresource based on the metrics specified. horizontalPodAutoscaler:: { local kind = {kind: "HorizontalPodAutoscaler"}, new():: apiVersion + kind, mixin:: { // metadata is the standard object metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // spec is the specification for the behaviour of the autoscaler. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // maxReplicas is the upper limit for the number of replicas to which the autoscaler can scale up. It cannot be less that minReplicas. maxReplicas(maxReplicas):: __specMixin({maxReplicas: maxReplicas}), // metrics contains the specifications for which to use to calculate the desired replica count (the maximum replica count across all metrics will be used). The desired replica count is calculated multiplying the ratio between the target value and the current value by the current number of pods. Ergo, metrics used must decrease as the pod count is increased, and vice-versa. See the individual metric source types for more information about how each type of metric must respond. metrics(metrics):: if std.type(metrics) == "array" then __specMixin({metrics+: metrics}) else __specMixin({metrics+: [metrics]}), metricsType:: hidden.autoscaling.v2alpha1.metricSpec, // minReplicas is the lower limit for the number of replicas to which the autoscaler can scale down. It defaults to 1 pod. minReplicas(minReplicas):: __specMixin({minReplicas: minReplicas}), // scaleTargetRef points to the target resource to scale, and is used to the pods for which metrics should be collected, as well as to actually change the replica count. scaleTargetRef:: { local __scaleTargetRefMixin(scaleTargetRef) = __specMixin({scaleTargetRef+: scaleTargetRef}), mixinInstance(scaleTargetRef):: __scaleTargetRefMixin(scaleTargetRef), // Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __scaleTargetRefMixin({name: name}), }, scaleTargetRefType:: hidden.autoscaling.v2alpha1.crossVersionObjectReference, }, specType:: hidden.autoscaling.v2alpha1.horizontalPodAutoscalerSpec, }, }, // HorizontalPodAutoscaler is a list of horizontal pod autoscaler objects. horizontalPodAutoscalerList:: { local kind = {kind: "HorizontalPodAutoscalerList"}, new():: apiVersion + kind, // items is the list of horizontal pod autoscaler objects. items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.autoscaling.v2alpha1.horizontalPodAutoscaler, mixin:: { }, }, }, }, batch:: { v1:: { local apiVersion = {apiVersion: "batch/v1"}, // Job represents the configuration of a single job. job:: { local kind = {kind: "Job"}, new():: apiVersion + kind, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of a job. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // Optional duration in seconds relative to the startTime that the job may be active before the system tries to terminate it; value must be positive integer activeDeadlineSeconds(activeDeadlineSeconds):: __specMixin({activeDeadlineSeconds: activeDeadlineSeconds}), // Specifies the desired number of successfully finished pods the job should be run with. Setting to nil means that the success of any pod signals the success of all pods, and allows parallelism to have any positive value. Setting to 1 means that parallelism is limited to 1 and the success of that pod signals the success of the job. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ completions(completions):: __specMixin({completions: completions}), // manualSelector controls generation of pod labels and pod selectors. Leave `manualSelector` unset unless you are certain what you are doing. When false or unset, the system pick labels unique to this job and appends those labels to the pod template. When true, the user is responsible for picking unique labels and specifying the selector. Failure to pick a unique label may cause this and other jobs to not function correctly. However, You may see `manualSelector=true` in jobs that were created with the old `extensions/v1beta1` API. More info: https://git.k8s.io/community/contributors/design-proposals/selector-generation.md manualSelector(manualSelector):: __specMixin({manualSelector: manualSelector}), // Specifies the maximum desired number of pods the job should run at any given time. The actual number of pods running in steady state will be less than this number when ((.spec.completions - .status.successful) < .spec.parallelism), i.e. when the work left to do is less than max parallelism. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ parallelism(parallelism):: __specMixin({parallelism: parallelism}), // A label query over pods that should match the pod count. Normally, the system sets this field for you. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors selector:: { local __selectorMixin(selector) = __specMixin({selector+: selector}), mixinInstance(selector):: __selectorMixin(selector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __selectorMixin({matchExpressions+: matchExpressions}) else __selectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __selectorMixin({matchLabels+: matchLabels}), }, selectorType:: hidden.meta.v1.labelSelector, // Describes the pod that will be created when executing a job. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ template:: { local __templateMixin(template) = __specMixin({template+: template}), mixinInstance(template):: __templateMixin(template), // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = __templateMixin({metadata+: metadata}), mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = __templateMixin({spec+: spec}), mixinInstance(spec):: __specMixin(spec), // Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer. activeDeadlineSeconds(activeDeadlineSeconds):: __specMixin({activeDeadlineSeconds: activeDeadlineSeconds}), // If specified, the pod's scheduling constraints affinity:: { local __affinityMixin(affinity) = __specMixin({affinity+: affinity}), mixinInstance(affinity):: __affinityMixin(affinity), // Describes node affinity scheduling rules for the pod. nodeAffinity:: { local __nodeAffinityMixin(nodeAffinity) = __affinityMixin({nodeAffinity+: nodeAffinity}), mixinInstance(nodeAffinity):: __nodeAffinityMixin(nodeAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.preferredSchedulingTerm, // If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node. requiredDuringSchedulingIgnoredDuringExecution:: { local __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution) = __nodeAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}), mixinInstance(requiredDuringSchedulingIgnoredDuringExecution):: __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution), // Required. A list of node selector terms. The terms are ORed. nodeSelectorTerms(nodeSelectorTerms):: if std.type(nodeSelectorTerms) == "array" then __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: nodeSelectorTerms}) else __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: [nodeSelectorTerms]}), nodeSelectorTermsType:: hidden.core.v1.nodeSelectorTerm, }, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.nodeSelector, }, nodeAffinityType:: hidden.core.v1.nodeAffinity, // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)). podAffinity:: { local __podAffinityMixin(podAffinity) = __affinityMixin({podAffinity+: podAffinity}), mixinInstance(podAffinity):: __podAffinityMixin(podAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAffinityType:: hidden.core.v1.podAffinity, // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)). podAntiAffinity:: { local __podAntiAffinityMixin(podAntiAffinity) = __affinityMixin({podAntiAffinity+: podAntiAffinity}), mixinInstance(podAntiAffinity):: __podAntiAffinityMixin(podAntiAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAntiAffinityType:: hidden.core.v1.podAntiAffinity, }, affinityType:: hidden.core.v1.affinity, // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted. automountServiceAccountToken(automountServiceAccountToken):: __specMixin({automountServiceAccountToken: automountServiceAccountToken}), // List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated. containers(containers):: if std.type(containers) == "array" then __specMixin({containers+: containers}) else __specMixin({containers+: [containers]}), containersType:: hidden.core.v1.container, // Set DNS policy for containers within the pod. One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. Defaults to "ClusterFirst". To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. dnsPolicy(dnsPolicy):: __specMixin({dnsPolicy: dnsPolicy}), // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts file if specified. This is only valid for non-hostNetwork pods. hostAliases(hostAliases):: if std.type(hostAliases) == "array" then __specMixin({hostAliases+: hostAliases}) else __specMixin({hostAliases+: [hostAliases]}), hostAliasesType:: hidden.core.v1.hostAlias, // Use the host's ipc namespace. Optional: Default to false. hostIpc(hostIpc):: __specMixin({hostIPC: hostIpc}), // Host networking requested for this pod. Use the host's network namespace. If this option is set, the ports that will be used must be specified. Default to false. hostNetwork(hostNetwork):: __specMixin({hostNetwork: hostNetwork}), // Use the host's pid namespace. Optional: Default to false. hostPid(hostPid):: __specMixin({hostPID: hostPid}), // Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value. hostname(hostname):: __specMixin({hostname: hostname}), // 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. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod imagePullSecrets(imagePullSecrets):: if std.type(imagePullSecrets) == "array" then __specMixin({imagePullSecrets+: imagePullSecrets}) else __specMixin({imagePullSecrets+: [imagePullSecrets]}), imagePullSecretsType:: hidden.core.v1.localObjectReference, // List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ initContainers(initContainers):: if std.type(initContainers) == "array" then __specMixin({initContainers+: initContainers}) else __specMixin({initContainers+: [initContainers]}), initContainersType:: hidden.core.v1.container, // NodeName is a request to schedule this pod onto a specific node. If it is non-empty, the scheduler simply schedules this pod onto that node, assuming that it fits resource requirements. nodeName(nodeName):: __specMixin({nodeName: nodeName}), // NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ nodeSelector(nodeSelector):: __specMixin({nodeSelector+: nodeSelector}), // Restart policy for all containers within the pod. One of Always, OnFailure, Never. Default to Always. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy restartPolicy(restartPolicy):: __specMixin({restartPolicy: restartPolicy}), // If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler. schedulerName(schedulerName):: __specMixin({schedulerName: schedulerName}), // SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field. securityContext:: { local __securityContextMixin(securityContext) = __specMixin({securityContext+: securityContext}), mixinInstance(securityContext):: __securityContextMixin(securityContext), // A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod: // // 1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw---- // // If unset, the Kubelet will not modify the ownership and permissions of any volume. fsGroup(fsGroup):: __securityContextMixin({fsGroup: fsGroup}), // Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsNonRoot(runAsNonRoot):: __securityContextMixin({runAsNonRoot: runAsNonRoot}), // The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. runAsUser(runAsUser):: __securityContextMixin({runAsUser: runAsUser}), // The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = __securityContextMixin({seLinuxOptions+: seLinuxOptions}), mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, // A list of groups applied to the first process run in each container, in addition to the container's primary GID. If unspecified, no groups will be added to any container. supplementalGroups(supplementalGroups):: if std.type(supplementalGroups) == "array" then __securityContextMixin({supplementalGroups+: supplementalGroups}) else __securityContextMixin({supplementalGroups+: [supplementalGroups]}), }, securityContextType:: hidden.core.v1.podSecurityContext, // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead. serviceAccount(serviceAccount):: __specMixin({serviceAccount: serviceAccount}), // ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ serviceAccountName(serviceAccountName):: __specMixin({serviceAccountName: serviceAccountName}), // If specified, the fully qualified Pod hostname will be "...svc.". If not specified, the pod will not have a domainname at all. subdomain(subdomain):: __specMixin({subdomain: subdomain}), // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds. terminationGracePeriodSeconds(terminationGracePeriodSeconds):: __specMixin({terminationGracePeriodSeconds: terminationGracePeriodSeconds}), // If specified, the pod's tolerations. tolerations(tolerations):: if std.type(tolerations) == "array" then __specMixin({tolerations+: tolerations}) else __specMixin({tolerations+: [tolerations]}), tolerationsType:: hidden.core.v1.toleration, // List of volumes that can be mounted by containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes volumes(volumes):: if std.type(volumes) == "array" then __specMixin({volumes+: volumes}) else __specMixin({volumes+: [volumes]}), volumesType:: hidden.core.v1.volume, }, specType:: hidden.core.v1.podSpec, }, templateType:: hidden.core.v1.podTemplateSpec, }, specType:: hidden.batch.v1.jobSpec, }, }, // JobList is a collection of jobs. jobList:: { local kind = {kind: "JobList"}, new():: apiVersion + kind, // items is the list of Jobs. items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.batch.v1.job, mixin:: { }, }, }, v2alpha1:: { local apiVersion = {apiVersion: "batch/v2alpha1"}, // CronJob represents the configuration of a single cron job. cronJob:: { local kind = {kind: "CronJob"}, new():: apiVersion + kind, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of a cron job, including the schedule. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // Specifies how to treat concurrent executions of a Job. Defaults to Allow. concurrencyPolicy(concurrencyPolicy):: __specMixin({concurrencyPolicy: concurrencyPolicy}), // The number of failed finished jobs to retain. This is a pointer to distinguish between explicit zero and not specified. failedJobsHistoryLimit(failedJobsHistoryLimit):: __specMixin({failedJobsHistoryLimit: failedJobsHistoryLimit}), // Specifies the job that will be created when executing a CronJob. jobTemplate:: { local __jobTemplateMixin(jobTemplate) = __specMixin({jobTemplate+: jobTemplate}), mixinInstance(jobTemplate):: __jobTemplateMixin(jobTemplate), // Standard object's metadata of the jobs created from this template. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = __jobTemplateMixin({metadata+: metadata}), mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the job. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = __jobTemplateMixin({spec+: spec}), mixinInstance(spec):: __specMixin(spec), // Optional duration in seconds relative to the startTime that the job may be active before the system tries to terminate it; value must be positive integer activeDeadlineSeconds(activeDeadlineSeconds):: __specMixin({activeDeadlineSeconds: activeDeadlineSeconds}), // Specifies the desired number of successfully finished pods the job should be run with. Setting to nil means that the success of any pod signals the success of all pods, and allows parallelism to have any positive value. Setting to 1 means that parallelism is limited to 1 and the success of that pod signals the success of the job. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ completions(completions):: __specMixin({completions: completions}), // manualSelector controls generation of pod labels and pod selectors. Leave `manualSelector` unset unless you are certain what you are doing. When false or unset, the system pick labels unique to this job and appends those labels to the pod template. When true, the user is responsible for picking unique labels and specifying the selector. Failure to pick a unique label may cause this and other jobs to not function correctly. However, You may see `manualSelector=true` in jobs that were created with the old `extensions/v1beta1` API. More info: https://git.k8s.io/community/contributors/design-proposals/selector-generation.md manualSelector(manualSelector):: __specMixin({manualSelector: manualSelector}), // Specifies the maximum desired number of pods the job should run at any given time. The actual number of pods running in steady state will be less than this number when ((.spec.completions - .status.successful) < .spec.parallelism), i.e. when the work left to do is less than max parallelism. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ parallelism(parallelism):: __specMixin({parallelism: parallelism}), // A label query over pods that should match the pod count. Normally, the system sets this field for you. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors selector:: { local __selectorMixin(selector) = __specMixin({selector+: selector}), mixinInstance(selector):: __selectorMixin(selector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __selectorMixin({matchExpressions+: matchExpressions}) else __selectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __selectorMixin({matchLabels+: matchLabels}), }, selectorType:: hidden.meta.v1.labelSelector, // Describes the pod that will be created when executing a job. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ template:: { local __templateMixin(template) = __specMixin({template+: template}), mixinInstance(template):: __templateMixin(template), // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = __templateMixin({metadata+: metadata}), mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = __templateMixin({spec+: spec}), mixinInstance(spec):: __specMixin(spec), // Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer. activeDeadlineSeconds(activeDeadlineSeconds):: __specMixin({activeDeadlineSeconds: activeDeadlineSeconds}), // If specified, the pod's scheduling constraints affinity:: { local __affinityMixin(affinity) = __specMixin({affinity+: affinity}), mixinInstance(affinity):: __affinityMixin(affinity), // Describes node affinity scheduling rules for the pod. nodeAffinity:: { local __nodeAffinityMixin(nodeAffinity) = __affinityMixin({nodeAffinity+: nodeAffinity}), mixinInstance(nodeAffinity):: __nodeAffinityMixin(nodeAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.preferredSchedulingTerm, // If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node. requiredDuringSchedulingIgnoredDuringExecution:: { local __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution) = __nodeAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}), mixinInstance(requiredDuringSchedulingIgnoredDuringExecution):: __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution), // Required. A list of node selector terms. The terms are ORed. nodeSelectorTerms(nodeSelectorTerms):: if std.type(nodeSelectorTerms) == "array" then __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: nodeSelectorTerms}) else __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: [nodeSelectorTerms]}), nodeSelectorTermsType:: hidden.core.v1.nodeSelectorTerm, }, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.nodeSelector, }, nodeAffinityType:: hidden.core.v1.nodeAffinity, // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)). podAffinity:: { local __podAffinityMixin(podAffinity) = __affinityMixin({podAffinity+: podAffinity}), mixinInstance(podAffinity):: __podAffinityMixin(podAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAffinityType:: hidden.core.v1.podAffinity, // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)). podAntiAffinity:: { local __podAntiAffinityMixin(podAntiAffinity) = __affinityMixin({podAntiAffinity+: podAntiAffinity}), mixinInstance(podAntiAffinity):: __podAntiAffinityMixin(podAntiAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAntiAffinityType:: hidden.core.v1.podAntiAffinity, }, affinityType:: hidden.core.v1.affinity, // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted. automountServiceAccountToken(automountServiceAccountToken):: __specMixin({automountServiceAccountToken: automountServiceAccountToken}), // List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated. containers(containers):: if std.type(containers) == "array" then __specMixin({containers+: containers}) else __specMixin({containers+: [containers]}), containersType:: hidden.core.v1.container, // Set DNS policy for containers within the pod. One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. Defaults to "ClusterFirst". To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. dnsPolicy(dnsPolicy):: __specMixin({dnsPolicy: dnsPolicy}), // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts file if specified. This is only valid for non-hostNetwork pods. hostAliases(hostAliases):: if std.type(hostAliases) == "array" then __specMixin({hostAliases+: hostAliases}) else __specMixin({hostAliases+: [hostAliases]}), hostAliasesType:: hidden.core.v1.hostAlias, // Use the host's ipc namespace. Optional: Default to false. hostIpc(hostIpc):: __specMixin({hostIPC: hostIpc}), // Host networking requested for this pod. Use the host's network namespace. If this option is set, the ports that will be used must be specified. Default to false. hostNetwork(hostNetwork):: __specMixin({hostNetwork: hostNetwork}), // Use the host's pid namespace. Optional: Default to false. hostPid(hostPid):: __specMixin({hostPID: hostPid}), // Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value. hostname(hostname):: __specMixin({hostname: hostname}), // 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. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod imagePullSecrets(imagePullSecrets):: if std.type(imagePullSecrets) == "array" then __specMixin({imagePullSecrets+: imagePullSecrets}) else __specMixin({imagePullSecrets+: [imagePullSecrets]}), imagePullSecretsType:: hidden.core.v1.localObjectReference, // List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ initContainers(initContainers):: if std.type(initContainers) == "array" then __specMixin({initContainers+: initContainers}) else __specMixin({initContainers+: [initContainers]}), initContainersType:: hidden.core.v1.container, // NodeName is a request to schedule this pod onto a specific node. If it is non-empty, the scheduler simply schedules this pod onto that node, assuming that it fits resource requirements. nodeName(nodeName):: __specMixin({nodeName: nodeName}), // NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ nodeSelector(nodeSelector):: __specMixin({nodeSelector+: nodeSelector}), // Restart policy for all containers within the pod. One of Always, OnFailure, Never. Default to Always. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy restartPolicy(restartPolicy):: __specMixin({restartPolicy: restartPolicy}), // If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler. schedulerName(schedulerName):: __specMixin({schedulerName: schedulerName}), // SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field. securityContext:: { local __securityContextMixin(securityContext) = __specMixin({securityContext+: securityContext}), mixinInstance(securityContext):: __securityContextMixin(securityContext), // A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod: // // 1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw---- // // If unset, the Kubelet will not modify the ownership and permissions of any volume. fsGroup(fsGroup):: __securityContextMixin({fsGroup: fsGroup}), // Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsNonRoot(runAsNonRoot):: __securityContextMixin({runAsNonRoot: runAsNonRoot}), // The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. runAsUser(runAsUser):: __securityContextMixin({runAsUser: runAsUser}), // The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = __securityContextMixin({seLinuxOptions+: seLinuxOptions}), mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, // A list of groups applied to the first process run in each container, in addition to the container's primary GID. If unspecified, no groups will be added to any container. supplementalGroups(supplementalGroups):: if std.type(supplementalGroups) == "array" then __securityContextMixin({supplementalGroups+: supplementalGroups}) else __securityContextMixin({supplementalGroups+: [supplementalGroups]}), }, securityContextType:: hidden.core.v1.podSecurityContext, // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead. serviceAccount(serviceAccount):: __specMixin({serviceAccount: serviceAccount}), // ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ serviceAccountName(serviceAccountName):: __specMixin({serviceAccountName: serviceAccountName}), // If specified, the fully qualified Pod hostname will be "...svc.". If not specified, the pod will not have a domainname at all. subdomain(subdomain):: __specMixin({subdomain: subdomain}), // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds. terminationGracePeriodSeconds(terminationGracePeriodSeconds):: __specMixin({terminationGracePeriodSeconds: terminationGracePeriodSeconds}), // If specified, the pod's tolerations. tolerations(tolerations):: if std.type(tolerations) == "array" then __specMixin({tolerations+: tolerations}) else __specMixin({tolerations+: [tolerations]}), tolerationsType:: hidden.core.v1.toleration, // List of volumes that can be mounted by containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes volumes(volumes):: if std.type(volumes) == "array" then __specMixin({volumes+: volumes}) else __specMixin({volumes+: [volumes]}), volumesType:: hidden.core.v1.volume, }, specType:: hidden.core.v1.podSpec, }, templateType:: hidden.core.v1.podTemplateSpec, }, specType:: hidden.batch.v1.jobSpec, }, jobTemplateType:: hidden.batch.v2alpha1.jobTemplateSpec, // The schedule in Cron format, see https://en.wikipedia.org/wiki/Cron. schedule(schedule):: __specMixin({schedule: schedule}), // Optional deadline in seconds for starting the job if it misses scheduled time for any reason. Missed jobs executions will be counted as failed ones. startingDeadlineSeconds(startingDeadlineSeconds):: __specMixin({startingDeadlineSeconds: startingDeadlineSeconds}), // The number of successful finished jobs to retain. This is a pointer to distinguish between explicit zero and not specified. successfulJobsHistoryLimit(successfulJobsHistoryLimit):: __specMixin({successfulJobsHistoryLimit: successfulJobsHistoryLimit}), // This flag tells the controller to suspend subsequent executions, it does not apply to already started executions. Defaults to false. suspend(suspend):: __specMixin({suspend: suspend}), }, specType:: hidden.batch.v2alpha1.cronJobSpec, }, }, // CronJobList is a collection of cron jobs. cronJobList:: { local kind = {kind: "CronJobList"}, new():: apiVersion + kind, // items is the list of CronJobs. items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.batch.v2alpha1.cronJob, mixin:: { }, }, }, }, certificates:: { v1beta1:: { local apiVersion = {apiVersion: "certificates.k8s.io/v1beta1"}, // Describes a certificate signing request certificateSigningRequest:: { local kind = {kind: "CertificateSigningRequest"}, new():: apiVersion + kind, mixin:: { // metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // The certificate request itself and any additional information. spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // Extra information about the requesting user. See user.Info interface for details. extra(extra):: __specMixin({extra+: extra}), // Group information about the requesting user. See user.Info interface for details. groups(groups):: if std.type(groups) == "array" then __specMixin({groups+: groups}) else __specMixin({groups+: [groups]}), // Base64-encoded PKCS#10 CSR data request(request):: __specMixin({request: request}), // UID information about the requesting user. See user.Info interface for details. uid(uid):: __specMixin({uid: uid}), // allowedUsages specifies a set of usage contexts the key will be valid for. See: https://tools.ietf.org/html/rfc5280#section-4.2.1.3 // https://tools.ietf.org/html/rfc5280#section-4.2.1.12 usages(usages):: if std.type(usages) == "array" then __specMixin({usages+: usages}) else __specMixin({usages+: [usages]}), // Information about the requesting user. See user.Info interface for details. username(username):: __specMixin({username: username}), }, specType:: hidden.certificates.v1beta1.certificateSigningRequestSpec, }, }, // certificateSigningRequestList:: { local kind = {kind: "CertificateSigningRequestList"}, new():: apiVersion + kind, // items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.certificates.v1beta1.certificateSigningRequest, mixin:: { }, }, }, }, core:: { v1:: { local apiVersion = {apiVersion: "v1"}, // Binding ties one object to another; for example, a pod is bound to a node by a scheduler. Deprecated in 1.7, please use the bindings subresource of pods instead. binding:: { local kind = {kind: "Binding"}, new():: apiVersion + kind, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // The target object that you want to bind to the standard object. target:: { local __targetMixin(target) = {target+: target}, mixinInstance(target):: __targetMixin(target), // If referring to a piece of an object instead of an entire object, this string should contain a valid JSON/Go field access statement, such as desiredState.manifest.containers[2]. For example, if the object reference is to a container within a pod, this would take on a value like: "spec.containers{name}" (where "name" refers to the name of the container that triggered the event) or if no container name is specified "spec.containers[2]" (container with index 2 in this pod). This syntax is chosen only to have some well-defined way of referencing a part of an object. fieldPath(fieldPath):: __targetMixin({fieldPath: fieldPath}), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __targetMixin({name: name}), // Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ namespace(namespace):: __targetMixin({namespace: namespace}), // Specific resourceVersion to which this reference is made, if any. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency resourceVersion(resourceVersion):: __targetMixin({resourceVersion: resourceVersion}), // UID of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids uid(uid):: __targetMixin({uid: uid}), }, targetType:: hidden.core.v1.objectReference, }, }, // ComponentStatus (and ComponentStatusList) holds the cluster validation info. componentStatus:: { local kind = {kind: "ComponentStatus"}, new():: apiVersion + kind, // List of component conditions observed conditions(conditions):: if std.type(conditions) == "array" then {conditions+: conditions} else {conditions+: [conditions]}, conditionsType:: hidden.core.v1.componentCondition, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, }, }, // Status of all the conditions for the component as a list of ComponentStatus objects. componentStatusList:: { local kind = {kind: "ComponentStatusList"}, new():: apiVersion + kind, // List of ComponentStatus objects. items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.core.v1.componentStatus, mixin:: { }, }, // ConfigMap holds configuration data for pods to consume. configMap:: { local kind = {kind: "ConfigMap"}, new():: apiVersion + kind, // Data contains the configuration data. Each key must consist of alphanumeric characters, '-', '_' or '.'. data(data):: {data+: data}, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, }, }, // ConfigMapList is a resource containing a list of ConfigMap objects. configMapList:: { local kind = {kind: "ConfigMapList"}, new():: apiVersion + kind, // Items is the list of ConfigMaps. items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.core.v1.configMap, mixin:: { }, }, // Endpoints is a collection of endpoints that implement the actual service. Example: // Name: "mysvc", // Subsets: [ // { // Addresses: [{"ip": "10.10.1.1"}, {"ip": "10.10.2.2"}], // Ports: [{"name": "a", "port": 8675}, {"name": "b", "port": 309}] // }, // { // Addresses: [{"ip": "10.10.3.3"}], // Ports: [{"name": "a", "port": 93}, {"name": "b", "port": 76}] // }, // ] endpoints:: { local kind = {kind: "Endpoints"}, new():: apiVersion + kind, // The set of all endpoints is the union of all subsets. Addresses are placed into subsets according to the IPs they share. A single address with multiple ports, some of which are ready and some of which are not (because they come from different containers) will result in the address being displayed in different subsets for the different ports. No address will appear in both Addresses and NotReadyAddresses in the same subset. Sets of addresses and ports that comprise a service. subsets(subsets):: if std.type(subsets) == "array" then {subsets+: subsets} else {subsets+: [subsets]}, subsetsType:: hidden.core.v1.endpointSubset, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, }, }, // EndpointsList is a list of endpoints. endpointsList:: { local kind = {kind: "EndpointsList"}, new():: apiVersion + kind, // List of endpoints. items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.core.v1.endpoints, mixin:: { }, }, // Event is a report of an event somewhere in the cluster. event:: { local kind = {kind: "Event"}, new():: apiVersion + kind, // The number of times this event has occurred. count(count):: {count: count}, // A human-readable description of the status of this operation. message(message):: {message: message}, // This should be a short, machine understandable string that gives the reason for the transition into the object's current status. reason(reason):: {reason: reason}, // Type of this event (Normal, Warning), new types could be added in the future type(type):: {type: type}, mixin:: { // The time at which the event was first recorded. (Time of server receipt is in TypeMeta.) firstTimestamp:: { local __firstTimestampMixin(firstTimestamp) = {firstTimestamp+: firstTimestamp}, mixinInstance(firstTimestamp):: __firstTimestampMixin(firstTimestamp), }, firstTimestampType:: hidden.meta.v1.time, // The object that this event is about. involvedObject:: { local __involvedObjectMixin(involvedObject) = {involvedObject+: involvedObject}, mixinInstance(involvedObject):: __involvedObjectMixin(involvedObject), // If referring to a piece of an object instead of an entire object, this string should contain a valid JSON/Go field access statement, such as desiredState.manifest.containers[2]. For example, if the object reference is to a container within a pod, this would take on a value like: "spec.containers{name}" (where "name" refers to the name of the container that triggered the event) or if no container name is specified "spec.containers[2]" (container with index 2 in this pod). This syntax is chosen only to have some well-defined way of referencing a part of an object. fieldPath(fieldPath):: __involvedObjectMixin({fieldPath: fieldPath}), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __involvedObjectMixin({name: name}), // Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ namespace(namespace):: __involvedObjectMixin({namespace: namespace}), // Specific resourceVersion to which this reference is made, if any. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency resourceVersion(resourceVersion):: __involvedObjectMixin({resourceVersion: resourceVersion}), // UID of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids uid(uid):: __involvedObjectMixin({uid: uid}), }, involvedObjectType:: hidden.core.v1.objectReference, // The time at which the most recent occurrence of this event was recorded. lastTimestamp:: { local __lastTimestampMixin(lastTimestamp) = {lastTimestamp+: lastTimestamp}, mixinInstance(lastTimestamp):: __lastTimestampMixin(lastTimestamp), }, lastTimestampType:: hidden.meta.v1.time, // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // The component reporting this event. Should be a short machine understandable string. source:: { local __sourceMixin(source) = {source+: source}, mixinInstance(source):: __sourceMixin(source), // Component from which the event is generated. component(component):: __sourceMixin({component: component}), // Node name on which the event is generated. host(host):: __sourceMixin({host: host}), }, sourceType:: hidden.core.v1.eventSource, }, }, // EventList is a list of events. eventList:: { local kind = {kind: "EventList"}, new():: apiVersion + kind, // List of events items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.core.v1.event, mixin:: { }, }, // LimitRange sets resource usage limits for each kind of resource in a Namespace. limitRange:: { local kind = {kind: "LimitRange"}, new():: apiVersion + kind, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Spec defines the limits enforced. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // Limits is the list of LimitRangeItem objects that are enforced. limits(limits):: if std.type(limits) == "array" then __specMixin({limits+: limits}) else __specMixin({limits+: [limits]}), limitsType:: hidden.core.v1.limitRangeItem, }, specType:: hidden.core.v1.limitRangeSpec, }, }, // LimitRangeList is a list of LimitRange items. limitRangeList:: { local kind = {kind: "LimitRangeList"}, new():: apiVersion + kind, // Items is a list of LimitRange objects. More info: https://git.k8s.io/community/contributors/design-proposals/admission_control_limit_range.md items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.core.v1.limitRange, mixin:: { }, }, // Namespace provides a scope for Names. Use of multiple namespaces is optional. namespace:: { local kind = {kind: "Namespace"}, new():: apiVersion + kind, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Spec defines the behavior of the Namespace. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // Finalizers is an opaque list of values that must be empty to permanently remove object from storage. More info: https://git.k8s.io/community/contributors/design-proposals/namespaces.md#finalizers finalizers(finalizers):: if std.type(finalizers) == "array" then __specMixin({finalizers+: finalizers}) else __specMixin({finalizers+: [finalizers]}), }, specType:: hidden.core.v1.namespaceSpec, }, }, // NamespaceList is a list of Namespaces. namespaceList:: { local kind = {kind: "NamespaceList"}, new():: apiVersion + kind, // Items is the list of Namespace objects in the list. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.core.v1.namespace, mixin:: { }, }, // Node is a worker node in Kubernetes. Each node will have a unique identifier in the cache (i.e. in etcd). node:: { local kind = {kind: "Node"}, new():: apiVersion + kind, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Spec defines the behavior of a node. https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // External ID of the node assigned by some machine database (e.g. a cloud provider). Deprecated. externalId(externalId):: __specMixin({externalID: externalId}), // PodCIDR represents the pod IP range assigned to the node. podCidr(podCidr):: __specMixin({podCIDR: podCidr}), // ID of the node assigned by the cloud provider in the format: :// providerId(providerId):: __specMixin({providerID: providerId}), // If specified, the node's taints. taints(taints):: if std.type(taints) == "array" then __specMixin({taints+: taints}) else __specMixin({taints+: [taints]}), taintsType:: hidden.core.v1.taint, // Unschedulable controls node schedulability of new pods. By default, node is schedulable. More info: https://kubernetes.io/docs/concepts/nodes/node/#manual-node-administration unschedulable(unschedulable):: __specMixin({unschedulable: unschedulable}), }, specType:: hidden.core.v1.nodeSpec, }, }, // NodeList is the whole list of all Nodes which have been registered with master. nodeList:: { local kind = {kind: "NodeList"}, new():: apiVersion + kind, // List of nodes items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.core.v1.node, mixin:: { }, }, // PersistentVolume (PV) is a storage resource provisioned by an administrator. It is analogous to a node. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes persistentVolume:: { local kind = {kind: "PersistentVolume"}, new():: apiVersion + kind, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Spec defines a specification of a persistent volume owned by the cluster. Provisioned by an administrator. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistent-volumes spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // AccessModes contains all ways the volume can be mounted. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes accessModes(accessModes):: if std.type(accessModes) == "array" then __specMixin({accessModes+: accessModes}) else __specMixin({accessModes+: [accessModes]}), // AWSElasticBlockStore represents an AWS Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore awsElasticBlockStore:: { local __awsElasticBlockStoreMixin(awsElasticBlockStore) = __specMixin({awsElasticBlockStore+: awsElasticBlockStore}), mixinInstance(awsElasticBlockStore):: __awsElasticBlockStoreMixin(awsElasticBlockStore), // Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore fsType(fsType):: __awsElasticBlockStoreMixin({fsType: fsType}), // The partition in the volume that you want to mount. If omitted, the default is to mount by volume name. Examples: For volume /dev/sda1, you specify the partition as "1". Similarly, the volume partition for /dev/sda is "0" (or you can leave the property empty). partition(partition):: __awsElasticBlockStoreMixin({partition: partition}), // Specify "true" to force and set the ReadOnly property in VolumeMounts to "true". If omitted, the default is "false". More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore readOnly(readOnly):: __awsElasticBlockStoreMixin({readOnly: readOnly}), // Unique ID of the persistent disk resource in AWS (Amazon EBS volume). More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore volumeId(volumeId):: __awsElasticBlockStoreMixin({volumeID: volumeId}), }, awsElasticBlockStoreType:: hidden.core.v1.awsElasticBlockStoreVolumeSource, // AzureDisk represents an Azure Data Disk mount on the host and bind mount to the pod. azureDisk:: { local __azureDiskMixin(azureDisk) = __specMixin({azureDisk+: azureDisk}), mixinInstance(azureDisk):: __azureDiskMixin(azureDisk), // Host Caching mode: None, Read Only, Read Write. cachingMode(cachingMode):: __azureDiskMixin({cachingMode: cachingMode}), // The Name of the data disk in the blob storage diskName(diskName):: __azureDiskMixin({diskName: diskName}), // The URI the data disk in the blob storage diskUri(diskUri):: __azureDiskMixin({diskURI: diskUri}), // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: __azureDiskMixin({fsType: fsType}), // Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: __azureDiskMixin({readOnly: readOnly}), }, azureDiskType:: hidden.core.v1.azureDiskVolumeSource, // AzureFile represents an Azure File Service mount on the host and bind mount to the pod. azureFile:: { local __azureFileMixin(azureFile) = __specMixin({azureFile+: azureFile}), mixinInstance(azureFile):: __azureFileMixin(azureFile), // Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: __azureFileMixin({readOnly: readOnly}), // the name of secret that contains Azure Storage Account Name and Key secretName(secretName):: __azureFileMixin({secretName: secretName}), // Share Name shareName(shareName):: __azureFileMixin({shareName: shareName}), }, azureFileType:: hidden.core.v1.azureFileVolumeSource, // A description of the persistent volume's resources and capacity. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#capacity capacity(capacity):: __specMixin({capacity+: capacity}), // CephFS represents a Ceph FS mount on the host that shares a pod's lifetime cephfs:: { local __cephfsMixin(cephfs) = __specMixin({cephfs+: cephfs}), mixinInstance(cephfs):: __cephfsMixin(cephfs), // Required: Monitors is a collection of Ceph monitors More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it monitors(monitors):: if std.type(monitors) == "array" then __cephfsMixin({monitors+: monitors}) else __cephfsMixin({monitors+: [monitors]}), // Optional: Used as the mounted root, rather than the full Ceph tree, default is / path(path):: __cephfsMixin({path: path}), // Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it readOnly(readOnly):: __cephfsMixin({readOnly: readOnly}), // Optional: SecretFile is the path to key ring for User, default is /etc/ceph/user.secret More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it secretFile(secretFile):: __cephfsMixin({secretFile: secretFile}), // Optional: SecretRef is reference to the authentication secret for User, default is empty. More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it secretRef:: { local __secretRefMixin(secretRef) = __cephfsMixin({secretRef+: secretRef}), mixinInstance(secretRef):: __secretRefMixin(secretRef), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), }, secretRefType:: hidden.core.v1.localObjectReference, // Optional: User is the rados user name, default is admin More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it user(user):: __cephfsMixin({user: user}), }, cephfsType:: hidden.core.v1.cephFsVolumeSource, // Cinder represents a cinder volume attached and mounted on kubelets host machine More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md cinder:: { local __cinderMixin(cinder) = __specMixin({cinder+: cinder}), mixinInstance(cinder):: __cinderMixin(cinder), // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md fsType(fsType):: __cinderMixin({fsType: fsType}), // Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md readOnly(readOnly):: __cinderMixin({readOnly: readOnly}), // volume id used to identify the volume in cinder More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md volumeId(volumeId):: __cinderMixin({volumeID: volumeId}), }, cinderType:: hidden.core.v1.cinderVolumeSource, // ClaimRef is part of a bi-directional binding between PersistentVolume and PersistentVolumeClaim. Expected to be non-nil when bound. claim.VolumeName is the authoritative bind between PV and PVC. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#binding claimRef:: { local __claimRefMixin(claimRef) = __specMixin({claimRef+: claimRef}), mixinInstance(claimRef):: __claimRefMixin(claimRef), // If referring to a piece of an object instead of an entire object, this string should contain a valid JSON/Go field access statement, such as desiredState.manifest.containers[2]. For example, if the object reference is to a container within a pod, this would take on a value like: "spec.containers{name}" (where "name" refers to the name of the container that triggered the event) or if no container name is specified "spec.containers[2]" (container with index 2 in this pod). This syntax is chosen only to have some well-defined way of referencing a part of an object. fieldPath(fieldPath):: __claimRefMixin({fieldPath: fieldPath}), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __claimRefMixin({name: name}), // Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ namespace(namespace):: __claimRefMixin({namespace: namespace}), // Specific resourceVersion to which this reference is made, if any. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency resourceVersion(resourceVersion):: __claimRefMixin({resourceVersion: resourceVersion}), // UID of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids uid(uid):: __claimRefMixin({uid: uid}), }, claimRefType:: hidden.core.v1.objectReference, // FC represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod. fc:: { local __fcMixin(fc) = __specMixin({fc+: fc}), mixinInstance(fc):: __fcMixin(fc), // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: __fcMixin({fsType: fsType}), // Required: FC target lun number lun(lun):: __fcMixin({lun: lun}), // Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: __fcMixin({readOnly: readOnly}), // Required: FC target worldwide names (WWNs) targetWwns(targetWwns):: if std.type(targetWwns) == "array" then __fcMixin({targetWWNs+: targetWwns}) else __fcMixin({targetWWNs+: [targetWwns]}), }, fcType:: hidden.core.v1.fcVolumeSource, // FlexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin. This is an alpha feature and may change in future. flexVolume:: { local __flexVolumeMixin(flexVolume) = __specMixin({flexVolume+: flexVolume}), mixinInstance(flexVolume):: __flexVolumeMixin(flexVolume), // Driver is the name of the driver to use for this volume. driver(driver):: __flexVolumeMixin({driver: driver}), // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". The default filesystem depends on FlexVolume script. fsType(fsType):: __flexVolumeMixin({fsType: fsType}), // Optional: Extra command options if any. options(options):: __flexVolumeMixin({options+: options}), // Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: __flexVolumeMixin({readOnly: readOnly}), // Optional: SecretRef is reference to the secret object containing sensitive information to pass to the plugin scripts. This may be empty if no secret object is specified. If the secret object contains more than one secret, all secrets are passed to the plugin scripts. secretRef:: { local __secretRefMixin(secretRef) = __flexVolumeMixin({secretRef+: secretRef}), mixinInstance(secretRef):: __secretRefMixin(secretRef), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), }, secretRefType:: hidden.core.v1.localObjectReference, }, flexVolumeType:: hidden.core.v1.flexVolumeSource, // 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 flocker:: { local __flockerMixin(flocker) = __specMixin({flocker+: flocker}), mixinInstance(flocker):: __flockerMixin(flocker), // Name of the dataset stored as metadata -> name on the dataset for Flocker should be considered as deprecated datasetName(datasetName):: __flockerMixin({datasetName: datasetName}), // UUID of the dataset. This is unique identifier of a Flocker dataset datasetUuid(datasetUuid):: __flockerMixin({datasetUUID: datasetUuid}), }, flockerType:: hidden.core.v1.flockerVolumeSource, // GCEPersistentDisk represents a GCE Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Provisioned by an admin. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk gcePersistentDisk:: { local __gcePersistentDiskMixin(gcePersistentDisk) = __specMixin({gcePersistentDisk+: gcePersistentDisk}), mixinInstance(gcePersistentDisk):: __gcePersistentDiskMixin(gcePersistentDisk), // Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk fsType(fsType):: __gcePersistentDiskMixin({fsType: fsType}), // The partition in the volume that you want to mount. If omitted, the default is to mount by volume name. Examples: For volume /dev/sda1, you specify the partition as "1". Similarly, the volume partition for /dev/sda is "0" (or you can leave the property empty). More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk partition(partition):: __gcePersistentDiskMixin({partition: partition}), // Unique name of the PD resource in GCE. Used to identify the disk in GCE. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk pdName(pdName):: __gcePersistentDiskMixin({pdName: pdName}), // ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk readOnly(readOnly):: __gcePersistentDiskMixin({readOnly: readOnly}), }, gcePersistentDiskType:: hidden.core.v1.gcePersistentDiskVolumeSource, // Glusterfs represents a Glusterfs volume that is attached to a host and exposed to the pod. Provisioned by an admin. More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md glusterfs:: { local __glusterfsMixin(glusterfs) = __specMixin({glusterfs+: glusterfs}), mixinInstance(glusterfs):: __glusterfsMixin(glusterfs), // EndpointsName is the endpoint name that details Glusterfs topology. More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod endpoints(endpoints):: __glusterfsMixin({endpoints: endpoints}), // Path is the Glusterfs volume path. More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod path(path):: __glusterfsMixin({path: path}), // ReadOnly here will force the Glusterfs volume to be mounted with read-only permissions. Defaults to false. More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod readOnly(readOnly):: __glusterfsMixin({readOnly: readOnly}), }, glusterfsType:: hidden.core.v1.glusterfsVolumeSource, // HostPath represents a directory on the host. Provisioned by a developer or tester. This is useful for single-node development and testing only! On-host storage is not supported in any way and WILL NOT WORK in a multi-node cluster. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath hostPath:: { local __hostPathMixin(hostPath) = __specMixin({hostPath+: hostPath}), mixinInstance(hostPath):: __hostPathMixin(hostPath), // Path of the directory on the host. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath path(path):: __hostPathMixin({path: path}), }, hostPathType:: hidden.core.v1.hostPathVolumeSource, // ISCSI represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Provisioned by an admin. iscsi:: { local __iscsiMixin(iscsi) = __specMixin({iscsi+: iscsi}), mixinInstance(iscsi):: __iscsiMixin(iscsi), // whether support iSCSI Discovery CHAP authentication chapAuthDiscovery(chapAuthDiscovery):: __iscsiMixin({chapAuthDiscovery: chapAuthDiscovery}), // whether support iSCSI Session CHAP authentication chapAuthSession(chapAuthSession):: __iscsiMixin({chapAuthSession: chapAuthSession}), // Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#iscsi fsType(fsType):: __iscsiMixin({fsType: fsType}), // Target iSCSI Qualified Name. iqn(iqn):: __iscsiMixin({iqn: iqn}), // Optional: Defaults to 'default' (tcp). iSCSI interface name that uses an iSCSI transport. iscsiInterface(iscsiInterface):: __iscsiMixin({iscsiInterface: iscsiInterface}), // iSCSI target lun number. lun(lun):: __iscsiMixin({lun: lun}), // iSCSI target portal List. The portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260). portals(portals):: if std.type(portals) == "array" then __iscsiMixin({portals+: portals}) else __iscsiMixin({portals+: [portals]}), // ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. readOnly(readOnly):: __iscsiMixin({readOnly: readOnly}), // CHAP secret for iSCSI target and initiator authentication secretRef:: { local __secretRefMixin(secretRef) = __iscsiMixin({secretRef+: secretRef}), mixinInstance(secretRef):: __secretRefMixin(secretRef), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), }, secretRefType:: hidden.core.v1.localObjectReference, // iSCSI target portal. The portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260). targetPortal(targetPortal):: __iscsiMixin({targetPortal: targetPortal}), }, iscsiType:: hidden.core.v1.iscsiVolumeSource, // Local represents directly-attached storage with node affinity localStorage:: { local __localStorageMixin(localStorage) = __specMixin({"local"+: localStorage}), mixinInstance(localStorage):: __localStorageMixin(localStorage), // The full path to the volume on the node For alpha, this path must be a directory Once block as a source is supported, then this path can point to a block device path(path):: __localStorageMixin({path: path}), }, localStorageType:: hidden.core.v1.localVolumeSource, // NFS represents an NFS mount on the host. Provisioned by an admin. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs nfs:: { local __nfsMixin(nfs) = __specMixin({nfs+: nfs}), mixinInstance(nfs):: __nfsMixin(nfs), // Path that is exported by the NFS server. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs path(path):: __nfsMixin({path: path}), // ReadOnly here will force the NFS export to be mounted with read-only permissions. Defaults to false. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs readOnly(readOnly):: __nfsMixin({readOnly: readOnly}), // Server is the hostname or IP address of the NFS server. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs server(server):: __nfsMixin({server: server}), }, nfsType:: hidden.core.v1.nfsVolumeSource, // What happens to a persistent volume when released from its claim. Valid options are Retain (default) and Recycle. Recycling must be supported by the volume plugin underlying this persistent volume. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#reclaiming persistentVolumeReclaimPolicy(persistentVolumeReclaimPolicy):: __specMixin({persistentVolumeReclaimPolicy: persistentVolumeReclaimPolicy}), // PhotonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine photonPersistentDisk:: { local __photonPersistentDiskMixin(photonPersistentDisk) = __specMixin({photonPersistentDisk+: photonPersistentDisk}), mixinInstance(photonPersistentDisk):: __photonPersistentDiskMixin(photonPersistentDisk), // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: __photonPersistentDiskMixin({fsType: fsType}), // ID that identifies Photon Controller persistent disk pdId(pdId):: __photonPersistentDiskMixin({pdID: pdId}), }, photonPersistentDiskType:: hidden.core.v1.photonPersistentDiskVolumeSource, // PortworxVolume represents a portworx volume attached and mounted on kubelets host machine portworxVolume:: { local __portworxVolumeMixin(portworxVolume) = __specMixin({portworxVolume+: portworxVolume}), mixinInstance(portworxVolume):: __portworxVolumeMixin(portworxVolume), // FSType represents the filesystem type to mount Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: __portworxVolumeMixin({fsType: fsType}), // Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: __portworxVolumeMixin({readOnly: readOnly}), // VolumeID uniquely identifies a Portworx volume volumeId(volumeId):: __portworxVolumeMixin({volumeID: volumeId}), }, portworxVolumeType:: hidden.core.v1.portworxVolumeSource, // Quobyte represents a Quobyte mount on the host that shares a pod's lifetime quobyte:: { local __quobyteMixin(quobyte) = __specMixin({quobyte+: quobyte}), mixinInstance(quobyte):: __quobyteMixin(quobyte), // Group to map volume access to Default is no group group(group):: __quobyteMixin({group: group}), // ReadOnly here will force the Quobyte volume to be mounted with read-only permissions. Defaults to false. readOnly(readOnly):: __quobyteMixin({readOnly: readOnly}), // Registry represents a single or multiple Quobyte Registry services specified as a string as host:port pair (multiple entries are separated with commas) which acts as the central registry for volumes registry(registry):: __quobyteMixin({registry: registry}), // User to map volume access to Defaults to serivceaccount user user(user):: __quobyteMixin({user: user}), // Volume is a string that references an already created Quobyte volume by name. volume(volume):: __quobyteMixin({volume: volume}), }, quobyteType:: hidden.core.v1.quobyteVolumeSource, // RBD represents a Rados Block Device mount on the host that shares a pod's lifetime. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md rbd:: { local __rbdMixin(rbd) = __specMixin({rbd+: rbd}), mixinInstance(rbd):: __rbdMixin(rbd), // Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#rbd fsType(fsType):: __rbdMixin({fsType: fsType}), // The rados image name. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it image(image):: __rbdMixin({image: image}), // Keyring is the path to key ring for RBDUser. Default is /etc/ceph/keyring. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it keyring(keyring):: __rbdMixin({keyring: keyring}), // A collection of Ceph monitors. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it monitors(monitors):: if std.type(monitors) == "array" then __rbdMixin({monitors+: monitors}) else __rbdMixin({monitors+: [monitors]}), // The rados pool name. Default is rbd. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it pool(pool):: __rbdMixin({pool: pool}), // ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it readOnly(readOnly):: __rbdMixin({readOnly: readOnly}), // SecretRef is name of the authentication secret for RBDUser. If provided overrides keyring. Default is nil. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it secretRef:: { local __secretRefMixin(secretRef) = __rbdMixin({secretRef+: secretRef}), mixinInstance(secretRef):: __secretRefMixin(secretRef), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), }, secretRefType:: hidden.core.v1.localObjectReference, // The rados user name. Default is admin. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it user(user):: __rbdMixin({user: user}), }, rbdType:: hidden.core.v1.rbdVolumeSource, // ScaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes. scaleIo:: { local __scaleIoMixin(scaleIo) = __specMixin({scaleIO+: scaleIo}), mixinInstance(scaleIo):: __scaleIoMixin(scaleIo), // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: __scaleIoMixin({fsType: fsType}), // The host address of the ScaleIO API Gateway. gateway(gateway):: __scaleIoMixin({gateway: gateway}), // The name of the Protection Domain for the configured storage (defaults to "default"). protectionDomain(protectionDomain):: __scaleIoMixin({protectionDomain: protectionDomain}), // Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: __scaleIoMixin({readOnly: readOnly}), // SecretRef references to the secret for ScaleIO user and other sensitive information. If this is not provided, Login operation will fail. secretRef:: { local __secretRefMixin(secretRef) = __scaleIoMixin({secretRef+: secretRef}), mixinInstance(secretRef):: __secretRefMixin(secretRef), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), }, secretRefType:: hidden.core.v1.localObjectReference, // Flag to enable/disable SSL communication with Gateway, default false sslEnabled(sslEnabled):: __scaleIoMixin({sslEnabled: sslEnabled}), // Indicates whether the storage for a volume should be thick or thin (defaults to "thin"). storageMode(storageMode):: __scaleIoMixin({storageMode: storageMode}), // The Storage Pool associated with the protection domain (defaults to "default"). storagePool(storagePool):: __scaleIoMixin({storagePool: storagePool}), // The name of the storage system as configured in ScaleIO. system(system):: __scaleIoMixin({system: system}), // The name of a volume already created in the ScaleIO system that is associated with this volume source. volumeName(volumeName):: __scaleIoMixin({volumeName: volumeName}), }, scaleIoType:: hidden.core.v1.scaleIoVolumeSource, // Name of StorageClass to which this persistent volume belongs. Empty value means that this volume does not belong to any StorageClass. storageClassName(storageClassName):: __specMixin({storageClassName: storageClassName}), // StorageOS represents a StorageOS volume that is attached to the kubelet's host machine and mounted into the pod More info: https://releases.k8s.io/HEAD/examples/volumes/storageos/README.md storageos:: { local __storageosMixin(storageos) = __specMixin({storageos+: storageos}), mixinInstance(storageos):: __storageosMixin(storageos), // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: __storageosMixin({fsType: fsType}), // Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: __storageosMixin({readOnly: readOnly}), // SecretRef specifies the secret to use for obtaining the StorageOS API credentials. If not specified, default values will be attempted. secretRef:: { local __secretRefMixin(secretRef) = __storageosMixin({secretRef+: secretRef}), mixinInstance(secretRef):: __secretRefMixin(secretRef), // If referring to a piece of an object instead of an entire object, this string should contain a valid JSON/Go field access statement, such as desiredState.manifest.containers[2]. For example, if the object reference is to a container within a pod, this would take on a value like: "spec.containers{name}" (where "name" refers to the name of the container that triggered the event) or if no container name is specified "spec.containers[2]" (container with index 2 in this pod). This syntax is chosen only to have some well-defined way of referencing a part of an object. fieldPath(fieldPath):: __secretRefMixin({fieldPath: fieldPath}), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), // Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ namespace(namespace):: __secretRefMixin({namespace: namespace}), // Specific resourceVersion to which this reference is made, if any. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency resourceVersion(resourceVersion):: __secretRefMixin({resourceVersion: resourceVersion}), // UID of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids uid(uid):: __secretRefMixin({uid: uid}), }, secretRefType:: hidden.core.v1.objectReference, // VolumeName is the human-readable name of the StorageOS volume. Volume names are only unique within a namespace. volumeName(volumeName):: __storageosMixin({volumeName: volumeName}), // VolumeNamespace specifies the scope of the volume within StorageOS. If no namespace is specified then the Pod's namespace will be used. This allows the Kubernetes name scoping to be mirrored within StorageOS for tighter integration. Set VolumeName to any name to override the default behaviour. Set to "default" if you are not using namespaces within StorageOS. Namespaces that do not pre-exist within StorageOS will be created. volumeNamespace(volumeNamespace):: __storageosMixin({volumeNamespace: volumeNamespace}), }, storageosType:: hidden.core.v1.storageOSPersistentVolumeSource, // VsphereVolume represents a vSphere volume attached and mounted on kubelets host machine vsphereVolume:: { local __vsphereVolumeMixin(vsphereVolume) = __specMixin({vsphereVolume+: vsphereVolume}), mixinInstance(vsphereVolume):: __vsphereVolumeMixin(vsphereVolume), // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: __vsphereVolumeMixin({fsType: fsType}), // Storage Policy Based Management (SPBM) profile ID associated with the StoragePolicyName. storagePolicyID(storagePolicyID):: __vsphereVolumeMixin({storagePolicyID: storagePolicyID}), // Storage Policy Based Management (SPBM) profile name. storagePolicyName(storagePolicyName):: __vsphereVolumeMixin({storagePolicyName: storagePolicyName}), // Path that identifies vSphere volume vmdk volumePath(volumePath):: __vsphereVolumeMixin({volumePath: volumePath}), }, vsphereVolumeType:: hidden.core.v1.vsphereVirtualDiskVolumeSource, }, specType:: hidden.core.v1.persistentVolumeSpec, }, }, // PersistentVolumeClaim is a user's request for and claim to a persistent volume persistentVolumeClaim:: { local kind = {kind: "PersistentVolumeClaim"}, new():: apiVersion + kind, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Spec defines the desired characteristics of a volume requested by a pod author. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // AccessModes contains the desired access modes the volume should have. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes-1 accessModes(accessModes):: if std.type(accessModes) == "array" then __specMixin({accessModes+: accessModes}) else __specMixin({accessModes+: [accessModes]}), // Resources represents the minimum resources the volume should have. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources resources:: { local __resourcesMixin(resources) = __specMixin({resources+: resources}), mixinInstance(resources):: __resourcesMixin(resources), // Limits describes the maximum amount of compute resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ limits(limits):: __resourcesMixin({limits+: limits}), // Requests describes the minimum amount of compute resources required. If Requests is omitted for a container, it defaults to Limits if that is explicitly specified, otherwise to an implementation-defined value. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ requests(requests):: __resourcesMixin({requests+: requests}), }, resourcesType:: hidden.core.v1.resourceRequirements, // A label query over volumes to consider for binding. selector:: { local __selectorMixin(selector) = __specMixin({selector+: selector}), mixinInstance(selector):: __selectorMixin(selector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __selectorMixin({matchExpressions+: matchExpressions}) else __selectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __selectorMixin({matchLabels+: matchLabels}), }, selectorType:: hidden.meta.v1.labelSelector, // Name of the StorageClass required by the claim. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#class-1 storageClassName(storageClassName):: __specMixin({storageClassName: storageClassName}), // VolumeName is the binding reference to the PersistentVolume backing this claim. volumeName(volumeName):: __specMixin({volumeName: volumeName}), }, specType:: hidden.core.v1.persistentVolumeClaimSpec, }, }, // PersistentVolumeClaimList is a list of PersistentVolumeClaim items. persistentVolumeClaimList:: { local kind = {kind: "PersistentVolumeClaimList"}, new():: apiVersion + kind, // A list of persistent volume claims. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.core.v1.persistentVolumeClaim, mixin:: { }, }, // PersistentVolumeList is a list of PersistentVolume items. persistentVolumeList:: { local kind = {kind: "PersistentVolumeList"}, new():: apiVersion + kind, // List of persistent volumes. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.core.v1.persistentVolume, mixin:: { }, }, // Pod is a collection of containers that can run on a host. This resource is created by clients and scheduled onto hosts. pod:: { local kind = {kind: "Pod"}, new():: apiVersion + kind, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer. activeDeadlineSeconds(activeDeadlineSeconds):: __specMixin({activeDeadlineSeconds: activeDeadlineSeconds}), // If specified, the pod's scheduling constraints affinity:: { local __affinityMixin(affinity) = __specMixin({affinity+: affinity}), mixinInstance(affinity):: __affinityMixin(affinity), // Describes node affinity scheduling rules for the pod. nodeAffinity:: { local __nodeAffinityMixin(nodeAffinity) = __affinityMixin({nodeAffinity+: nodeAffinity}), mixinInstance(nodeAffinity):: __nodeAffinityMixin(nodeAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.preferredSchedulingTerm, // If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node. requiredDuringSchedulingIgnoredDuringExecution:: { local __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution) = __nodeAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}), mixinInstance(requiredDuringSchedulingIgnoredDuringExecution):: __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution), // Required. A list of node selector terms. The terms are ORed. nodeSelectorTerms(nodeSelectorTerms):: if std.type(nodeSelectorTerms) == "array" then __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: nodeSelectorTerms}) else __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: [nodeSelectorTerms]}), nodeSelectorTermsType:: hidden.core.v1.nodeSelectorTerm, }, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.nodeSelector, }, nodeAffinityType:: hidden.core.v1.nodeAffinity, // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)). podAffinity:: { local __podAffinityMixin(podAffinity) = __affinityMixin({podAffinity+: podAffinity}), mixinInstance(podAffinity):: __podAffinityMixin(podAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAffinityType:: hidden.core.v1.podAffinity, // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)). podAntiAffinity:: { local __podAntiAffinityMixin(podAntiAffinity) = __affinityMixin({podAntiAffinity+: podAntiAffinity}), mixinInstance(podAntiAffinity):: __podAntiAffinityMixin(podAntiAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAntiAffinityType:: hidden.core.v1.podAntiAffinity, }, affinityType:: hidden.core.v1.affinity, // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted. automountServiceAccountToken(automountServiceAccountToken):: __specMixin({automountServiceAccountToken: automountServiceAccountToken}), // List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated. containers(containers):: if std.type(containers) == "array" then __specMixin({containers+: containers}) else __specMixin({containers+: [containers]}), containersType:: hidden.core.v1.container, // Set DNS policy for containers within the pod. One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. Defaults to "ClusterFirst". To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. dnsPolicy(dnsPolicy):: __specMixin({dnsPolicy: dnsPolicy}), // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts file if specified. This is only valid for non-hostNetwork pods. hostAliases(hostAliases):: if std.type(hostAliases) == "array" then __specMixin({hostAliases+: hostAliases}) else __specMixin({hostAliases+: [hostAliases]}), hostAliasesType:: hidden.core.v1.hostAlias, // Use the host's ipc namespace. Optional: Default to false. hostIpc(hostIpc):: __specMixin({hostIPC: hostIpc}), // Host networking requested for this pod. Use the host's network namespace. If this option is set, the ports that will be used must be specified. Default to false. hostNetwork(hostNetwork):: __specMixin({hostNetwork: hostNetwork}), // Use the host's pid namespace. Optional: Default to false. hostPid(hostPid):: __specMixin({hostPID: hostPid}), // Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value. hostname(hostname):: __specMixin({hostname: hostname}), // 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. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod imagePullSecrets(imagePullSecrets):: if std.type(imagePullSecrets) == "array" then __specMixin({imagePullSecrets+: imagePullSecrets}) else __specMixin({imagePullSecrets+: [imagePullSecrets]}), imagePullSecretsType:: hidden.core.v1.localObjectReference, // List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ initContainers(initContainers):: if std.type(initContainers) == "array" then __specMixin({initContainers+: initContainers}) else __specMixin({initContainers+: [initContainers]}), initContainersType:: hidden.core.v1.container, // NodeName is a request to schedule this pod onto a specific node. If it is non-empty, the scheduler simply schedules this pod onto that node, assuming that it fits resource requirements. nodeName(nodeName):: __specMixin({nodeName: nodeName}), // NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ nodeSelector(nodeSelector):: __specMixin({nodeSelector+: nodeSelector}), // Restart policy for all containers within the pod. One of Always, OnFailure, Never. Default to Always. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy restartPolicy(restartPolicy):: __specMixin({restartPolicy: restartPolicy}), // If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler. schedulerName(schedulerName):: __specMixin({schedulerName: schedulerName}), // SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field. securityContext:: { local __securityContextMixin(securityContext) = __specMixin({securityContext+: securityContext}), mixinInstance(securityContext):: __securityContextMixin(securityContext), // A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod: // // 1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw---- // // If unset, the Kubelet will not modify the ownership and permissions of any volume. fsGroup(fsGroup):: __securityContextMixin({fsGroup: fsGroup}), // Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsNonRoot(runAsNonRoot):: __securityContextMixin({runAsNonRoot: runAsNonRoot}), // The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. runAsUser(runAsUser):: __securityContextMixin({runAsUser: runAsUser}), // The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = __securityContextMixin({seLinuxOptions+: seLinuxOptions}), mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, // A list of groups applied to the first process run in each container, in addition to the container's primary GID. If unspecified, no groups will be added to any container. supplementalGroups(supplementalGroups):: if std.type(supplementalGroups) == "array" then __securityContextMixin({supplementalGroups+: supplementalGroups}) else __securityContextMixin({supplementalGroups+: [supplementalGroups]}), }, securityContextType:: hidden.core.v1.podSecurityContext, // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead. serviceAccount(serviceAccount):: __specMixin({serviceAccount: serviceAccount}), // ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ serviceAccountName(serviceAccountName):: __specMixin({serviceAccountName: serviceAccountName}), // If specified, the fully qualified Pod hostname will be "...svc.". If not specified, the pod will not have a domainname at all. subdomain(subdomain):: __specMixin({subdomain: subdomain}), // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds. terminationGracePeriodSeconds(terminationGracePeriodSeconds):: __specMixin({terminationGracePeriodSeconds: terminationGracePeriodSeconds}), // If specified, the pod's tolerations. tolerations(tolerations):: if std.type(tolerations) == "array" then __specMixin({tolerations+: tolerations}) else __specMixin({tolerations+: [tolerations]}), tolerationsType:: hidden.core.v1.toleration, // List of volumes that can be mounted by containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes volumes(volumes):: if std.type(volumes) == "array" then __specMixin({volumes+: volumes}) else __specMixin({volumes+: [volumes]}), volumesType:: hidden.core.v1.volume, }, specType:: hidden.core.v1.podSpec, }, }, // PodList is a list of Pods. podList:: { local kind = {kind: "PodList"}, new():: apiVersion + kind, // List of pods. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.core.v1.pod, mixin:: { }, }, // PodTemplate describes a template for creating copies of a predefined pod. podTemplate:: { local kind = {kind: "PodTemplate"}, new():: apiVersion + kind, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Template defines the pods that will be created from this pod template. https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status template:: { local __templateMixin(template) = {template+: template}, mixinInstance(template):: __templateMixin(template), // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = __templateMixin({metadata+: metadata}), mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = __templateMixin({spec+: spec}), mixinInstance(spec):: __specMixin(spec), // Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer. activeDeadlineSeconds(activeDeadlineSeconds):: __specMixin({activeDeadlineSeconds: activeDeadlineSeconds}), // If specified, the pod's scheduling constraints affinity:: { local __affinityMixin(affinity) = __specMixin({affinity+: affinity}), mixinInstance(affinity):: __affinityMixin(affinity), // Describes node affinity scheduling rules for the pod. nodeAffinity:: { local __nodeAffinityMixin(nodeAffinity) = __affinityMixin({nodeAffinity+: nodeAffinity}), mixinInstance(nodeAffinity):: __nodeAffinityMixin(nodeAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.preferredSchedulingTerm, // If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node. requiredDuringSchedulingIgnoredDuringExecution:: { local __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution) = __nodeAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}), mixinInstance(requiredDuringSchedulingIgnoredDuringExecution):: __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution), // Required. A list of node selector terms. The terms are ORed. nodeSelectorTerms(nodeSelectorTerms):: if std.type(nodeSelectorTerms) == "array" then __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: nodeSelectorTerms}) else __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: [nodeSelectorTerms]}), nodeSelectorTermsType:: hidden.core.v1.nodeSelectorTerm, }, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.nodeSelector, }, nodeAffinityType:: hidden.core.v1.nodeAffinity, // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)). podAffinity:: { local __podAffinityMixin(podAffinity) = __affinityMixin({podAffinity+: podAffinity}), mixinInstance(podAffinity):: __podAffinityMixin(podAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAffinityType:: hidden.core.v1.podAffinity, // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)). podAntiAffinity:: { local __podAntiAffinityMixin(podAntiAffinity) = __affinityMixin({podAntiAffinity+: podAntiAffinity}), mixinInstance(podAntiAffinity):: __podAntiAffinityMixin(podAntiAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAntiAffinityType:: hidden.core.v1.podAntiAffinity, }, affinityType:: hidden.core.v1.affinity, // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted. automountServiceAccountToken(automountServiceAccountToken):: __specMixin({automountServiceAccountToken: automountServiceAccountToken}), // List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated. containers(containers):: if std.type(containers) == "array" then __specMixin({containers+: containers}) else __specMixin({containers+: [containers]}), containersType:: hidden.core.v1.container, // Set DNS policy for containers within the pod. One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. Defaults to "ClusterFirst". To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. dnsPolicy(dnsPolicy):: __specMixin({dnsPolicy: dnsPolicy}), // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts file if specified. This is only valid for non-hostNetwork pods. hostAliases(hostAliases):: if std.type(hostAliases) == "array" then __specMixin({hostAliases+: hostAliases}) else __specMixin({hostAliases+: [hostAliases]}), hostAliasesType:: hidden.core.v1.hostAlias, // Use the host's ipc namespace. Optional: Default to false. hostIpc(hostIpc):: __specMixin({hostIPC: hostIpc}), // Host networking requested for this pod. Use the host's network namespace. If this option is set, the ports that will be used must be specified. Default to false. hostNetwork(hostNetwork):: __specMixin({hostNetwork: hostNetwork}), // Use the host's pid namespace. Optional: Default to false. hostPid(hostPid):: __specMixin({hostPID: hostPid}), // Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value. hostname(hostname):: __specMixin({hostname: hostname}), // 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. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod imagePullSecrets(imagePullSecrets):: if std.type(imagePullSecrets) == "array" then __specMixin({imagePullSecrets+: imagePullSecrets}) else __specMixin({imagePullSecrets+: [imagePullSecrets]}), imagePullSecretsType:: hidden.core.v1.localObjectReference, // List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ initContainers(initContainers):: if std.type(initContainers) == "array" then __specMixin({initContainers+: initContainers}) else __specMixin({initContainers+: [initContainers]}), initContainersType:: hidden.core.v1.container, // NodeName is a request to schedule this pod onto a specific node. If it is non-empty, the scheduler simply schedules this pod onto that node, assuming that it fits resource requirements. nodeName(nodeName):: __specMixin({nodeName: nodeName}), // NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ nodeSelector(nodeSelector):: __specMixin({nodeSelector+: nodeSelector}), // Restart policy for all containers within the pod. One of Always, OnFailure, Never. Default to Always. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy restartPolicy(restartPolicy):: __specMixin({restartPolicy: restartPolicy}), // If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler. schedulerName(schedulerName):: __specMixin({schedulerName: schedulerName}), // SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field. securityContext:: { local __securityContextMixin(securityContext) = __specMixin({securityContext+: securityContext}), mixinInstance(securityContext):: __securityContextMixin(securityContext), // A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod: // // 1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw---- // // If unset, the Kubelet will not modify the ownership and permissions of any volume. fsGroup(fsGroup):: __securityContextMixin({fsGroup: fsGroup}), // Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsNonRoot(runAsNonRoot):: __securityContextMixin({runAsNonRoot: runAsNonRoot}), // The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. runAsUser(runAsUser):: __securityContextMixin({runAsUser: runAsUser}), // The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = __securityContextMixin({seLinuxOptions+: seLinuxOptions}), mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, // A list of groups applied to the first process run in each container, in addition to the container's primary GID. If unspecified, no groups will be added to any container. supplementalGroups(supplementalGroups):: if std.type(supplementalGroups) == "array" then __securityContextMixin({supplementalGroups+: supplementalGroups}) else __securityContextMixin({supplementalGroups+: [supplementalGroups]}), }, securityContextType:: hidden.core.v1.podSecurityContext, // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead. serviceAccount(serviceAccount):: __specMixin({serviceAccount: serviceAccount}), // ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ serviceAccountName(serviceAccountName):: __specMixin({serviceAccountName: serviceAccountName}), // If specified, the fully qualified Pod hostname will be "...svc.". If not specified, the pod will not have a domainname at all. subdomain(subdomain):: __specMixin({subdomain: subdomain}), // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds. terminationGracePeriodSeconds(terminationGracePeriodSeconds):: __specMixin({terminationGracePeriodSeconds: terminationGracePeriodSeconds}), // If specified, the pod's tolerations. tolerations(tolerations):: if std.type(tolerations) == "array" then __specMixin({tolerations+: tolerations}) else __specMixin({tolerations+: [tolerations]}), tolerationsType:: hidden.core.v1.toleration, // List of volumes that can be mounted by containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes volumes(volumes):: if std.type(volumes) == "array" then __specMixin({volumes+: volumes}) else __specMixin({volumes+: [volumes]}), volumesType:: hidden.core.v1.volume, }, specType:: hidden.core.v1.podSpec, }, templateType:: hidden.core.v1.podTemplateSpec, }, }, // PodTemplateList is a list of PodTemplates. podTemplateList:: { local kind = {kind: "PodTemplateList"}, new():: apiVersion + kind, // List of pod templates items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.core.v1.podTemplate, mixin:: { }, }, // ReplicationController represents the configuration of a replication controller. replicationController:: { local kind = {kind: "ReplicationController"}, new():: apiVersion + kind, mixin:: { // If the Labels of a ReplicationController are empty, they are defaulted to be the same as the Pod(s) that the replication controller manages. Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Spec defines the specification of the desired behavior of the replication controller. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // Minimum number of seconds for which a newly created pod should be ready without any of its container crashing, for it to be considered available. Defaults to 0 (pod will be considered available as soon as it is ready) minReadySeconds(minReadySeconds):: __specMixin({minReadySeconds: minReadySeconds}), // Replicas is the number of desired replicas. This is a pointer to distinguish between explicit zero and unspecified. Defaults to 1. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#what-is-a-replicationcontroller replicas(replicas):: __specMixin({replicas: replicas}), // Selector is a label query over pods that should match the Replicas count. If Selector is empty, it is defaulted to the labels present on the Pod template. Label keys and values that must match in order to be controlled by this replication controller, if empty defaulted to labels on Pod template. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors selector(selector):: __specMixin({selector+: selector}), // Template is the object that describes the pod that will be created if insufficient replicas are detected. This takes precedence over a TemplateRef. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#pod-template template:: { local __templateMixin(template) = __specMixin({template+: template}), mixinInstance(template):: __templateMixin(template), // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = __templateMixin({metadata+: metadata}), mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = __templateMixin({spec+: spec}), mixinInstance(spec):: __specMixin(spec), // Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer. activeDeadlineSeconds(activeDeadlineSeconds):: __specMixin({activeDeadlineSeconds: activeDeadlineSeconds}), // If specified, the pod's scheduling constraints affinity:: { local __affinityMixin(affinity) = __specMixin({affinity+: affinity}), mixinInstance(affinity):: __affinityMixin(affinity), // Describes node affinity scheduling rules for the pod. nodeAffinity:: { local __nodeAffinityMixin(nodeAffinity) = __affinityMixin({nodeAffinity+: nodeAffinity}), mixinInstance(nodeAffinity):: __nodeAffinityMixin(nodeAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.preferredSchedulingTerm, // If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node. requiredDuringSchedulingIgnoredDuringExecution:: { local __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution) = __nodeAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}), mixinInstance(requiredDuringSchedulingIgnoredDuringExecution):: __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution), // Required. A list of node selector terms. The terms are ORed. nodeSelectorTerms(nodeSelectorTerms):: if std.type(nodeSelectorTerms) == "array" then __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: nodeSelectorTerms}) else __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: [nodeSelectorTerms]}), nodeSelectorTermsType:: hidden.core.v1.nodeSelectorTerm, }, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.nodeSelector, }, nodeAffinityType:: hidden.core.v1.nodeAffinity, // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)). podAffinity:: { local __podAffinityMixin(podAffinity) = __affinityMixin({podAffinity+: podAffinity}), mixinInstance(podAffinity):: __podAffinityMixin(podAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAffinityType:: hidden.core.v1.podAffinity, // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)). podAntiAffinity:: { local __podAntiAffinityMixin(podAntiAffinity) = __affinityMixin({podAntiAffinity+: podAntiAffinity}), mixinInstance(podAntiAffinity):: __podAntiAffinityMixin(podAntiAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAntiAffinityType:: hidden.core.v1.podAntiAffinity, }, affinityType:: hidden.core.v1.affinity, // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted. automountServiceAccountToken(automountServiceAccountToken):: __specMixin({automountServiceAccountToken: automountServiceAccountToken}), // List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated. containers(containers):: if std.type(containers) == "array" then __specMixin({containers+: containers}) else __specMixin({containers+: [containers]}), containersType:: hidden.core.v1.container, // Set DNS policy for containers within the pod. One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. Defaults to "ClusterFirst". To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. dnsPolicy(dnsPolicy):: __specMixin({dnsPolicy: dnsPolicy}), // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts file if specified. This is only valid for non-hostNetwork pods. hostAliases(hostAliases):: if std.type(hostAliases) == "array" then __specMixin({hostAliases+: hostAliases}) else __specMixin({hostAliases+: [hostAliases]}), hostAliasesType:: hidden.core.v1.hostAlias, // Use the host's ipc namespace. Optional: Default to false. hostIpc(hostIpc):: __specMixin({hostIPC: hostIpc}), // Host networking requested for this pod. Use the host's network namespace. If this option is set, the ports that will be used must be specified. Default to false. hostNetwork(hostNetwork):: __specMixin({hostNetwork: hostNetwork}), // Use the host's pid namespace. Optional: Default to false. hostPid(hostPid):: __specMixin({hostPID: hostPid}), // Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value. hostname(hostname):: __specMixin({hostname: hostname}), // 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. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod imagePullSecrets(imagePullSecrets):: if std.type(imagePullSecrets) == "array" then __specMixin({imagePullSecrets+: imagePullSecrets}) else __specMixin({imagePullSecrets+: [imagePullSecrets]}), imagePullSecretsType:: hidden.core.v1.localObjectReference, // List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ initContainers(initContainers):: if std.type(initContainers) == "array" then __specMixin({initContainers+: initContainers}) else __specMixin({initContainers+: [initContainers]}), initContainersType:: hidden.core.v1.container, // NodeName is a request to schedule this pod onto a specific node. If it is non-empty, the scheduler simply schedules this pod onto that node, assuming that it fits resource requirements. nodeName(nodeName):: __specMixin({nodeName: nodeName}), // NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ nodeSelector(nodeSelector):: __specMixin({nodeSelector+: nodeSelector}), // Restart policy for all containers within the pod. One of Always, OnFailure, Never. Default to Always. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy restartPolicy(restartPolicy):: __specMixin({restartPolicy: restartPolicy}), // If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler. schedulerName(schedulerName):: __specMixin({schedulerName: schedulerName}), // SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field. securityContext:: { local __securityContextMixin(securityContext) = __specMixin({securityContext+: securityContext}), mixinInstance(securityContext):: __securityContextMixin(securityContext), // A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod: // // 1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw---- // // If unset, the Kubelet will not modify the ownership and permissions of any volume. fsGroup(fsGroup):: __securityContextMixin({fsGroup: fsGroup}), // Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsNonRoot(runAsNonRoot):: __securityContextMixin({runAsNonRoot: runAsNonRoot}), // The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. runAsUser(runAsUser):: __securityContextMixin({runAsUser: runAsUser}), // The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = __securityContextMixin({seLinuxOptions+: seLinuxOptions}), mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, // A list of groups applied to the first process run in each container, in addition to the container's primary GID. If unspecified, no groups will be added to any container. supplementalGroups(supplementalGroups):: if std.type(supplementalGroups) == "array" then __securityContextMixin({supplementalGroups+: supplementalGroups}) else __securityContextMixin({supplementalGroups+: [supplementalGroups]}), }, securityContextType:: hidden.core.v1.podSecurityContext, // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead. serviceAccount(serviceAccount):: __specMixin({serviceAccount: serviceAccount}), // ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ serviceAccountName(serviceAccountName):: __specMixin({serviceAccountName: serviceAccountName}), // If specified, the fully qualified Pod hostname will be "...svc.". If not specified, the pod will not have a domainname at all. subdomain(subdomain):: __specMixin({subdomain: subdomain}), // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds. terminationGracePeriodSeconds(terminationGracePeriodSeconds):: __specMixin({terminationGracePeriodSeconds: terminationGracePeriodSeconds}), // If specified, the pod's tolerations. tolerations(tolerations):: if std.type(tolerations) == "array" then __specMixin({tolerations+: tolerations}) else __specMixin({tolerations+: [tolerations]}), tolerationsType:: hidden.core.v1.toleration, // List of volumes that can be mounted by containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes volumes(volumes):: if std.type(volumes) == "array" then __specMixin({volumes+: volumes}) else __specMixin({volumes+: [volumes]}), volumesType:: hidden.core.v1.volume, }, specType:: hidden.core.v1.podSpec, }, templateType:: hidden.core.v1.podTemplateSpec, }, specType:: hidden.core.v1.replicationControllerSpec, }, }, // ReplicationControllerList is a collection of replication controllers. replicationControllerList:: { local kind = {kind: "ReplicationControllerList"}, new():: apiVersion + kind, // List of replication controllers. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.core.v1.replicationController, mixin:: { }, }, // ResourceQuota sets aggregate quota restrictions enforced per namespace resourceQuota:: { local kind = {kind: "ResourceQuota"}, new():: apiVersion + kind, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Spec defines the desired quota. https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // Hard is the set of desired hard limits for each named resource. More info: https://git.k8s.io/community/contributors/design-proposals/admission_control_resource_quota.md hard(hard):: __specMixin({hard+: hard}), // A collection of filters that must match each object tracked by a quota. If not specified, the quota matches all objects. scopes(scopes):: if std.type(scopes) == "array" then __specMixin({scopes+: scopes}) else __specMixin({scopes+: [scopes]}), }, specType:: hidden.core.v1.resourceQuotaSpec, }, }, // ResourceQuotaList is a list of ResourceQuota items. resourceQuotaList:: { local kind = {kind: "ResourceQuotaList"}, new():: apiVersion + kind, // Items is a list of ResourceQuota objects. More info: https://git.k8s.io/community/contributors/design-proposals/admission_control_resource_quota.md items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.core.v1.resourceQuota, mixin:: { }, }, // Secret holds secret data of a certain type. The total bytes of the values in the Data field must be less than MaxSecretSize bytes. secret:: { local kind = {kind: "Secret"}, new():: apiVersion + kind, // Data contains the secret data. Each key must consist of alphanumeric characters, '-', '_' or '.'. The serialized form of the secret data is a base64 encoded string, representing the arbitrary (possibly non-string) data value here. Described in https://tools.ietf.org/html/rfc4648#section-4 data(data):: {data+: data}, // stringData allows specifying non-binary secret data in string form. It is provided as a write-only convenience method. All keys and values are merged into the data field on write, overwriting any existing values. It is never output when reading from the API. stringData(stringData):: {stringData+: stringData}, // Used to facilitate programmatic handling of secret data. type(type):: {type: type}, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, }, }, // SecretList is a list of Secret. secretList:: { local kind = {kind: "SecretList"}, new():: apiVersion + kind, // Items is a list of secret objects. More info: https://kubernetes.io/docs/concepts/configuration/secret items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.core.v1.secret, mixin:: { }, }, // Service is a named abstraction of software service (for example, mysql) consisting of local port (for example 3306) that the proxy listens on, and the selector that determines which pods will answer requests sent through the proxy. service:: { local kind = {kind: "Service"}, new(name, selector, ports):: apiVersion + kind + self.mixin.metadata.name(name) + self.mixin.spec.selector(selector) + self.mixin.spec.ports(ports), mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Spec defines the behavior of a service. https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // clusterIP is the IP address of the service and is usually assigned randomly by the master. If an address is specified manually and is not in use by others, it will be allocated to the service; otherwise, creation of the service will fail. This field can not be changed through updates. Valid values are "None", empty string (""), or a valid IP address. "None" can be specified for headless services when proxying is not required. Only applies to types ClusterIP, NodePort, and LoadBalancer. Ignored if type is ExternalName. More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies clusterIp(clusterIp):: __specMixin({clusterIP: clusterIp}), // externalIPs is a list of IP addresses for which nodes in the cluster will also accept traffic for this service. These IPs are not managed by Kubernetes. The user is responsible for ensuring that traffic arrives at a node with this IP. A common example is external load-balancers that are not part of the Kubernetes system. externalIps(externalIps):: if std.type(externalIps) == "array" then __specMixin({externalIPs+: externalIps}) else __specMixin({externalIPs+: [externalIps]}), // externalName is the external reference that kubedns or equivalent will return as a CNAME record for this service. No proxying will be involved. Must be a valid DNS name and requires Type to be ExternalName. externalName(externalName):: __specMixin({externalName: externalName}), // externalTrafficPolicy denotes if this Service desires to route external traffic to node-local or cluster-wide endpoints. "Local" preserves the client source IP and avoids a second hop for LoadBalancer and Nodeport type services, but risks potentially imbalanced traffic spreading. "Cluster" obscures the client source IP and may cause a second hop to another node, but should have good overall load-spreading. externalTrafficPolicy(externalTrafficPolicy):: __specMixin({externalTrafficPolicy: externalTrafficPolicy}), // healthCheckNodePort specifies the healthcheck nodePort for the service. If not specified, HealthCheckNodePort is created by the service api backend with the allocated nodePort. Will use user-specified nodePort value if specified by the client. Only effects when Type is set to LoadBalancer and ExternalTrafficPolicy is set to Local. healthCheckNodePort(healthCheckNodePort):: __specMixin({healthCheckNodePort: healthCheckNodePort}), // Only applies to Service Type: LoadBalancer LoadBalancer will get created with the IP specified in this field. This feature depends on whether the underlying cloud-provider supports specifying the loadBalancerIP when a load balancer is created. This field will be ignored if the cloud-provider does not support the feature. loadBalancerIp(loadBalancerIp):: __specMixin({loadBalancerIP: loadBalancerIp}), // If specified and supported by the platform, this will restrict traffic through the cloud-provider load-balancer will be restricted to the specified client IPs. This field will be ignored if the cloud-provider does not support the feature." More info: https://kubernetes.io/docs/tasks/access-application-cluster/configure-cloud-provider-firewall/ loadBalancerSourceRanges(loadBalancerSourceRanges):: if std.type(loadBalancerSourceRanges) == "array" then __specMixin({loadBalancerSourceRanges+: loadBalancerSourceRanges}) else __specMixin({loadBalancerSourceRanges+: [loadBalancerSourceRanges]}), // The list of ports that are exposed by this service. More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies ports(ports):: if std.type(ports) == "array" then __specMixin({ports+: ports}) else __specMixin({ports+: [ports]}), portsType:: hidden.core.v1.servicePort, // Route service traffic to pods with label keys and values matching this selector. If empty or not present, the service is assumed to have an external process managing its endpoints, which Kubernetes will not modify. Only applies to types ClusterIP, NodePort, and LoadBalancer. Ignored if type is ExternalName. More info: https://kubernetes.io/docs/concepts/services-networking/service/ selector(selector):: __specMixin({selector+: selector}), // Supports "ClientIP" and "None". Used to maintain session affinity. Enable client IP based session affinity. Must be ClientIP or None. Defaults to None. More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies sessionAffinity(sessionAffinity):: __specMixin({sessionAffinity: sessionAffinity}), // type determines how the Service is exposed. Defaults to ClusterIP. Valid options are ExternalName, ClusterIP, NodePort, and LoadBalancer. "ExternalName" maps to the specified externalName. "ClusterIP" allocates a cluster-internal IP address for load-balancing to endpoints. Endpoints are determined by the selector or if that is not specified, by manual construction of an Endpoints object. If clusterIP is "None", no virtual IP is allocated and the endpoints are published as a set of endpoints rather than a stable IP. "NodePort" builds on ClusterIP and allocates a port on every node which routes to the clusterIP. "LoadBalancer" builds on NodePort and creates an external load-balancer (if supported in the current cloud) which routes to the clusterIP. More info: https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services---service-types type(type):: __specMixin({type: type}), }, specType:: hidden.core.v1.serviceSpec, }, }, // ServiceAccount binds together: * a name, understood by users, and perhaps by peripheral systems, for an identity * a principal that can be authenticated and authorized * a set of secrets serviceAccount:: { local kind = {kind: "ServiceAccount"}, new():: apiVersion + kind, // AutomountServiceAccountToken indicates whether pods running as this service account should have an API token automatically mounted. Can be overridden at the pod level. automountServiceAccountToken(automountServiceAccountToken):: {automountServiceAccountToken: automountServiceAccountToken}, // ImagePullSecrets is a list of references to secrets in the same namespace to use for pulling any images in pods that reference this ServiceAccount. ImagePullSecrets are distinct from Secrets because Secrets can be mounted in the pod, but ImagePullSecrets are only accessed by the kubelet. More info: https://kubernetes.io/docs/concepts/containers/images/#specifying-imagepullsecrets-on-a-pod imagePullSecrets(imagePullSecrets):: if std.type(imagePullSecrets) == "array" then {imagePullSecrets+: imagePullSecrets} else {imagePullSecrets+: [imagePullSecrets]}, imagePullSecretsType:: hidden.core.v1.localObjectReference, // Secrets is the list of secrets allowed to be used by pods running using this ServiceAccount. More info: https://kubernetes.io/docs/concepts/configuration/secret secrets(secrets):: if std.type(secrets) == "array" then {secrets+: secrets} else {secrets+: [secrets]}, secretsType:: hidden.core.v1.objectReference, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, }, }, // ServiceAccountList is a list of ServiceAccount objects serviceAccountList:: { local kind = {kind: "ServiceAccountList"}, new():: apiVersion + kind, // List of ServiceAccounts. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.core.v1.serviceAccount, mixin:: { }, }, // ServiceList holds a list of services. serviceList:: { local kind = {kind: "ServiceList"}, new():: apiVersion + kind, // List of services items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.core.v1.service, mixin:: { }, }, }, }, extensions:: { v1beta1:: { local apiVersion = {apiVersion: "extensions/v1beta1"}, // DaemonSet represents the configuration of a daemon set. daemonSet:: { local kind = {kind: "DaemonSet"}, new():: apiVersion + kind, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // The desired behavior of this daemon set. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // The minimum number of seconds for which a newly created DaemonSet pod should be ready without any of its container crashing, for it to be considered available. Defaults to 0 (pod will be considered available as soon as it is ready). minReadySeconds(minReadySeconds):: __specMixin({minReadySeconds: minReadySeconds}), // The number of old history to retain to allow rollback. This is a pointer to distinguish between explicit zero and not specified. Defaults to 10. revisionHistoryLimit(revisionHistoryLimit):: __specMixin({revisionHistoryLimit: revisionHistoryLimit}), // A label query over pods that are managed by the daemon set. Must match in order to be controlled. If empty, defaulted to labels on Pod template. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors selector:: { local __selectorMixin(selector) = __specMixin({selector+: selector}), mixinInstance(selector):: __selectorMixin(selector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __selectorMixin({matchExpressions+: matchExpressions}) else __selectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __selectorMixin({matchLabels+: matchLabels}), }, selectorType:: hidden.meta.v1.labelSelector, // An object that describes the pod that will be created. The DaemonSet will create exactly one copy of this pod on every node that matches the template's node selector (or on every node if no node selector is specified). More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#pod-template template:: { local __templateMixin(template) = __specMixin({template+: template}), mixinInstance(template):: __templateMixin(template), // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = __templateMixin({metadata+: metadata}), mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = __templateMixin({spec+: spec}), mixinInstance(spec):: __specMixin(spec), // Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer. activeDeadlineSeconds(activeDeadlineSeconds):: __specMixin({activeDeadlineSeconds: activeDeadlineSeconds}), // If specified, the pod's scheduling constraints affinity:: { local __affinityMixin(affinity) = __specMixin({affinity+: affinity}), mixinInstance(affinity):: __affinityMixin(affinity), // Describes node affinity scheduling rules for the pod. nodeAffinity:: { local __nodeAffinityMixin(nodeAffinity) = __affinityMixin({nodeAffinity+: nodeAffinity}), mixinInstance(nodeAffinity):: __nodeAffinityMixin(nodeAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.preferredSchedulingTerm, // If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node. requiredDuringSchedulingIgnoredDuringExecution:: { local __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution) = __nodeAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}), mixinInstance(requiredDuringSchedulingIgnoredDuringExecution):: __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution), // Required. A list of node selector terms. The terms are ORed. nodeSelectorTerms(nodeSelectorTerms):: if std.type(nodeSelectorTerms) == "array" then __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: nodeSelectorTerms}) else __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: [nodeSelectorTerms]}), nodeSelectorTermsType:: hidden.core.v1.nodeSelectorTerm, }, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.nodeSelector, }, nodeAffinityType:: hidden.core.v1.nodeAffinity, // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)). podAffinity:: { local __podAffinityMixin(podAffinity) = __affinityMixin({podAffinity+: podAffinity}), mixinInstance(podAffinity):: __podAffinityMixin(podAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAffinityType:: hidden.core.v1.podAffinity, // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)). podAntiAffinity:: { local __podAntiAffinityMixin(podAntiAffinity) = __affinityMixin({podAntiAffinity+: podAntiAffinity}), mixinInstance(podAntiAffinity):: __podAntiAffinityMixin(podAntiAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAntiAffinityType:: hidden.core.v1.podAntiAffinity, }, affinityType:: hidden.core.v1.affinity, // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted. automountServiceAccountToken(automountServiceAccountToken):: __specMixin({automountServiceAccountToken: automountServiceAccountToken}), // List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated. containers(containers):: if std.type(containers) == "array" then __specMixin({containers+: containers}) else __specMixin({containers+: [containers]}), containersType:: hidden.core.v1.container, // Set DNS policy for containers within the pod. One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. Defaults to "ClusterFirst". To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. dnsPolicy(dnsPolicy):: __specMixin({dnsPolicy: dnsPolicy}), // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts file if specified. This is only valid for non-hostNetwork pods. hostAliases(hostAliases):: if std.type(hostAliases) == "array" then __specMixin({hostAliases+: hostAliases}) else __specMixin({hostAliases+: [hostAliases]}), hostAliasesType:: hidden.core.v1.hostAlias, // Use the host's ipc namespace. Optional: Default to false. hostIpc(hostIpc):: __specMixin({hostIPC: hostIpc}), // Host networking requested for this pod. Use the host's network namespace. If this option is set, the ports that will be used must be specified. Default to false. hostNetwork(hostNetwork):: __specMixin({hostNetwork: hostNetwork}), // Use the host's pid namespace. Optional: Default to false. hostPid(hostPid):: __specMixin({hostPID: hostPid}), // Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value. hostname(hostname):: __specMixin({hostname: hostname}), // 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. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod imagePullSecrets(imagePullSecrets):: if std.type(imagePullSecrets) == "array" then __specMixin({imagePullSecrets+: imagePullSecrets}) else __specMixin({imagePullSecrets+: [imagePullSecrets]}), imagePullSecretsType:: hidden.core.v1.localObjectReference, // List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ initContainers(initContainers):: if std.type(initContainers) == "array" then __specMixin({initContainers+: initContainers}) else __specMixin({initContainers+: [initContainers]}), initContainersType:: hidden.core.v1.container, // NodeName is a request to schedule this pod onto a specific node. If it is non-empty, the scheduler simply schedules this pod onto that node, assuming that it fits resource requirements. nodeName(nodeName):: __specMixin({nodeName: nodeName}), // NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ nodeSelector(nodeSelector):: __specMixin({nodeSelector+: nodeSelector}), // Restart policy for all containers within the pod. One of Always, OnFailure, Never. Default to Always. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy restartPolicy(restartPolicy):: __specMixin({restartPolicy: restartPolicy}), // If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler. schedulerName(schedulerName):: __specMixin({schedulerName: schedulerName}), // SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field. securityContext:: { local __securityContextMixin(securityContext) = __specMixin({securityContext+: securityContext}), mixinInstance(securityContext):: __securityContextMixin(securityContext), // A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod: // // 1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw---- // // If unset, the Kubelet will not modify the ownership and permissions of any volume. fsGroup(fsGroup):: __securityContextMixin({fsGroup: fsGroup}), // Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsNonRoot(runAsNonRoot):: __securityContextMixin({runAsNonRoot: runAsNonRoot}), // The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. runAsUser(runAsUser):: __securityContextMixin({runAsUser: runAsUser}), // The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = __securityContextMixin({seLinuxOptions+: seLinuxOptions}), mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, // A list of groups applied to the first process run in each container, in addition to the container's primary GID. If unspecified, no groups will be added to any container. supplementalGroups(supplementalGroups):: if std.type(supplementalGroups) == "array" then __securityContextMixin({supplementalGroups+: supplementalGroups}) else __securityContextMixin({supplementalGroups+: [supplementalGroups]}), }, securityContextType:: hidden.core.v1.podSecurityContext, // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead. serviceAccount(serviceAccount):: __specMixin({serviceAccount: serviceAccount}), // ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ serviceAccountName(serviceAccountName):: __specMixin({serviceAccountName: serviceAccountName}), // If specified, the fully qualified Pod hostname will be "...svc.". If not specified, the pod will not have a domainname at all. subdomain(subdomain):: __specMixin({subdomain: subdomain}), // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds. terminationGracePeriodSeconds(terminationGracePeriodSeconds):: __specMixin({terminationGracePeriodSeconds: terminationGracePeriodSeconds}), // If specified, the pod's tolerations. tolerations(tolerations):: if std.type(tolerations) == "array" then __specMixin({tolerations+: tolerations}) else __specMixin({tolerations+: [tolerations]}), tolerationsType:: hidden.core.v1.toleration, // List of volumes that can be mounted by containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes volumes(volumes):: if std.type(volumes) == "array" then __specMixin({volumes+: volumes}) else __specMixin({volumes+: [volumes]}), volumesType:: hidden.core.v1.volume, }, specType:: hidden.core.v1.podSpec, }, templateType:: hidden.core.v1.podTemplateSpec, // An update strategy to replace existing DaemonSet pods with new pods. updateStrategy:: { local __updateStrategyMixin(updateStrategy) = __specMixin({updateStrategy+: updateStrategy}), mixinInstance(updateStrategy):: __updateStrategyMixin(updateStrategy), // Rolling update config params. Present only if type = "RollingUpdate". rollingUpdate:: { local __rollingUpdateMixin(rollingUpdate) = __updateStrategyMixin({rollingUpdate+: rollingUpdate}), mixinInstance(rollingUpdate):: __rollingUpdateMixin(rollingUpdate), // The maximum number of DaemonSet pods that can be unavailable during the update. Value can be an absolute number (ex: 5) or a percentage of total number of DaemonSet pods at the start of the update (ex: 10%). Absolute number is calculated from percentage by rounding up. This cannot be 0. Default value is 1. Example: when this is set to 30%, at most 30% of the total number of nodes that should be running the daemon pod (i.e. status.desiredNumberScheduled) can have their pods stopped for an update at any given time. The update starts by stopping at most 30% of those DaemonSet pods and then brings up new DaemonSet pods in their place. Once the new pods are available, it then proceeds onto other DaemonSet pods, thus ensuring that at least 70% of original number of DaemonSet pods are available at all times during the update. maxUnavailable(maxUnavailable):: __rollingUpdateMixin({maxUnavailable: maxUnavailable}), }, rollingUpdateType:: hidden.extensions.v1beta1.rollingUpdateDaemonSet, // Type of daemon set update. Can be "RollingUpdate" or "OnDelete". Default is OnDelete. type(type):: __updateStrategyMixin({type: type}), }, updateStrategyType:: hidden.extensions.v1beta1.daemonSetUpdateStrategy, }, specType:: hidden.extensions.v1beta1.daemonSetSpec, }, }, // DaemonSetList is a collection of daemon sets. daemonSetList:: { local kind = {kind: "DaemonSetList"}, new():: apiVersion + kind, // A list of daemon sets. items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.extensions.v1beta1.daemonSet, mixin:: { }, }, // Deployment enables declarative updates for Pods and ReplicaSets. deployment:: { local kind = {kind: "Deployment"}, new(name, replicas, containers, podLabels={}):: apiVersion + kind + self.mixin.metadata.name(name) + self.mixin.spec.replicas(replicas) + self.mixin.spec.template.spec.containers(containers) + self.mixin.spec.template.metadata.labels(podLabels), mixin:: { // Standard object metadata. metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the Deployment. spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // Minimum number of seconds for which a newly created pod should be ready without any of its container crashing, for it to be considered available. Defaults to 0 (pod will be considered available as soon as it is ready) minReadySeconds(minReadySeconds):: __specMixin({minReadySeconds: minReadySeconds}), // Indicates that the deployment is paused and will not be processed by the deployment controller. paused(paused):: __specMixin({paused: paused}), // The maximum time in seconds for a deployment to make progress before it is considered to be failed. The deployment controller will continue to process failed deployments and a condition with a ProgressDeadlineExceeded reason will be surfaced in the deployment status. Once autoRollback is implemented, the deployment controller will automatically rollback failed deployments. Note that progress will not be estimated during the time a deployment is paused. This is not set by default. progressDeadlineSeconds(progressDeadlineSeconds):: __specMixin({progressDeadlineSeconds: progressDeadlineSeconds}), // Number of desired pods. This is a pointer to distinguish between explicit zero and not specified. Defaults to 1. replicas(replicas):: __specMixin({replicas: replicas}), // The number of old ReplicaSets to retain to allow rollback. This is a pointer to distinguish between explicit zero and not specified. revisionHistoryLimit(revisionHistoryLimit):: __specMixin({revisionHistoryLimit: revisionHistoryLimit}), // The config this deployment is rolling back to. Will be cleared after rollback is done. rollbackTo:: { local __rollbackToMixin(rollbackTo) = __specMixin({rollbackTo+: rollbackTo}), mixinInstance(rollbackTo):: __rollbackToMixin(rollbackTo), // The revision to rollback to. If set to 0, rollback to the last revision. revision(revision):: __rollbackToMixin({revision: revision}), }, rollbackToType:: hidden.extensions.v1beta1.rollbackConfig, // Label selector for pods. Existing ReplicaSets whose pods are selected by this will be the ones affected by this deployment. selector:: { local __selectorMixin(selector) = __specMixin({selector+: selector}), mixinInstance(selector):: __selectorMixin(selector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __selectorMixin({matchExpressions+: matchExpressions}) else __selectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __selectorMixin({matchLabels+: matchLabels}), }, selectorType:: hidden.meta.v1.labelSelector, // The deployment strategy to use to replace existing pods with new ones. strategy:: { local __strategyMixin(strategy) = __specMixin({strategy+: strategy}), mixinInstance(strategy):: __strategyMixin(strategy), // Rolling update config params. Present only if DeploymentStrategyType = RollingUpdate. rollingUpdate:: { local __rollingUpdateMixin(rollingUpdate) = __strategyMixin({rollingUpdate+: rollingUpdate}), mixinInstance(rollingUpdate):: __rollingUpdateMixin(rollingUpdate), // The maximum number of pods that can be scheduled above the desired number of pods. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). This can not be 0 if MaxUnavailable is 0. Absolute number is calculated from percentage by rounding up. By default, a value of 1 is used. Example: when this is set to 30%, the new RC can be scaled up immediately when the rolling update starts, such that the total number of old and new pods do not exceed 130% of desired pods. Once old pods have been killed, new RC can be scaled up further, ensuring that total number of pods running at any time during the update is atmost 130% of desired pods. maxSurge(maxSurge):: __rollingUpdateMixin({maxSurge: maxSurge}), // The maximum number of pods that can be unavailable during the update. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). Absolute number is calculated from percentage by rounding down. This can not be 0 if MaxSurge is 0. By default, a fixed value of 1 is used. Example: when this is set to 30%, the old RC can be scaled down to 70% of desired pods immediately when the rolling update starts. Once new pods are ready, old RC can be scaled down further, followed by scaling up the new RC, ensuring that the total number of pods available at all times during the update is at least 70% of desired pods. maxUnavailable(maxUnavailable):: __rollingUpdateMixin({maxUnavailable: maxUnavailable}), }, rollingUpdateType:: hidden.extensions.v1beta1.rollingUpdateDeployment, // Type of deployment. Can be "Recreate" or "RollingUpdate". Default is RollingUpdate. type(type):: __strategyMixin({type: type}), }, strategyType:: hidden.extensions.v1beta1.deploymentStrategy, // Template describes the pods that will be created. template:: { local __templateMixin(template) = __specMixin({template+: template}), mixinInstance(template):: __templateMixin(template), // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = __templateMixin({metadata+: metadata}), mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = __templateMixin({spec+: spec}), mixinInstance(spec):: __specMixin(spec), // Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer. activeDeadlineSeconds(activeDeadlineSeconds):: __specMixin({activeDeadlineSeconds: activeDeadlineSeconds}), // If specified, the pod's scheduling constraints affinity:: { local __affinityMixin(affinity) = __specMixin({affinity+: affinity}), mixinInstance(affinity):: __affinityMixin(affinity), // Describes node affinity scheduling rules for the pod. nodeAffinity:: { local __nodeAffinityMixin(nodeAffinity) = __affinityMixin({nodeAffinity+: nodeAffinity}), mixinInstance(nodeAffinity):: __nodeAffinityMixin(nodeAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.preferredSchedulingTerm, // If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node. requiredDuringSchedulingIgnoredDuringExecution:: { local __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution) = __nodeAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}), mixinInstance(requiredDuringSchedulingIgnoredDuringExecution):: __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution), // Required. A list of node selector terms. The terms are ORed. nodeSelectorTerms(nodeSelectorTerms):: if std.type(nodeSelectorTerms) == "array" then __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: nodeSelectorTerms}) else __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: [nodeSelectorTerms]}), nodeSelectorTermsType:: hidden.core.v1.nodeSelectorTerm, }, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.nodeSelector, }, nodeAffinityType:: hidden.core.v1.nodeAffinity, // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)). podAffinity:: { local __podAffinityMixin(podAffinity) = __affinityMixin({podAffinity+: podAffinity}), mixinInstance(podAffinity):: __podAffinityMixin(podAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAffinityType:: hidden.core.v1.podAffinity, // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)). podAntiAffinity:: { local __podAntiAffinityMixin(podAntiAffinity) = __affinityMixin({podAntiAffinity+: podAntiAffinity}), mixinInstance(podAntiAffinity):: __podAntiAffinityMixin(podAntiAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAntiAffinityType:: hidden.core.v1.podAntiAffinity, }, affinityType:: hidden.core.v1.affinity, // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted. automountServiceAccountToken(automountServiceAccountToken):: __specMixin({automountServiceAccountToken: automountServiceAccountToken}), // List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated. containers(containers):: if std.type(containers) == "array" then __specMixin({containers+: containers}) else __specMixin({containers+: [containers]}), containersType:: hidden.core.v1.container, // Set DNS policy for containers within the pod. One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. Defaults to "ClusterFirst". To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. dnsPolicy(dnsPolicy):: __specMixin({dnsPolicy: dnsPolicy}), // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts file if specified. This is only valid for non-hostNetwork pods. hostAliases(hostAliases):: if std.type(hostAliases) == "array" then __specMixin({hostAliases+: hostAliases}) else __specMixin({hostAliases+: [hostAliases]}), hostAliasesType:: hidden.core.v1.hostAlias, // Use the host's ipc namespace. Optional: Default to false. hostIpc(hostIpc):: __specMixin({hostIPC: hostIpc}), // Host networking requested for this pod. Use the host's network namespace. If this option is set, the ports that will be used must be specified. Default to false. hostNetwork(hostNetwork):: __specMixin({hostNetwork: hostNetwork}), // Use the host's pid namespace. Optional: Default to false. hostPid(hostPid):: __specMixin({hostPID: hostPid}), // Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value. hostname(hostname):: __specMixin({hostname: hostname}), // 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. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod imagePullSecrets(imagePullSecrets):: if std.type(imagePullSecrets) == "array" then __specMixin({imagePullSecrets+: imagePullSecrets}) else __specMixin({imagePullSecrets+: [imagePullSecrets]}), imagePullSecretsType:: hidden.core.v1.localObjectReference, // List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ initContainers(initContainers):: if std.type(initContainers) == "array" then __specMixin({initContainers+: initContainers}) else __specMixin({initContainers+: [initContainers]}), initContainersType:: hidden.core.v1.container, // NodeName is a request to schedule this pod onto a specific node. If it is non-empty, the scheduler simply schedules this pod onto that node, assuming that it fits resource requirements. nodeName(nodeName):: __specMixin({nodeName: nodeName}), // NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ nodeSelector(nodeSelector):: __specMixin({nodeSelector+: nodeSelector}), // Restart policy for all containers within the pod. One of Always, OnFailure, Never. Default to Always. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy restartPolicy(restartPolicy):: __specMixin({restartPolicy: restartPolicy}), // If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler. schedulerName(schedulerName):: __specMixin({schedulerName: schedulerName}), // SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field. securityContext:: { local __securityContextMixin(securityContext) = __specMixin({securityContext+: securityContext}), mixinInstance(securityContext):: __securityContextMixin(securityContext), // A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod: // // 1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw---- // // If unset, the Kubelet will not modify the ownership and permissions of any volume. fsGroup(fsGroup):: __securityContextMixin({fsGroup: fsGroup}), // Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsNonRoot(runAsNonRoot):: __securityContextMixin({runAsNonRoot: runAsNonRoot}), // The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. runAsUser(runAsUser):: __securityContextMixin({runAsUser: runAsUser}), // The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = __securityContextMixin({seLinuxOptions+: seLinuxOptions}), mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, // A list of groups applied to the first process run in each container, in addition to the container's primary GID. If unspecified, no groups will be added to any container. supplementalGroups(supplementalGroups):: if std.type(supplementalGroups) == "array" then __securityContextMixin({supplementalGroups+: supplementalGroups}) else __securityContextMixin({supplementalGroups+: [supplementalGroups]}), }, securityContextType:: hidden.core.v1.podSecurityContext, // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead. serviceAccount(serviceAccount):: __specMixin({serviceAccount: serviceAccount}), // ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ serviceAccountName(serviceAccountName):: __specMixin({serviceAccountName: serviceAccountName}), // If specified, the fully qualified Pod hostname will be "...svc.". If not specified, the pod will not have a domainname at all. subdomain(subdomain):: __specMixin({subdomain: subdomain}), // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds. terminationGracePeriodSeconds(terminationGracePeriodSeconds):: __specMixin({terminationGracePeriodSeconds: terminationGracePeriodSeconds}), // If specified, the pod's tolerations. tolerations(tolerations):: if std.type(tolerations) == "array" then __specMixin({tolerations+: tolerations}) else __specMixin({tolerations+: [tolerations]}), tolerationsType:: hidden.core.v1.toleration, // List of volumes that can be mounted by containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes volumes(volumes):: if std.type(volumes) == "array" then __specMixin({volumes+: volumes}) else __specMixin({volumes+: [volumes]}), volumesType:: hidden.core.v1.volume, }, specType:: hidden.core.v1.podSpec, }, templateType:: hidden.core.v1.podTemplateSpec, }, specType:: hidden.extensions.v1beta1.deploymentSpec, }, }, // DeploymentList is a list of Deployments. deploymentList:: { local kind = {kind: "DeploymentList"}, new():: apiVersion + kind, // Items is the list of Deployments. items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.extensions.v1beta1.deployment, mixin:: { }, }, // DeploymentRollback stores the information required to rollback a deployment. deploymentRollback:: { local kind = {kind: "DeploymentRollback"}, new():: apiVersion + kind, // Required: This must match the Name of a deployment. name(name):: {name: name}, // The annotations to be updated to a deployment updatedAnnotations(updatedAnnotations):: {updatedAnnotations+: updatedAnnotations}, mixin:: { // The config of this deployment rollback. rollbackTo:: { local __rollbackToMixin(rollbackTo) = {rollbackTo+: rollbackTo}, mixinInstance(rollbackTo):: __rollbackToMixin(rollbackTo), // The revision to rollback to. If set to 0, rollback to the last revision. revision(revision):: __rollbackToMixin({revision: revision}), }, rollbackToType:: hidden.extensions.v1beta1.rollbackConfig, }, }, // Ingress is a collection of rules that allow inbound connections to reach the endpoints defined by a backend. An Ingress can be configured to give services externally-reachable urls, load balance traffic, terminate SSL, offer name based virtual hosting etc. ingress:: { local kind = {kind: "Ingress"}, new():: apiVersion + kind, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Spec is the desired state of the Ingress. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // A default backend capable of servicing requests that don't match any rule. At least one of 'backend' or 'rules' must be specified. This field is optional to allow the loadbalancer controller or defaulting logic to specify a global default. backend:: { local __backendMixin(backend) = __specMixin({backend+: backend}), mixinInstance(backend):: __backendMixin(backend), // Specifies the name of the referenced service. serviceName(serviceName):: __backendMixin({serviceName: serviceName}), // Specifies the port of the referenced service. servicePort(servicePort):: __backendMixin({servicePort: servicePort}), }, backendType:: hidden.extensions.v1beta1.ingressBackend, // A list of host rules used to configure the Ingress. If unspecified, or no rule matches, all traffic is sent to the default backend. rules(rules):: if std.type(rules) == "array" then __specMixin({rules+: rules}) else __specMixin({rules+: [rules]}), rulesType:: hidden.extensions.v1beta1.ingressRule, // TLS configuration. Currently the Ingress only supports a single TLS port, 443. If multiple members of this list specify different hosts, they will be multiplexed on the same port according to the hostname specified through the SNI TLS extension, if the ingress controller fulfilling the ingress supports SNI. tls(tls):: if std.type(tls) == "array" then __specMixin({tls+: tls}) else __specMixin({tls+: [tls]}), tlsType:: hidden.extensions.v1beta1.ingressTls, }, specType:: hidden.extensions.v1beta1.ingressSpec, }, }, // IngressList is a collection of Ingress. ingressList:: { local kind = {kind: "IngressList"}, new():: apiVersion + kind, // Items is the list of Ingress. items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.extensions.v1beta1.ingress, mixin:: { }, }, // NetworkPolicy describes what network traffic is allowed for a set of Pods networkPolicy:: { local kind = {kind: "NetworkPolicy"}, new():: apiVersion + kind, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior for this NetworkPolicy. spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // List of ingress rules to be applied to the selected pods. Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod OR if the traffic source is the pod's local node, OR if the traffic matches at least one ingress rule across all of the NetworkPolicy objects whose podSelector matches the pod. If this field is empty then this NetworkPolicy does not allow any traffic (and serves solely to ensure that the pods it selects are isolated by default). ingress(ingress):: if std.type(ingress) == "array" then __specMixin({ingress+: ingress}) else __specMixin({ingress+: [ingress]}), ingressType:: hidden.extensions.v1beta1.networkPolicyIngressRule, // Selects the pods to which this NetworkPolicy object applies. The array of ingress rules is applied to any pods selected by this field. Multiple network policies can select the same set of pods. In this case, the ingress rules for each are combined additively. This field is NOT optional and follows standard label selector semantics. An empty podSelector matches all pods in this namespace. podSelector:: { local __podSelectorMixin(podSelector) = __specMixin({podSelector+: podSelector}), mixinInstance(podSelector):: __podSelectorMixin(podSelector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __podSelectorMixin({matchExpressions+: matchExpressions}) else __podSelectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __podSelectorMixin({matchLabels+: matchLabels}), }, podSelectorType:: hidden.meta.v1.labelSelector, }, specType:: hidden.extensions.v1beta1.networkPolicySpec, }, }, // Network Policy List is a list of NetworkPolicy objects. networkPolicyList:: { local kind = {kind: "NetworkPolicyList"}, new():: apiVersion + kind, // Items is a list of schema objects. items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.extensions.v1beta1.networkPolicy, mixin:: { }, }, // Pod Security Policy governs the ability to make requests that affect the Security Context that will be applied to a pod and container. podSecurityPolicy:: { local kind = {kind: "PodSecurityPolicy"}, new():: apiVersion + kind, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // spec defines the policy enforced. spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // AllowedCapabilities is a list of capabilities that can be requested to add to the container. Capabilities in this field may be added at the pod author's discretion. You must not list a capability in both AllowedCapabilities and RequiredDropCapabilities. allowedCapabilities(allowedCapabilities):: if std.type(allowedCapabilities) == "array" then __specMixin({allowedCapabilities+: allowedCapabilities}) else __specMixin({allowedCapabilities+: [allowedCapabilities]}), // DefaultAddCapabilities is the default set of capabilities that will be added to the container unless the pod spec specifically drops the capability. You may not list a capabiility in both DefaultAddCapabilities and RequiredDropCapabilities. defaultAddCapabilities(defaultAddCapabilities):: if std.type(defaultAddCapabilities) == "array" then __specMixin({defaultAddCapabilities+: defaultAddCapabilities}) else __specMixin({defaultAddCapabilities+: [defaultAddCapabilities]}), // FSGroup is the strategy that will dictate what fs group is used by the SecurityContext. fsGroup:: { local __fsGroupMixin(fsGroup) = __specMixin({fsGroup+: fsGroup}), mixinInstance(fsGroup):: __fsGroupMixin(fsGroup), // Ranges are the allowed ranges of fs groups. If you would like to force a single fs group then supply a single range with the same start and end. ranges(ranges):: if std.type(ranges) == "array" then __fsGroupMixin({ranges+: ranges}) else __fsGroupMixin({ranges+: [ranges]}), rangesType:: hidden.extensions.v1beta1.idRange, // Rule is the strategy that will dictate what FSGroup is used in the SecurityContext. rule(rule):: __fsGroupMixin({rule: rule}), }, fsGroupType:: hidden.extensions.v1beta1.fsGroupStrategyOptions, // hostIPC determines if the policy allows the use of HostIPC in the pod spec. hostIpc(hostIpc):: __specMixin({hostIPC: hostIpc}), // hostNetwork determines if the policy allows the use of HostNetwork in the pod spec. hostNetwork(hostNetwork):: __specMixin({hostNetwork: hostNetwork}), // hostPID determines if the policy allows the use of HostPID in the pod spec. hostPid(hostPid):: __specMixin({hostPID: hostPid}), // hostPorts determines which host port ranges are allowed to be exposed. hostPorts(hostPorts):: if std.type(hostPorts) == "array" then __specMixin({hostPorts+: hostPorts}) else __specMixin({hostPorts+: [hostPorts]}), hostPortsType:: hidden.extensions.v1beta1.hostPortRange, // privileged determines if a pod can request to be run as privileged. privileged(privileged):: __specMixin({privileged: privileged}), // ReadOnlyRootFilesystem when set to true will force containers to run with a read only root file system. If the container specifically requests to run with a non-read only root file system the PSP should deny the pod. If set to false the container may run with a read only root file system if it wishes but it will not be forced to. readOnlyRootFilesystem(readOnlyRootFilesystem):: __specMixin({readOnlyRootFilesystem: readOnlyRootFilesystem}), // RequiredDropCapabilities are the capabilities that will be dropped from the container. These are required to be dropped and cannot be added. requiredDropCapabilities(requiredDropCapabilities):: if std.type(requiredDropCapabilities) == "array" then __specMixin({requiredDropCapabilities+: requiredDropCapabilities}) else __specMixin({requiredDropCapabilities+: [requiredDropCapabilities]}), // runAsUser is the strategy that will dictate the allowable RunAsUser values that may be set. runAsUser:: { local __runAsUserMixin(runAsUser) = __specMixin({runAsUser+: runAsUser}), mixinInstance(runAsUser):: __runAsUserMixin(runAsUser), // Ranges are the allowed ranges of uids that may be used. ranges(ranges):: if std.type(ranges) == "array" then __runAsUserMixin({ranges+: ranges}) else __runAsUserMixin({ranges+: [ranges]}), rangesType:: hidden.extensions.v1beta1.idRange, // Rule is the strategy that will dictate the allowable RunAsUser values that may be set. rule(rule):: __runAsUserMixin({rule: rule}), }, runAsUserType:: hidden.extensions.v1beta1.runAsUserStrategyOptions, // seLinux is the strategy that will dictate the allowable labels that may be set. seLinux:: { local __seLinuxMixin(seLinux) = __specMixin({seLinux+: seLinux}), mixinInstance(seLinux):: __seLinuxMixin(seLinux), // type is the strategy that will dictate the allowable labels that may be set. rule(rule):: __seLinuxMixin({rule: rule}), // seLinuxOptions required to run as; required for MustRunAs More info: https://git.k8s.io/community/contributors/design-proposals/security_context.md seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = __seLinuxMixin({seLinuxOptions+: seLinuxOptions}), mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, }, seLinuxType:: hidden.extensions.v1beta1.seLinuxStrategyOptions, // SupplementalGroups is the strategy that will dictate what supplemental groups are used by the SecurityContext. supplementalGroups:: { local __supplementalGroupsMixin(supplementalGroups) = __specMixin({supplementalGroups+: supplementalGroups}), mixinInstance(supplementalGroups):: __supplementalGroupsMixin(supplementalGroups), // Ranges are the allowed ranges of supplemental groups. If you would like to force a single supplemental group then supply a single range with the same start and end. ranges(ranges):: if std.type(ranges) == "array" then __supplementalGroupsMixin({ranges+: ranges}) else __supplementalGroupsMixin({ranges+: [ranges]}), rangesType:: hidden.extensions.v1beta1.idRange, // Rule is the strategy that will dictate what supplemental groups is used in the SecurityContext. rule(rule):: __supplementalGroupsMixin({rule: rule}), }, supplementalGroupsType:: hidden.extensions.v1beta1.supplementalGroupsStrategyOptions, // volumes is a white list of allowed volume plugins. Empty indicates that all plugins may be used. volumes(volumes):: if std.type(volumes) == "array" then __specMixin({volumes+: volumes}) else __specMixin({volumes+: [volumes]}), }, specType:: hidden.extensions.v1beta1.podSecurityPolicySpec, }, }, // Pod Security Policy List is a list of PodSecurityPolicy objects. podSecurityPolicyList:: { local kind = {kind: "PodSecurityPolicyList"}, new():: apiVersion + kind, // Items is a list of schema objects. items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.extensions.v1beta1.podSecurityPolicy, mixin:: { }, }, // ReplicaSet represents the configuration of a ReplicaSet. replicaSet:: { local kind = {kind: "ReplicaSet"}, new():: apiVersion + kind, mixin:: { // If the Labels of a ReplicaSet are empty, they are defaulted to be the same as the Pod(s) that the ReplicaSet manages. Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Spec defines the specification of the desired behavior of the ReplicaSet. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // Minimum number of seconds for which a newly created pod should be ready without any of its container crashing, for it to be considered available. Defaults to 0 (pod will be considered available as soon as it is ready) minReadySeconds(minReadySeconds):: __specMixin({minReadySeconds: minReadySeconds}), // Replicas is the number of desired replicas. This is a pointer to distinguish between explicit zero and unspecified. Defaults to 1. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller/#what-is-a-replicationcontroller replicas(replicas):: __specMixin({replicas: replicas}), // Selector is a label query over pods that should match the replica count. If the selector is empty, it is defaulted to the labels present on the pod template. Label keys and values that must match in order to be controlled by this replica set. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors selector:: { local __selectorMixin(selector) = __specMixin({selector+: selector}), mixinInstance(selector):: __selectorMixin(selector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __selectorMixin({matchExpressions+: matchExpressions}) else __selectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __selectorMixin({matchLabels+: matchLabels}), }, selectorType:: hidden.meta.v1.labelSelector, // Template is the object that describes the pod that will be created if insufficient replicas are detected. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#pod-template template:: { local __templateMixin(template) = __specMixin({template+: template}), mixinInstance(template):: __templateMixin(template), // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = __templateMixin({metadata+: metadata}), mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = __templateMixin({spec+: spec}), mixinInstance(spec):: __specMixin(spec), // Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer. activeDeadlineSeconds(activeDeadlineSeconds):: __specMixin({activeDeadlineSeconds: activeDeadlineSeconds}), // If specified, the pod's scheduling constraints affinity:: { local __affinityMixin(affinity) = __specMixin({affinity+: affinity}), mixinInstance(affinity):: __affinityMixin(affinity), // Describes node affinity scheduling rules for the pod. nodeAffinity:: { local __nodeAffinityMixin(nodeAffinity) = __affinityMixin({nodeAffinity+: nodeAffinity}), mixinInstance(nodeAffinity):: __nodeAffinityMixin(nodeAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.preferredSchedulingTerm, // If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node. requiredDuringSchedulingIgnoredDuringExecution:: { local __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution) = __nodeAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}), mixinInstance(requiredDuringSchedulingIgnoredDuringExecution):: __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution), // Required. A list of node selector terms. The terms are ORed. nodeSelectorTerms(nodeSelectorTerms):: if std.type(nodeSelectorTerms) == "array" then __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: nodeSelectorTerms}) else __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: [nodeSelectorTerms]}), nodeSelectorTermsType:: hidden.core.v1.nodeSelectorTerm, }, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.nodeSelector, }, nodeAffinityType:: hidden.core.v1.nodeAffinity, // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)). podAffinity:: { local __podAffinityMixin(podAffinity) = __affinityMixin({podAffinity+: podAffinity}), mixinInstance(podAffinity):: __podAffinityMixin(podAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAffinityType:: hidden.core.v1.podAffinity, // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)). podAntiAffinity:: { local __podAntiAffinityMixin(podAntiAffinity) = __affinityMixin({podAntiAffinity+: podAntiAffinity}), mixinInstance(podAntiAffinity):: __podAntiAffinityMixin(podAntiAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAntiAffinityType:: hidden.core.v1.podAntiAffinity, }, affinityType:: hidden.core.v1.affinity, // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted. automountServiceAccountToken(automountServiceAccountToken):: __specMixin({automountServiceAccountToken: automountServiceAccountToken}), // List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated. containers(containers):: if std.type(containers) == "array" then __specMixin({containers+: containers}) else __specMixin({containers+: [containers]}), containersType:: hidden.core.v1.container, // Set DNS policy for containers within the pod. One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. Defaults to "ClusterFirst". To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. dnsPolicy(dnsPolicy):: __specMixin({dnsPolicy: dnsPolicy}), // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts file if specified. This is only valid for non-hostNetwork pods. hostAliases(hostAliases):: if std.type(hostAliases) == "array" then __specMixin({hostAliases+: hostAliases}) else __specMixin({hostAliases+: [hostAliases]}), hostAliasesType:: hidden.core.v1.hostAlias, // Use the host's ipc namespace. Optional: Default to false. hostIpc(hostIpc):: __specMixin({hostIPC: hostIpc}), // Host networking requested for this pod. Use the host's network namespace. If this option is set, the ports that will be used must be specified. Default to false. hostNetwork(hostNetwork):: __specMixin({hostNetwork: hostNetwork}), // Use the host's pid namespace. Optional: Default to false. hostPid(hostPid):: __specMixin({hostPID: hostPid}), // Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value. hostname(hostname):: __specMixin({hostname: hostname}), // 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. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod imagePullSecrets(imagePullSecrets):: if std.type(imagePullSecrets) == "array" then __specMixin({imagePullSecrets+: imagePullSecrets}) else __specMixin({imagePullSecrets+: [imagePullSecrets]}), imagePullSecretsType:: hidden.core.v1.localObjectReference, // List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ initContainers(initContainers):: if std.type(initContainers) == "array" then __specMixin({initContainers+: initContainers}) else __specMixin({initContainers+: [initContainers]}), initContainersType:: hidden.core.v1.container, // NodeName is a request to schedule this pod onto a specific node. If it is non-empty, the scheduler simply schedules this pod onto that node, assuming that it fits resource requirements. nodeName(nodeName):: __specMixin({nodeName: nodeName}), // NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ nodeSelector(nodeSelector):: __specMixin({nodeSelector+: nodeSelector}), // Restart policy for all containers within the pod. One of Always, OnFailure, Never. Default to Always. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy restartPolicy(restartPolicy):: __specMixin({restartPolicy: restartPolicy}), // If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler. schedulerName(schedulerName):: __specMixin({schedulerName: schedulerName}), // SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field. securityContext:: { local __securityContextMixin(securityContext) = __specMixin({securityContext+: securityContext}), mixinInstance(securityContext):: __securityContextMixin(securityContext), // A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod: // // 1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw---- // // If unset, the Kubelet will not modify the ownership and permissions of any volume. fsGroup(fsGroup):: __securityContextMixin({fsGroup: fsGroup}), // Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsNonRoot(runAsNonRoot):: __securityContextMixin({runAsNonRoot: runAsNonRoot}), // The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. runAsUser(runAsUser):: __securityContextMixin({runAsUser: runAsUser}), // The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = __securityContextMixin({seLinuxOptions+: seLinuxOptions}), mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, // A list of groups applied to the first process run in each container, in addition to the container's primary GID. If unspecified, no groups will be added to any container. supplementalGroups(supplementalGroups):: if std.type(supplementalGroups) == "array" then __securityContextMixin({supplementalGroups+: supplementalGroups}) else __securityContextMixin({supplementalGroups+: [supplementalGroups]}), }, securityContextType:: hidden.core.v1.podSecurityContext, // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead. serviceAccount(serviceAccount):: __specMixin({serviceAccount: serviceAccount}), // ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ serviceAccountName(serviceAccountName):: __specMixin({serviceAccountName: serviceAccountName}), // If specified, the fully qualified Pod hostname will be "...svc.". If not specified, the pod will not have a domainname at all. subdomain(subdomain):: __specMixin({subdomain: subdomain}), // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds. terminationGracePeriodSeconds(terminationGracePeriodSeconds):: __specMixin({terminationGracePeriodSeconds: terminationGracePeriodSeconds}), // If specified, the pod's tolerations. tolerations(tolerations):: if std.type(tolerations) == "array" then __specMixin({tolerations+: tolerations}) else __specMixin({tolerations+: [tolerations]}), tolerationsType:: hidden.core.v1.toleration, // List of volumes that can be mounted by containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes volumes(volumes):: if std.type(volumes) == "array" then __specMixin({volumes+: volumes}) else __specMixin({volumes+: [volumes]}), volumesType:: hidden.core.v1.volume, }, specType:: hidden.core.v1.podSpec, }, templateType:: hidden.core.v1.podTemplateSpec, }, specType:: hidden.extensions.v1beta1.replicaSetSpec, }, }, // ReplicaSetList is a collection of ReplicaSets. replicaSetList:: { local kind = {kind: "ReplicaSetList"}, new():: apiVersion + kind, // List of ReplicaSets. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.extensions.v1beta1.replicaSet, mixin:: { }, }, // represents a scaling request for a resource. scale:: { local kind = {kind: "Scale"}, new():: apiVersion + kind, mixin:: { // Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata. metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // defines the behavior of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // desired number of instances for the scaled object. replicas(replicas):: __specMixin({replicas: replicas}), }, specType:: hidden.extensions.v1beta1.scaleSpec, }, }, // A ThirdPartyResource is a generic representation of a resource, it is used by add-ons and plugins to add new resource types to the API. It consists of one or more Versions of the api. thirdPartyResource:: { local kind = {kind: "ThirdPartyResource"}, new():: apiVersion + kind, // Description is the description of this object. description(description):: {description: description}, // Versions are versions for this third party object versions(versions):: if std.type(versions) == "array" then {versions+: versions} else {versions+: [versions]}, versionsType:: hidden.extensions.v1beta1.apiVersion, mixin:: { // Standard object metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, }, }, // ThirdPartyResourceList is a list of ThirdPartyResources. thirdPartyResourceList:: { local kind = {kind: "ThirdPartyResourceList"}, new():: apiVersion + kind, // Items is the list of ThirdPartyResources. items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.extensions.v1beta1.thirdPartyResource, mixin:: { }, }, }, }, networking:: { v1:: { local apiVersion = {apiVersion: "networking.k8s.io/v1"}, // NetworkPolicy describes what network traffic is allowed for a set of Pods networkPolicy:: { local kind = {kind: "NetworkPolicy"}, new():: apiVersion + kind, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior for this NetworkPolicy. spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // List of ingress rules to be applied to the selected pods. Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod (and cluster policy otherwise allows the traffic), OR if the traffic source is the pod's local node, OR if the traffic matches at least one ingress rule across all of the NetworkPolicy objects whose podSelector matches the pod. If this field is empty then this NetworkPolicy does not allow any traffic (and serves solely to ensure that the pods it selects are isolated by default) ingress(ingress):: if std.type(ingress) == "array" then __specMixin({ingress+: ingress}) else __specMixin({ingress+: [ingress]}), ingressType:: hidden.networking.v1.networkPolicyIngressRule, // Selects the pods to which this NetworkPolicy object applies. The array of ingress rules is applied to any pods selected by this field. Multiple network policies can select the same set of pods. In this case, the ingress rules for each are combined additively. This field is NOT optional and follows standard label selector semantics. An empty podSelector matches all pods in this namespace. podSelector:: { local __podSelectorMixin(podSelector) = __specMixin({podSelector+: podSelector}), mixinInstance(podSelector):: __podSelectorMixin(podSelector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __podSelectorMixin({matchExpressions+: matchExpressions}) else __podSelectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __podSelectorMixin({matchLabels+: matchLabels}), }, podSelectorType:: hidden.meta.v1.labelSelector, }, specType:: hidden.networking.v1.networkPolicySpec, }, }, // NetworkPolicyList is a list of NetworkPolicy objects. networkPolicyList:: { local kind = {kind: "NetworkPolicyList"}, new():: apiVersion + kind, // Items is a list of schema objects. items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.networking.v1.networkPolicy, mixin:: { // Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // String that identifies the server's internal version of this object that can be used by clients to determine when objects have changed. Value must be treated as opaque by clients and passed unmodified back to the server. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency resourceVersion(resourceVersion):: __metadataMixin({resourceVersion: resourceVersion}), // SelfLink is a URL representing this object. Populated by the system. Read-only. selfLink(selfLink):: __metadataMixin({selfLink: selfLink}), }, metadataType:: hidden.meta.v1.listMeta, }, }, }, }, policy:: { v1beta1:: { local apiVersion = {apiVersion: "policy/v1beta1"}, // Eviction evicts a pod from its node subject to certain policies and safety constraints. This is a subresource of Pod. A request to cause such an eviction is created by POSTing to .../pods//evictions. eviction:: { local kind = {kind: "Eviction"}, new():: apiVersion + kind, mixin:: { // DeleteOptions may be provided deleteOptions:: { local __deleteOptionsMixin(deleteOptions) = {deleteOptions+: deleteOptions}, mixinInstance(deleteOptions):: __deleteOptionsMixin(deleteOptions), // The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. gracePeriodSeconds(gracePeriodSeconds):: __deleteOptionsMixin({gracePeriodSeconds: gracePeriodSeconds}), // Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the "orphan" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. orphanDependents(orphanDependents):: __deleteOptionsMixin({orphanDependents: orphanDependents}), // Must be fulfilled before a deletion is carried out. If not possible, a 409 Conflict status will be returned. preconditions:: { local __preconditionsMixin(preconditions) = __deleteOptionsMixin({preconditions+: preconditions}), mixinInstance(preconditions):: __preconditionsMixin(preconditions), // Specifies the target UID. uid(uid):: __preconditionsMixin({uid: uid}), }, preconditionsType:: hidden.meta.v1.preconditions, // Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. propagationPolicy(propagationPolicy):: __deleteOptionsMixin({propagationPolicy: propagationPolicy}), }, deleteOptionsType:: hidden.meta.v1.deleteOptions, // ObjectMeta describes the pod that is being evicted. metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, }, }, // PodDisruptionBudget is an object to define the max disruption that can be caused to a collection of pods podDisruptionBudget:: { local kind = {kind: "PodDisruptionBudget"}, new():: apiVersion + kind, mixin:: { // metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the PodDisruptionBudget. spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // An eviction is allowed if at most "maxUnavailable" pods selected by "selector" are unavailable after the eviction, i.e. even in absence of the evicted pod. For example, one can prevent all voluntary evictions by specifying 0. This is a mutually exclusive setting with "minAvailable". maxUnavailable(maxUnavailable):: __specMixin({maxUnavailable: maxUnavailable}), // An eviction is allowed if at least "minAvailable" pods selected by "selector" will still be available after the eviction, i.e. even in the absence of the evicted pod. So for example you can prevent all voluntary evictions by specifying "100%". minAvailable(minAvailable):: __specMixin({minAvailable: minAvailable}), // Label query over pods whose evictions are managed by the disruption budget. selector:: { local __selectorMixin(selector) = __specMixin({selector+: selector}), mixinInstance(selector):: __selectorMixin(selector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __selectorMixin({matchExpressions+: matchExpressions}) else __selectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __selectorMixin({matchLabels+: matchLabels}), }, selectorType:: hidden.meta.v1.labelSelector, }, specType:: hidden.policy.v1beta1.podDisruptionBudgetSpec, }, }, // PodDisruptionBudgetList is a collection of PodDisruptionBudgets. podDisruptionBudgetList:: { local kind = {kind: "PodDisruptionBudgetList"}, new():: apiVersion + kind, // items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.policy.v1beta1.podDisruptionBudget, mixin:: { }, }, }, }, rbac:: { v1alpha1:: { local apiVersion = {apiVersion: "rbac.authorization.k8s.io/v1alpha1"}, // ClusterRole is a cluster level, logical grouping of PolicyRules that can be referenced as a unit by a RoleBinding or ClusterRoleBinding. clusterRole:: { local kind = {kind: "ClusterRole"}, new():: apiVersion + kind, // Rules holds all the PolicyRules for this ClusterRole rules(rules):: if std.type(rules) == "array" then {rules+: rules} else {rules+: [rules]}, rulesType:: hidden.rbac.v1alpha1.policyRule, mixin:: { // Standard object's metadata. metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, }, }, // ClusterRoleBinding references a ClusterRole, but not contain it. It can reference a ClusterRole in the global namespace, and adds who information via Subject. clusterRoleBinding:: { local kind = {kind: "ClusterRoleBinding"}, new():: apiVersion + kind, // Subjects holds references to the objects the role applies to. subjects(subjects):: if std.type(subjects) == "array" then {subjects+: subjects} else {subjects+: [subjects]}, subjectsType:: hidden.rbac.v1alpha1.subject, mixin:: { // Standard object's metadata. metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // RoleRef can only reference a ClusterRole in the global namespace. If the RoleRef cannot be resolved, the Authorizer must return an error. roleRef:: { local __roleRefMixin(roleRef) = {roleRef+: roleRef}, mixinInstance(roleRef):: __roleRefMixin(roleRef), // APIGroup is the group for the resource being referenced apiGroup(apiGroup):: __roleRefMixin({apiGroup: apiGroup}), // Name is the name of resource being referenced name(name):: __roleRefMixin({name: name}), }, roleRefType:: hidden.rbac.v1alpha1.roleRef, }, }, // ClusterRoleBindingList is a collection of ClusterRoleBindings clusterRoleBindingList:: { local kind = {kind: "ClusterRoleBindingList"}, new():: apiVersion + kind, // Items is a list of ClusterRoleBindings items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.rbac.v1alpha1.clusterRoleBinding, mixin:: { }, }, // ClusterRoleList is a collection of ClusterRoles clusterRoleList:: { local kind = {kind: "ClusterRoleList"}, new():: apiVersion + kind, // Items is a list of ClusterRoles items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.rbac.v1alpha1.clusterRole, mixin:: { }, }, // Role is a namespaced, logical grouping of PolicyRules that can be referenced as a unit by a RoleBinding. role:: { local kind = {kind: "Role"}, new():: apiVersion + kind, // Rules holds all the PolicyRules for this Role rules(rules):: if std.type(rules) == "array" then {rules+: rules} else {rules+: [rules]}, rulesType:: hidden.rbac.v1alpha1.policyRule, mixin:: { // Standard object's metadata. metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, }, }, // RoleBinding references a role, but does not contain it. It can reference a Role in the same namespace or a ClusterRole in the global namespace. It adds who information via Subjects and namespace information by which namespace it exists in. RoleBindings in a given namespace only have effect in that namespace. roleBinding:: { local kind = {kind: "RoleBinding"}, new():: apiVersion + kind, // Subjects holds references to the objects the role applies to. subjects(subjects):: if std.type(subjects) == "array" then {subjects+: subjects} else {subjects+: [subjects]}, subjectsType:: hidden.rbac.v1alpha1.subject, mixin:: { // Standard object's metadata. metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // RoleRef can reference a Role in the current namespace or a ClusterRole in the global namespace. If the RoleRef cannot be resolved, the Authorizer must return an error. roleRef:: { local __roleRefMixin(roleRef) = {roleRef+: roleRef}, mixinInstance(roleRef):: __roleRefMixin(roleRef), // APIGroup is the group for the resource being referenced apiGroup(apiGroup):: __roleRefMixin({apiGroup: apiGroup}), // Name is the name of resource being referenced name(name):: __roleRefMixin({name: name}), }, roleRefType:: hidden.rbac.v1alpha1.roleRef, }, }, // RoleBindingList is a collection of RoleBindings roleBindingList:: { local kind = {kind: "RoleBindingList"}, new():: apiVersion + kind, // Items is a list of RoleBindings items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.rbac.v1alpha1.roleBinding, mixin:: { }, }, // RoleList is a collection of Roles roleList:: { local kind = {kind: "RoleList"}, new():: apiVersion + kind, // Items is a list of Roles items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.rbac.v1alpha1.role, mixin:: { }, }, }, v1beta1:: { local apiVersion = {apiVersion: "rbac.authorization.k8s.io/v1beta1"}, // ClusterRole is a cluster level, logical grouping of PolicyRules that can be referenced as a unit by a RoleBinding or ClusterRoleBinding. clusterRole:: { local kind = {kind: "ClusterRole"}, new():: apiVersion + kind, // Rules holds all the PolicyRules for this ClusterRole rules(rules):: if std.type(rules) == "array" then {rules+: rules} else {rules+: [rules]}, rulesType:: hidden.rbac.v1beta1.policyRule, mixin:: { // Standard object's metadata. metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, }, }, // ClusterRoleBinding references a ClusterRole, but not contain it. It can reference a ClusterRole in the global namespace, and adds who information via Subject. clusterRoleBinding:: { local kind = {kind: "ClusterRoleBinding"}, new():: apiVersion + kind, // Subjects holds references to the objects the role applies to. subjects(subjects):: if std.type(subjects) == "array" then {subjects+: subjects} else {subjects+: [subjects]}, subjectsType:: hidden.rbac.v1beta1.subject, mixin:: { // Standard object's metadata. metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // RoleRef can only reference a ClusterRole in the global namespace. If the RoleRef cannot be resolved, the Authorizer must return an error. roleRef:: { local __roleRefMixin(roleRef) = {roleRef+: roleRef}, mixinInstance(roleRef):: __roleRefMixin(roleRef), // APIGroup is the group for the resource being referenced apiGroup(apiGroup):: __roleRefMixin({apiGroup: apiGroup}), // Name is the name of resource being referenced name(name):: __roleRefMixin({name: name}), }, roleRefType:: hidden.rbac.v1beta1.roleRef, }, }, // ClusterRoleBindingList is a collection of ClusterRoleBindings clusterRoleBindingList:: { local kind = {kind: "ClusterRoleBindingList"}, new():: apiVersion + kind, // Items is a list of ClusterRoleBindings items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.rbac.v1beta1.clusterRoleBinding, mixin:: { }, }, // ClusterRoleList is a collection of ClusterRoles clusterRoleList:: { local kind = {kind: "ClusterRoleList"}, new():: apiVersion + kind, // Items is a list of ClusterRoles items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.rbac.v1beta1.clusterRole, mixin:: { }, }, // Role is a namespaced, logical grouping of PolicyRules that can be referenced as a unit by a RoleBinding. role:: { local kind = {kind: "Role"}, new():: apiVersion + kind, // Rules holds all the PolicyRules for this Role rules(rules):: if std.type(rules) == "array" then {rules+: rules} else {rules+: [rules]}, rulesType:: hidden.rbac.v1beta1.policyRule, mixin:: { // Standard object's metadata. metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, }, }, // RoleBinding references a role, but does not contain it. It can reference a Role in the same namespace or a ClusterRole in the global namespace. It adds who information via Subjects and namespace information by which namespace it exists in. RoleBindings in a given namespace only have effect in that namespace. roleBinding:: { local kind = {kind: "RoleBinding"}, new():: apiVersion + kind, // Subjects holds references to the objects the role applies to. subjects(subjects):: if std.type(subjects) == "array" then {subjects+: subjects} else {subjects+: [subjects]}, subjectsType:: hidden.rbac.v1beta1.subject, mixin:: { // Standard object's metadata. metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // RoleRef can reference a Role in the current namespace or a ClusterRole in the global namespace. If the RoleRef cannot be resolved, the Authorizer must return an error. roleRef:: { local __roleRefMixin(roleRef) = {roleRef+: roleRef}, mixinInstance(roleRef):: __roleRefMixin(roleRef), // APIGroup is the group for the resource being referenced apiGroup(apiGroup):: __roleRefMixin({apiGroup: apiGroup}), // Name is the name of resource being referenced name(name):: __roleRefMixin({name: name}), }, roleRefType:: hidden.rbac.v1beta1.roleRef, }, }, // RoleBindingList is a collection of RoleBindings roleBindingList:: { local kind = {kind: "RoleBindingList"}, new():: apiVersion + kind, // Items is a list of RoleBindings items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.rbac.v1beta1.roleBinding, mixin:: { }, }, // RoleList is a collection of Roles roleList:: { local kind = {kind: "RoleList"}, new():: apiVersion + kind, // Items is a list of Roles items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.rbac.v1beta1.role, mixin:: { }, }, }, }, settings:: { v1alpha1:: { local apiVersion = {apiVersion: "settings.k8s.io/v1alpha1"}, // PodPreset is a policy resource that defines additional runtime requirements for a Pod. podPreset:: { local kind = {kind: "PodPreset"}, new():: apiVersion + kind, mixin:: { // metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // Env defines the collection of EnvVar to inject into containers. env(env):: if std.type(env) == "array" then __specMixin({env+: env}) else __specMixin({env+: [env]}), // EnvFrom defines the collection of EnvFromSource to inject into containers. envFrom(envFrom):: if std.type(envFrom) == "array" then __specMixin({envFrom+: envFrom}) else __specMixin({envFrom+: [envFrom]}), envFromType:: hidden.core.v1.envFromSource, envType:: hidden.core.v1.envVar, // Selector is a label query over a set of resources, in this case pods. Required. selector:: { local __selectorMixin(selector) = __specMixin({selector+: selector}), mixinInstance(selector):: __selectorMixin(selector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __selectorMixin({matchExpressions+: matchExpressions}) else __selectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __selectorMixin({matchLabels+: matchLabels}), }, selectorType:: hidden.meta.v1.labelSelector, // VolumeMounts defines the collection of VolumeMount to inject into containers. volumeMounts(volumeMounts):: if std.type(volumeMounts) == "array" then __specMixin({volumeMounts+: volumeMounts}) else __specMixin({volumeMounts+: [volumeMounts]}), volumeMountsType:: hidden.core.v1.volumeMount, // Volumes defines the collection of Volume to inject into the pod. volumes(volumes):: if std.type(volumes) == "array" then __specMixin({volumes+: volumes}) else __specMixin({volumes+: [volumes]}), volumesType:: hidden.core.v1.volume, }, specType:: hidden.settings.v1alpha1.podPresetSpec, }, }, // PodPresetList is a list of PodPreset objects. podPresetList:: { local kind = {kind: "PodPresetList"}, new():: apiVersion + kind, // Items is a list of schema objects. items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.settings.v1alpha1.podPreset, mixin:: { }, }, }, }, storage:: { v1:: { local apiVersion = {apiVersion: "storage.k8s.io/v1"}, // StorageClass describes the parameters for a class of storage for which PersistentVolumes can be dynamically provisioned. // // StorageClasses are non-namespaced; the name of the storage class according to etcd is in ObjectMeta.Name. storageClass:: { local kind = {kind: "StorageClass"}, new():: apiVersion + kind, // Parameters holds the parameters for the provisioner that should create volumes of this storage class. parameters(parameters):: {parameters+: parameters}, // Provisioner indicates the type of the provisioner. provisioner(provisioner):: {provisioner: provisioner}, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, }, }, // StorageClassList is a collection of storage classes. storageClassList:: { local kind = {kind: "StorageClassList"}, new():: apiVersion + kind, // Items is the list of StorageClasses items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.storage.v1.storageClass, mixin:: { }, }, }, v1beta1:: { local apiVersion = {apiVersion: "storage.k8s.io/v1beta1"}, // StorageClass describes the parameters for a class of storage for which PersistentVolumes can be dynamically provisioned. // // StorageClasses are non-namespaced; the name of the storage class according to etcd is in ObjectMeta.Name. storageClass:: { local kind = {kind: "StorageClass"}, new():: apiVersion + kind, // Parameters holds the parameters for the provisioner that should create volumes of this storage class. parameters(parameters):: {parameters+: parameters}, // Provisioner indicates the type of the provisioner. provisioner(provisioner):: {provisioner: provisioner}, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, }, }, // StorageClassList is a collection of storage classes. storageClassList:: { local kind = {kind: "StorageClassList"}, new():: apiVersion + kind, // Items is the list of StorageClasses items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.storage.v1beta1.storageClass, mixin:: { }, }, }, }, local hidden = { admissionregistration:: { v1alpha1:: { local apiVersion = {apiVersion: "admissionregistration/v1alpha1"}, // AdmissionHookClientConfig contains the information to make a TLS connection with the webhook admissionHookClientConfig:: { new():: {}, // CABundle is a PEM encoded CA bundle which will be used to validate webhook's server certificate. Required caBundle(caBundle):: {caBundle: caBundle}, mixin:: { // Service is a reference to the service for this webhook. If there is only one port open for the service, that port will be used. If there are multiple ports open, port 443 will be used if it is open, otherwise it is an error. Required service:: { local __serviceMixin(service) = {service+: service}, mixinInstance(service):: __serviceMixin(service), // Name is the name of the service Required name(name):: __serviceMixin({name: name}), // Namespace is the namespace of the service Required namespace(namespace):: __serviceMixin({namespace: namespace}), }, serviceType:: hidden.admissionregistration.v1alpha1.serviceReference, }, }, // ExternalAdmissionHook describes an external admission webhook and the resources and operations it applies to. externalAdmissionHook:: { new():: {}, // FailurePolicy defines how unrecognized errors from the admission endpoint are handled - allowed values are Ignore or Fail. Defaults to Ignore. failurePolicy(failurePolicy):: {failurePolicy: failurePolicy}, // The name of the external admission webhook. Name should be fully qualified, e.g., imagepolicy.kubernetes.io, where "imagepolicy" is the name of the webhook, and kubernetes.io is the name of the organization. Required. name(name):: {name: name}, // Rules describes what operations on what resources/subresources the webhook cares about. The webhook cares about an operation if it matches _any_ Rule. rules(rules):: if std.type(rules) == "array" then {rules+: rules} else {rules+: [rules]}, rulesType:: hidden.admissionregistration.v1alpha1.ruleWithOperations, mixin:: { // ClientConfig defines how to communicate with the hook. Required clientConfig:: { local __clientConfigMixin(clientConfig) = {clientConfig+: clientConfig}, mixinInstance(clientConfig):: __clientConfigMixin(clientConfig), // CABundle is a PEM encoded CA bundle which will be used to validate webhook's server certificate. Required caBundle(caBundle):: __clientConfigMixin({caBundle: caBundle}), // Service is a reference to the service for this webhook. If there is only one port open for the service, that port will be used. If there are multiple ports open, port 443 will be used if it is open, otherwise it is an error. Required service:: { local __serviceMixin(service) = __clientConfigMixin({service+: service}), mixinInstance(service):: __serviceMixin(service), // Name is the name of the service Required name(name):: __serviceMixin({name: name}), // Namespace is the namespace of the service Required namespace(namespace):: __serviceMixin({namespace: namespace}), }, serviceType:: hidden.admissionregistration.v1alpha1.serviceReference, }, clientConfigType:: hidden.admissionregistration.v1alpha1.admissionHookClientConfig, }, }, // Initializer describes the name and the failure policy of an initializer, and what resources it applies to. initializer:: { new():: {}, // FailurePolicy defines what happens if the responsible initializer controller fails to takes action. Allowed values are Ignore, or Fail. If "Ignore" is set, initializer is removed from the initializers list of an object if the timeout is reached; If "Fail" is set, admissionregistration returns timeout error if the timeout is reached. failurePolicy(failurePolicy):: {failurePolicy: failurePolicy}, // Name is the identifier of the initializer. It will be added to the object that needs to be initialized. Name should be fully qualified, e.g., alwayspullimages.kubernetes.io, where "alwayspullimages" is the name of the webhook, and kubernetes.io is the name of the organization. Required name(name):: {name: name}, // Rules describes what resources/subresources the initializer cares about. The initializer cares about an operation if it matches _any_ Rule. Rule.Resources must not include subresources. rules(rules):: if std.type(rules) == "array" then {rules+: rules} else {rules+: [rules]}, rulesType:: hidden.admissionregistration.v1alpha1.rule, mixin:: { }, }, // Rule is a tuple of APIGroups, APIVersion, and Resources.It is recommended to make sure that all the tuple expansions are valid. rule:: { new():: {}, // APIGroups is the API groups the resources belong to. '*' is all groups. If '*' is present, the length of the slice must be one. Required. apiGroups(apiGroups):: if std.type(apiGroups) == "array" then {apiGroups+: apiGroups} else {apiGroups+: [apiGroups]}, // APIVersions is the API versions the resources belong to. '*' is all versions. If '*' is present, the length of the slice must be one. Required. apiVersions(apiVersions):: if std.type(apiVersions) == "array" then {apiVersions+: apiVersions} else {apiVersions+: [apiVersions]}, // Resources is a list of resources this rule applies to. // // For example: 'pods' means pods. 'pods/log' means the log subresource of pods. '*' means all resources, but not subresources. 'pods/*' means all subresources of pods. '*/scale' means all scale subresources. '*/*' means all resources and their subresources. // // If wildcard is present, the validation rule will ensure resources do not overlap with each other. // // Depending on the enclosing object, subresources might not be allowed. Required. resources(resources):: if std.type(resources) == "array" then {resources+: resources} else {resources+: [resources]}, mixin:: { }, }, // RuleWithOperations is a tuple of Operations and Resources. It is recommended to make sure that all the tuple expansions are valid. ruleWithOperations:: { new():: {}, // APIGroups is the API groups the resources belong to. '*' is all groups. If '*' is present, the length of the slice must be one. Required. apiGroups(apiGroups):: if std.type(apiGroups) == "array" then {apiGroups+: apiGroups} else {apiGroups+: [apiGroups]}, // APIVersions is the API versions the resources belong to. '*' is all versions. If '*' is present, the length of the slice must be one. Required. apiVersions(apiVersions):: if std.type(apiVersions) == "array" then {apiVersions+: apiVersions} else {apiVersions+: [apiVersions]}, // Operations is the operations the admission hook cares about - CREATE, UPDATE, or * for all operations. If '*' is present, the length of the slice must be one. Required. operations(operations):: if std.type(operations) == "array" then {operations+: operations} else {operations+: [operations]}, // Resources is a list of resources this rule applies to. // // For example: 'pods' means pods. 'pods/log' means the log subresource of pods. '*' means all resources, but not subresources. 'pods/*' means all subresources of pods. '*/scale' means all scale subresources. '*/*' means all resources and their subresources. // // If wildcard is present, the validation rule will ensure resources do not overlap with each other. // // Depending on the enclosing object, subresources might not be allowed. Required. resources(resources):: if std.type(resources) == "array" then {resources+: resources} else {resources+: [resources]}, mixin:: { }, }, // ServiceReference holds a reference to Service.legacy.k8s.io serviceReference:: { new():: {}, // Name is the name of the service Required name(name):: {name: name}, // Namespace is the namespace of the service Required namespace(namespace):: {namespace: namespace}, mixin:: { }, }, }, }, apiregistration:: { v1beta1:: { local apiVersion = {apiVersion: "apiregistration/v1beta1"}, // APIService represents a server for a particular GroupVersion. Name must be "version.group". aPIService:: { new():: {}, mixin:: { // metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Spec contains information for locating and communicating with a server spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // CABundle is a PEM encoded CA bundle which will be used to validate an API server's serving certificate. caBundle(caBundle):: __specMixin({caBundle: caBundle}), // Group is the API group name this server hosts group(group):: __specMixin({group: group}), // GroupPriorityMininum is the priority this group should have at least. Higher priority means that the group is prefered by clients over lower priority ones. Note that other versions of this group might specify even higher GroupPriorityMininum values such that the whole group gets a higher priority. The primary sort is based on GroupPriorityMinimum, ordered highest number to lowest (20 before 10). The secondary sort is based on the alphabetical comparison of the name of the object. (v1.bar before v1.foo) We'd recommend something like: *.k8s.io (except extensions) at 18000 and PaaSes (OpenShift, Deis) are recommended to be in the 2000s groupPriorityMinimum(groupPriorityMinimum):: __specMixin({groupPriorityMinimum: groupPriorityMinimum}), // InsecureSkipTLSVerify disables TLS certificate verification when communicating with this server. This is strongly discouraged. You should use the CABundle instead. insecureSkipTLSVerify(insecureSkipTLSVerify):: __specMixin({insecureSkipTLSVerify: insecureSkipTLSVerify}), // Service is a reference to the service for this API server. It must communicate on port 443 If the Service is nil, that means the handling for the API groupversion is handled locally on this server. The call will simply delegate to the normal handler chain to be fulfilled. service:: { local __serviceMixin(service) = __specMixin({service+: service}), mixinInstance(service):: __serviceMixin(service), // Name is the name of the service name(name):: __serviceMixin({name: name}), // Namespace is the namespace of the service namespace(namespace):: __serviceMixin({namespace: namespace}), }, serviceType:: hidden.apiregistration.v1beta1.serviceReference, // Version is the API version this server hosts. For example, "v1" version(version):: __specMixin({version: version}), // VersionPriority controls the ordering of this API version inside of its group. Must be greater than zero. The primary sort is based on VersionPriority, ordered highest to lowest (20 before 10). The secondary sort is based on the alphabetical comparison of the name of the object. (v1.bar before v1.foo) Since it's inside of a group, the number can be small, probably in the 10s. versionPriority(versionPriority):: __specMixin({versionPriority: versionPriority}), }, specType:: hidden.apiregistration.v1beta1.aPIServiceSpec, // Status contains derived information about an API server status:: { local __statusMixin(status) = {status+: status}, mixinInstance(status):: __statusMixin(status), // Current service state of apiService. conditions(conditions):: if std.type(conditions) == "array" then __statusMixin({conditions+: conditions}) else __statusMixin({conditions+: [conditions]}), conditionsType:: hidden.apiregistration.v1beta1.aPIServiceCondition, }, statusType:: hidden.apiregistration.v1beta1.aPIServiceStatus, }, }, // aPIServiceCondition:: { new():: {}, // Human-readable message indicating details about last transition. message(message):: {message: message}, // Unique, one-word, CamelCase reason for the condition's last transition. reason(reason):: {reason: reason}, // Status is the status of the condition. Can be True, False, Unknown. status(status):: {status: status}, // Type is the type of the condition. type(type):: {type: type}, mixin:: { // Last time the condition transitioned from one status to another. lastTransitionTime:: { local __lastTransitionTimeMixin(lastTransitionTime) = {lastTransitionTime+: lastTransitionTime}, mixinInstance(lastTransitionTime):: __lastTransitionTimeMixin(lastTransitionTime), }, lastTransitionTimeType:: hidden.meta.v1.time, }, }, // APIServiceList is a list of APIService objects. aPIServiceList:: { new():: {}, // items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.apiregistration.v1beta1.aPIService, mixin:: { // metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // String that identifies the server's internal version of this object that can be used by clients to determine when objects have changed. Value must be treated as opaque by clients and passed unmodified back to the server. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency resourceVersion(resourceVersion):: __metadataMixin({resourceVersion: resourceVersion}), // SelfLink is a URL representing this object. Populated by the system. Read-only. selfLink(selfLink):: __metadataMixin({selfLink: selfLink}), }, metadataType:: hidden.meta.v1.listMeta, }, }, // APIServiceSpec contains information for locating and communicating with a server. Only https is supported, though you are able to disable certificate verification. aPIServiceSpec:: { new():: {}, // CABundle is a PEM encoded CA bundle which will be used to validate an API server's serving certificate. caBundle(caBundle):: {caBundle: caBundle}, // Group is the API group name this server hosts group(group):: {group: group}, // GroupPriorityMininum is the priority this group should have at least. Higher priority means that the group is prefered by clients over lower priority ones. Note that other versions of this group might specify even higher GroupPriorityMininum values such that the whole group gets a higher priority. The primary sort is based on GroupPriorityMinimum, ordered highest number to lowest (20 before 10). The secondary sort is based on the alphabetical comparison of the name of the object. (v1.bar before v1.foo) We'd recommend something like: *.k8s.io (except extensions) at 18000 and PaaSes (OpenShift, Deis) are recommended to be in the 2000s groupPriorityMinimum(groupPriorityMinimum):: {groupPriorityMinimum: groupPriorityMinimum}, // InsecureSkipTLSVerify disables TLS certificate verification when communicating with this server. This is strongly discouraged. You should use the CABundle instead. insecureSkipTLSVerify(insecureSkipTLSVerify):: {insecureSkipTLSVerify: insecureSkipTLSVerify}, // Version is the API version this server hosts. For example, "v1" version(version):: {version: version}, // VersionPriority controls the ordering of this API version inside of its group. Must be greater than zero. The primary sort is based on VersionPriority, ordered highest to lowest (20 before 10). The secondary sort is based on the alphabetical comparison of the name of the object. (v1.bar before v1.foo) Since it's inside of a group, the number can be small, probably in the 10s. versionPriority(versionPriority):: {versionPriority: versionPriority}, mixin:: { // Service is a reference to the service for this API server. It must communicate on port 443 If the Service is nil, that means the handling for the API groupversion is handled locally on this server. The call will simply delegate to the normal handler chain to be fulfilled. service:: { local __serviceMixin(service) = {service+: service}, mixinInstance(service):: __serviceMixin(service), // Name is the name of the service name(name):: __serviceMixin({name: name}), // Namespace is the namespace of the service namespace(namespace):: __serviceMixin({namespace: namespace}), }, serviceType:: hidden.apiregistration.v1beta1.serviceReference, }, }, // APIServiceStatus contains derived information about an API server aPIServiceStatus:: { new():: {}, // Current service state of apiService. conditions(conditions):: if std.type(conditions) == "array" then {conditions+: conditions} else {conditions+: [conditions]}, conditionsType:: hidden.apiregistration.v1beta1.aPIServiceCondition, mixin:: { }, }, // ServiceReference holds a reference to Service.legacy.k8s.io serviceReference:: { new():: {}, // Name is the name of the service name(name):: {name: name}, // Namespace is the namespace of the service namespace(namespace):: {namespace: namespace}, mixin:: { }, }, }, }, apps:: { v1beta1:: { local apiVersion = {apiVersion: "apps/v1beta1"}, // DeploymentCondition describes the state of a deployment at a certain point. deploymentCondition:: { new():: {}, // A human readable message indicating details about the transition. message(message):: {message: message}, // The reason for the condition's last transition. reason(reason):: {reason: reason}, // Type of deployment condition. type(type):: {type: type}, mixin:: { // Last time the condition transitioned from one status to another. lastTransitionTime:: { local __lastTransitionTimeMixin(lastTransitionTime) = {lastTransitionTime+: lastTransitionTime}, mixinInstance(lastTransitionTime):: __lastTransitionTimeMixin(lastTransitionTime), }, lastTransitionTimeType:: hidden.meta.v1.time, // The last time this condition was updated. lastUpdateTime:: { local __lastUpdateTimeMixin(lastUpdateTime) = {lastUpdateTime+: lastUpdateTime}, mixinInstance(lastUpdateTime):: __lastUpdateTimeMixin(lastUpdateTime), }, lastUpdateTimeType:: hidden.meta.v1.time, }, }, // DeploymentSpec is the specification of the desired behavior of the Deployment. deploymentSpec:: { new():: {}, // Minimum number of seconds for which a newly created pod should be ready without any of its container crashing, for it to be considered available. Defaults to 0 (pod will be considered available as soon as it is ready) minReadySeconds(minReadySeconds):: {minReadySeconds: minReadySeconds}, // Indicates that the deployment is paused. paused(paused):: {paused: paused}, // The maximum time in seconds for a deployment to make progress before it is considered to be failed. The deployment controller will continue to process failed deployments and a condition with a ProgressDeadlineExceeded reason will be surfaced in the deployment status. Once autoRollback is implemented, the deployment controller will automatically rollback failed deployments. Note that progress will not be estimated during the time a deployment is paused. Defaults to 600s. progressDeadlineSeconds(progressDeadlineSeconds):: {progressDeadlineSeconds: progressDeadlineSeconds}, // Number of desired pods. This is a pointer to distinguish between explicit zero and not specified. Defaults to 1. replicas(replicas):: {replicas: replicas}, // The number of old ReplicaSets to retain to allow rollback. This is a pointer to distinguish between explicit zero and not specified. Defaults to 2. revisionHistoryLimit(revisionHistoryLimit):: {revisionHistoryLimit: revisionHistoryLimit}, mixin:: { // The config this deployment is rolling back to. Will be cleared after rollback is done. rollbackTo:: { local __rollbackToMixin(rollbackTo) = {rollbackTo+: rollbackTo}, mixinInstance(rollbackTo):: __rollbackToMixin(rollbackTo), // The revision to rollback to. If set to 0, rollback to the last revision. revision(revision):: __rollbackToMixin({revision: revision}), }, rollbackToType:: hidden.apps.v1beta1.rollbackConfig, // Label selector for pods. Existing ReplicaSets whose pods are selected by this will be the ones affected by this deployment. selector:: { local __selectorMixin(selector) = {selector+: selector}, mixinInstance(selector):: __selectorMixin(selector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __selectorMixin({matchExpressions+: matchExpressions}) else __selectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __selectorMixin({matchLabels+: matchLabels}), }, selectorType:: hidden.meta.v1.labelSelector, // The deployment strategy to use to replace existing pods with new ones. strategy:: { local __strategyMixin(strategy) = {strategy+: strategy}, mixinInstance(strategy):: __strategyMixin(strategy), // Rolling update config params. Present only if DeploymentStrategyType = RollingUpdate. rollingUpdate:: { local __rollingUpdateMixin(rollingUpdate) = __strategyMixin({rollingUpdate+: rollingUpdate}), mixinInstance(rollingUpdate):: __rollingUpdateMixin(rollingUpdate), // The maximum number of pods that can be scheduled above the desired number of pods. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). This can not be 0 if MaxUnavailable is 0. Absolute number is calculated from percentage by rounding up. Defaults to 25%. Example: when this is set to 30%, the new RC can be scaled up immediately when the rolling update starts, such that the total number of old and new pods do not exceed 130% of desired pods. Once old pods have been killed, new RC can be scaled up further, ensuring that total number of pods running at any time during the update is atmost 130% of desired pods. maxSurge(maxSurge):: __rollingUpdateMixin({maxSurge: maxSurge}), // The maximum number of pods that can be unavailable during the update. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). Absolute number is calculated from percentage by rounding down. This can not be 0 if MaxSurge is 0. Defaults to 25%. Example: when this is set to 30%, the old RC can be scaled down to 70% of desired pods immediately when the rolling update starts. Once new pods are ready, old RC can be scaled down further, followed by scaling up the new RC, ensuring that the total number of pods available at all times during the update is at least 70% of desired pods. maxUnavailable(maxUnavailable):: __rollingUpdateMixin({maxUnavailable: maxUnavailable}), }, rollingUpdateType:: hidden.apps.v1beta1.rollingUpdateDeployment, // Type of deployment. Can be "Recreate" or "RollingUpdate". Default is RollingUpdate. type(type):: __strategyMixin({type: type}), }, strategyType:: hidden.apps.v1beta1.deploymentStrategy, // Template describes the pods that will be created. template:: { local __templateMixin(template) = {template+: template}, mixinInstance(template):: __templateMixin(template), // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = __templateMixin({metadata+: metadata}), mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = __templateMixin({spec+: spec}), mixinInstance(spec):: __specMixin(spec), // Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer. activeDeadlineSeconds(activeDeadlineSeconds):: __specMixin({activeDeadlineSeconds: activeDeadlineSeconds}), // If specified, the pod's scheduling constraints affinity:: { local __affinityMixin(affinity) = __specMixin({affinity+: affinity}), mixinInstance(affinity):: __affinityMixin(affinity), // Describes node affinity scheduling rules for the pod. nodeAffinity:: { local __nodeAffinityMixin(nodeAffinity) = __affinityMixin({nodeAffinity+: nodeAffinity}), mixinInstance(nodeAffinity):: __nodeAffinityMixin(nodeAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.preferredSchedulingTerm, // If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node. requiredDuringSchedulingIgnoredDuringExecution:: { local __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution) = __nodeAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}), mixinInstance(requiredDuringSchedulingIgnoredDuringExecution):: __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution), // Required. A list of node selector terms. The terms are ORed. nodeSelectorTerms(nodeSelectorTerms):: if std.type(nodeSelectorTerms) == "array" then __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: nodeSelectorTerms}) else __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: [nodeSelectorTerms]}), nodeSelectorTermsType:: hidden.core.v1.nodeSelectorTerm, }, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.nodeSelector, }, nodeAffinityType:: hidden.core.v1.nodeAffinity, // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)). podAffinity:: { local __podAffinityMixin(podAffinity) = __affinityMixin({podAffinity+: podAffinity}), mixinInstance(podAffinity):: __podAffinityMixin(podAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAffinityType:: hidden.core.v1.podAffinity, // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)). podAntiAffinity:: { local __podAntiAffinityMixin(podAntiAffinity) = __affinityMixin({podAntiAffinity+: podAntiAffinity}), mixinInstance(podAntiAffinity):: __podAntiAffinityMixin(podAntiAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAntiAffinityType:: hidden.core.v1.podAntiAffinity, }, affinityType:: hidden.core.v1.affinity, // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted. automountServiceAccountToken(automountServiceAccountToken):: __specMixin({automountServiceAccountToken: automountServiceAccountToken}), // List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated. containers(containers):: if std.type(containers) == "array" then __specMixin({containers+: containers}) else __specMixin({containers+: [containers]}), containersType:: hidden.core.v1.container, // Set DNS policy for containers within the pod. One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. Defaults to "ClusterFirst". To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. dnsPolicy(dnsPolicy):: __specMixin({dnsPolicy: dnsPolicy}), // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts file if specified. This is only valid for non-hostNetwork pods. hostAliases(hostAliases):: if std.type(hostAliases) == "array" then __specMixin({hostAliases+: hostAliases}) else __specMixin({hostAliases+: [hostAliases]}), hostAliasesType:: hidden.core.v1.hostAlias, // Use the host's ipc namespace. Optional: Default to false. hostIpc(hostIpc):: __specMixin({hostIPC: hostIpc}), // Host networking requested for this pod. Use the host's network namespace. If this option is set, the ports that will be used must be specified. Default to false. hostNetwork(hostNetwork):: __specMixin({hostNetwork: hostNetwork}), // Use the host's pid namespace. Optional: Default to false. hostPid(hostPid):: __specMixin({hostPID: hostPid}), // Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value. hostname(hostname):: __specMixin({hostname: hostname}), // 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. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod imagePullSecrets(imagePullSecrets):: if std.type(imagePullSecrets) == "array" then __specMixin({imagePullSecrets+: imagePullSecrets}) else __specMixin({imagePullSecrets+: [imagePullSecrets]}), imagePullSecretsType:: hidden.core.v1.localObjectReference, // List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ initContainers(initContainers):: if std.type(initContainers) == "array" then __specMixin({initContainers+: initContainers}) else __specMixin({initContainers+: [initContainers]}), initContainersType:: hidden.core.v1.container, // NodeName is a request to schedule this pod onto a specific node. If it is non-empty, the scheduler simply schedules this pod onto that node, assuming that it fits resource requirements. nodeName(nodeName):: __specMixin({nodeName: nodeName}), // NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ nodeSelector(nodeSelector):: __specMixin({nodeSelector+: nodeSelector}), // Restart policy for all containers within the pod. One of Always, OnFailure, Never. Default to Always. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy restartPolicy(restartPolicy):: __specMixin({restartPolicy: restartPolicy}), // If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler. schedulerName(schedulerName):: __specMixin({schedulerName: schedulerName}), // SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field. securityContext:: { local __securityContextMixin(securityContext) = __specMixin({securityContext+: securityContext}), mixinInstance(securityContext):: __securityContextMixin(securityContext), // A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod: // // 1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw---- // // If unset, the Kubelet will not modify the ownership and permissions of any volume. fsGroup(fsGroup):: __securityContextMixin({fsGroup: fsGroup}), // Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsNonRoot(runAsNonRoot):: __securityContextMixin({runAsNonRoot: runAsNonRoot}), // The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. runAsUser(runAsUser):: __securityContextMixin({runAsUser: runAsUser}), // The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = __securityContextMixin({seLinuxOptions+: seLinuxOptions}), mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, // A list of groups applied to the first process run in each container, in addition to the container's primary GID. If unspecified, no groups will be added to any container. supplementalGroups(supplementalGroups):: if std.type(supplementalGroups) == "array" then __securityContextMixin({supplementalGroups+: supplementalGroups}) else __securityContextMixin({supplementalGroups+: [supplementalGroups]}), }, securityContextType:: hidden.core.v1.podSecurityContext, // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead. serviceAccount(serviceAccount):: __specMixin({serviceAccount: serviceAccount}), // ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ serviceAccountName(serviceAccountName):: __specMixin({serviceAccountName: serviceAccountName}), // If specified, the fully qualified Pod hostname will be "...svc.". If not specified, the pod will not have a domainname at all. subdomain(subdomain):: __specMixin({subdomain: subdomain}), // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds. terminationGracePeriodSeconds(terminationGracePeriodSeconds):: __specMixin({terminationGracePeriodSeconds: terminationGracePeriodSeconds}), // If specified, the pod's tolerations. tolerations(tolerations):: if std.type(tolerations) == "array" then __specMixin({tolerations+: tolerations}) else __specMixin({tolerations+: [tolerations]}), tolerationsType:: hidden.core.v1.toleration, // List of volumes that can be mounted by containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes volumes(volumes):: if std.type(volumes) == "array" then __specMixin({volumes+: volumes}) else __specMixin({volumes+: [volumes]}), volumesType:: hidden.core.v1.volume, }, specType:: hidden.core.v1.podSpec, }, templateType:: hidden.core.v1.podTemplateSpec, }, }, // DeploymentStatus is the most recently observed status of the Deployment. deploymentStatus:: { new():: {}, // Total number of available pods (ready for at least minReadySeconds) targeted by this deployment. availableReplicas(availableReplicas):: {availableReplicas: availableReplicas}, // Count of hash collisions for the Deployment. The Deployment controller uses this field as a collision avoidance mechanism when it needs to create the name for the newest ReplicaSet. collisionCount(collisionCount):: {collisionCount: collisionCount}, // Represents the latest available observations of a deployment's current state. conditions(conditions):: if std.type(conditions) == "array" then {conditions+: conditions} else {conditions+: [conditions]}, conditionsType:: hidden.apps.v1beta1.deploymentCondition, // The generation observed by the deployment controller. observedGeneration(observedGeneration):: {observedGeneration: observedGeneration}, // Total number of ready pods targeted by this deployment. readyReplicas(readyReplicas):: {readyReplicas: readyReplicas}, // Total number of non-terminated pods targeted by this deployment (their labels match the selector). replicas(replicas):: {replicas: replicas}, // Total number of unavailable pods targeted by this deployment. unavailableReplicas(unavailableReplicas):: {unavailableReplicas: unavailableReplicas}, // Total number of non-terminated pods targeted by this deployment that have the desired template spec. updatedReplicas(updatedReplicas):: {updatedReplicas: updatedReplicas}, mixin:: { }, }, // DeploymentStrategy describes how to replace existing pods with new ones. deploymentStrategy:: { new():: {}, // Type of deployment. Can be "Recreate" or "RollingUpdate". Default is RollingUpdate. type(type):: {type: type}, mixin:: { // Rolling update config params. Present only if DeploymentStrategyType = RollingUpdate. rollingUpdate:: { local __rollingUpdateMixin(rollingUpdate) = {rollingUpdate+: rollingUpdate}, mixinInstance(rollingUpdate):: __rollingUpdateMixin(rollingUpdate), // The maximum number of pods that can be scheduled above the desired number of pods. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). This can not be 0 if MaxUnavailable is 0. Absolute number is calculated from percentage by rounding up. Defaults to 25%. Example: when this is set to 30%, the new RC can be scaled up immediately when the rolling update starts, such that the total number of old and new pods do not exceed 130% of desired pods. Once old pods have been killed, new RC can be scaled up further, ensuring that total number of pods running at any time during the update is atmost 130% of desired pods. maxSurge(maxSurge):: __rollingUpdateMixin({maxSurge: maxSurge}), // The maximum number of pods that can be unavailable during the update. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). Absolute number is calculated from percentage by rounding down. This can not be 0 if MaxSurge is 0. Defaults to 25%. Example: when this is set to 30%, the old RC can be scaled down to 70% of desired pods immediately when the rolling update starts. Once new pods are ready, old RC can be scaled down further, followed by scaling up the new RC, ensuring that the total number of pods available at all times during the update is at least 70% of desired pods. maxUnavailable(maxUnavailable):: __rollingUpdateMixin({maxUnavailable: maxUnavailable}), }, rollingUpdateType:: hidden.apps.v1beta1.rollingUpdateDeployment, }, }, // rollbackConfig:: { new():: {}, // The revision to rollback to. If set to 0, rollback to the last revision. revision(revision):: {revision: revision}, mixin:: { }, }, // Spec to control the desired behavior of rolling update. rollingUpdateDeployment:: { new():: {}, // The maximum number of pods that can be scheduled above the desired number of pods. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). This can not be 0 if MaxUnavailable is 0. Absolute number is calculated from percentage by rounding up. Defaults to 25%. Example: when this is set to 30%, the new RC can be scaled up immediately when the rolling update starts, such that the total number of old and new pods do not exceed 130% of desired pods. Once old pods have been killed, new RC can be scaled up further, ensuring that total number of pods running at any time during the update is atmost 130% of desired pods. maxSurge(maxSurge):: {maxSurge: maxSurge}, // The maximum number of pods that can be unavailable during the update. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). Absolute number is calculated from percentage by rounding down. This can not be 0 if MaxSurge is 0. Defaults to 25%. Example: when this is set to 30%, the old RC can be scaled down to 70% of desired pods immediately when the rolling update starts. Once new pods are ready, old RC can be scaled down further, followed by scaling up the new RC, ensuring that the total number of pods available at all times during the update is at least 70% of desired pods. maxUnavailable(maxUnavailable):: {maxUnavailable: maxUnavailable}, mixin:: { }, }, // RollingUpdateStatefulSetStrategy is used to communicate parameter for RollingUpdateStatefulSetStrategyType. rollingUpdateStatefulSetStrategy:: { new():: {}, // Partition indicates the ordinal at which the StatefulSet should be partitioned. partition(partition):: {partition: partition}, mixin:: { }, }, // ScaleSpec describes the attributes of a scale subresource scaleSpec:: { new():: {}, // desired number of instances for the scaled object. replicas(replicas):: {replicas: replicas}, mixin:: { }, }, // ScaleStatus represents the current status of a scale subresource. scaleStatus:: { new():: {}, // actual number of observed instances of the scaled object. replicas(replicas):: {replicas: replicas}, // label query over pods that should match the replicas count. More info: http://kubernetes.io/docs/user-guide/labels#label-selectors selector(selector):: {selector+: selector}, // label selector for pods that should match the replicas count. This is a serializated version of both map-based and more expressive set-based selectors. This is done to avoid introspection in the clients. The string will be in the same format as the query-param syntax. If the target type only supports map-based selectors, both this field and map-based selector field are populated. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors targetSelector(targetSelector):: {targetSelector: targetSelector}, mixin:: { }, }, // A StatefulSetSpec is the specification of a StatefulSet. statefulSetSpec:: { new():: {}, // podManagementPolicy controls how pods are created during initial scale up, when replacing pods on nodes, or when scaling down. The default policy is `OrderedReady`, where pods are created in increasing order (pod-0, then pod-1, etc) and the controller will wait until each pod is ready before continuing. When scaling down, the pods are removed in the opposite order. The alternative policy is `Parallel` which will create pods in parallel to match the desired scale without waiting, and on scale down will delete all pods at once. podManagementPolicy(podManagementPolicy):: {podManagementPolicy: podManagementPolicy}, // replicas is the desired number of replicas of the given Template. These are replicas in the sense that they are instantiations of the same Template, but individual replicas also have a consistent identity. If unspecified, defaults to 1. replicas(replicas):: {replicas: replicas}, // revisionHistoryLimit is the maximum number of revisions that will be maintained in the StatefulSet's revision history. The revision history consists of all revisions not represented by a currently applied StatefulSetSpec version. The default value is 10. revisionHistoryLimit(revisionHistoryLimit):: {revisionHistoryLimit: revisionHistoryLimit}, // serviceName is the name of the service that governs this StatefulSet. This service must exist before the StatefulSet, and is responsible for the network identity of the set. Pods get DNS/hostnames that follow the pattern: pod-specific-string.serviceName.default.svc.cluster.local where "pod-specific-string" is managed by the StatefulSet controller. serviceName(serviceName):: {serviceName: serviceName}, // volumeClaimTemplates is a list of claims that pods are allowed to reference. The StatefulSet controller is responsible for mapping network identities to claims in a way that maintains the identity of a pod. Every claim in this list must have at least one matching (by name) volumeMount in one container in the template. A claim in this list takes precedence over any volumes in the template, with the same name. volumeClaimTemplates(volumeClaimTemplates):: if std.type(volumeClaimTemplates) == "array" then {volumeClaimTemplates+: volumeClaimTemplates} else {volumeClaimTemplates+: [volumeClaimTemplates]}, volumeClaimTemplatesType:: hidden.core.v1.persistentVolumeClaim, mixin:: { // selector is a label query over pods that should match the replica count. If empty, defaulted to labels on the pod template. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors selector:: { local __selectorMixin(selector) = {selector+: selector}, mixinInstance(selector):: __selectorMixin(selector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __selectorMixin({matchExpressions+: matchExpressions}) else __selectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __selectorMixin({matchLabels+: matchLabels}), }, selectorType:: hidden.meta.v1.labelSelector, // template is the object that describes the pod that will be created if insufficient replicas are detected. Each pod stamped out by the StatefulSet will fulfill this Template, but have a unique identity from the rest of the StatefulSet. template:: { local __templateMixin(template) = {template+: template}, mixinInstance(template):: __templateMixin(template), // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = __templateMixin({metadata+: metadata}), mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = __templateMixin({spec+: spec}), mixinInstance(spec):: __specMixin(spec), // Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer. activeDeadlineSeconds(activeDeadlineSeconds):: __specMixin({activeDeadlineSeconds: activeDeadlineSeconds}), // If specified, the pod's scheduling constraints affinity:: { local __affinityMixin(affinity) = __specMixin({affinity+: affinity}), mixinInstance(affinity):: __affinityMixin(affinity), // Describes node affinity scheduling rules for the pod. nodeAffinity:: { local __nodeAffinityMixin(nodeAffinity) = __affinityMixin({nodeAffinity+: nodeAffinity}), mixinInstance(nodeAffinity):: __nodeAffinityMixin(nodeAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.preferredSchedulingTerm, // If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node. requiredDuringSchedulingIgnoredDuringExecution:: { local __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution) = __nodeAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}), mixinInstance(requiredDuringSchedulingIgnoredDuringExecution):: __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution), // Required. A list of node selector terms. The terms are ORed. nodeSelectorTerms(nodeSelectorTerms):: if std.type(nodeSelectorTerms) == "array" then __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: nodeSelectorTerms}) else __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: [nodeSelectorTerms]}), nodeSelectorTermsType:: hidden.core.v1.nodeSelectorTerm, }, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.nodeSelector, }, nodeAffinityType:: hidden.core.v1.nodeAffinity, // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)). podAffinity:: { local __podAffinityMixin(podAffinity) = __affinityMixin({podAffinity+: podAffinity}), mixinInstance(podAffinity):: __podAffinityMixin(podAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAffinityType:: hidden.core.v1.podAffinity, // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)). podAntiAffinity:: { local __podAntiAffinityMixin(podAntiAffinity) = __affinityMixin({podAntiAffinity+: podAntiAffinity}), mixinInstance(podAntiAffinity):: __podAntiAffinityMixin(podAntiAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAntiAffinityType:: hidden.core.v1.podAntiAffinity, }, affinityType:: hidden.core.v1.affinity, // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted. automountServiceAccountToken(automountServiceAccountToken):: __specMixin({automountServiceAccountToken: automountServiceAccountToken}), // List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated. containers(containers):: if std.type(containers) == "array" then __specMixin({containers+: containers}) else __specMixin({containers+: [containers]}), containersType:: hidden.core.v1.container, // Set DNS policy for containers within the pod. One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. Defaults to "ClusterFirst". To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. dnsPolicy(dnsPolicy):: __specMixin({dnsPolicy: dnsPolicy}), // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts file if specified. This is only valid for non-hostNetwork pods. hostAliases(hostAliases):: if std.type(hostAliases) == "array" then __specMixin({hostAliases+: hostAliases}) else __specMixin({hostAliases+: [hostAliases]}), hostAliasesType:: hidden.core.v1.hostAlias, // Use the host's ipc namespace. Optional: Default to false. hostIpc(hostIpc):: __specMixin({hostIPC: hostIpc}), // Host networking requested for this pod. Use the host's network namespace. If this option is set, the ports that will be used must be specified. Default to false. hostNetwork(hostNetwork):: __specMixin({hostNetwork: hostNetwork}), // Use the host's pid namespace. Optional: Default to false. hostPid(hostPid):: __specMixin({hostPID: hostPid}), // Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value. hostname(hostname):: __specMixin({hostname: hostname}), // 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. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod imagePullSecrets(imagePullSecrets):: if std.type(imagePullSecrets) == "array" then __specMixin({imagePullSecrets+: imagePullSecrets}) else __specMixin({imagePullSecrets+: [imagePullSecrets]}), imagePullSecretsType:: hidden.core.v1.localObjectReference, // List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ initContainers(initContainers):: if std.type(initContainers) == "array" then __specMixin({initContainers+: initContainers}) else __specMixin({initContainers+: [initContainers]}), initContainersType:: hidden.core.v1.container, // NodeName is a request to schedule this pod onto a specific node. If it is non-empty, the scheduler simply schedules this pod onto that node, assuming that it fits resource requirements. nodeName(nodeName):: __specMixin({nodeName: nodeName}), // NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ nodeSelector(nodeSelector):: __specMixin({nodeSelector+: nodeSelector}), // Restart policy for all containers within the pod. One of Always, OnFailure, Never. Default to Always. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy restartPolicy(restartPolicy):: __specMixin({restartPolicy: restartPolicy}), // If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler. schedulerName(schedulerName):: __specMixin({schedulerName: schedulerName}), // SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field. securityContext:: { local __securityContextMixin(securityContext) = __specMixin({securityContext+: securityContext}), mixinInstance(securityContext):: __securityContextMixin(securityContext), // A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod: // // 1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw---- // // If unset, the Kubelet will not modify the ownership and permissions of any volume. fsGroup(fsGroup):: __securityContextMixin({fsGroup: fsGroup}), // Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsNonRoot(runAsNonRoot):: __securityContextMixin({runAsNonRoot: runAsNonRoot}), // The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. runAsUser(runAsUser):: __securityContextMixin({runAsUser: runAsUser}), // The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = __securityContextMixin({seLinuxOptions+: seLinuxOptions}), mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, // A list of groups applied to the first process run in each container, in addition to the container's primary GID. If unspecified, no groups will be added to any container. supplementalGroups(supplementalGroups):: if std.type(supplementalGroups) == "array" then __securityContextMixin({supplementalGroups+: supplementalGroups}) else __securityContextMixin({supplementalGroups+: [supplementalGroups]}), }, securityContextType:: hidden.core.v1.podSecurityContext, // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead. serviceAccount(serviceAccount):: __specMixin({serviceAccount: serviceAccount}), // ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ serviceAccountName(serviceAccountName):: __specMixin({serviceAccountName: serviceAccountName}), // If specified, the fully qualified Pod hostname will be "...svc.". If not specified, the pod will not have a domainname at all. subdomain(subdomain):: __specMixin({subdomain: subdomain}), // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds. terminationGracePeriodSeconds(terminationGracePeriodSeconds):: __specMixin({terminationGracePeriodSeconds: terminationGracePeriodSeconds}), // If specified, the pod's tolerations. tolerations(tolerations):: if std.type(tolerations) == "array" then __specMixin({tolerations+: tolerations}) else __specMixin({tolerations+: [tolerations]}), tolerationsType:: hidden.core.v1.toleration, // List of volumes that can be mounted by containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes volumes(volumes):: if std.type(volumes) == "array" then __specMixin({volumes+: volumes}) else __specMixin({volumes+: [volumes]}), volumesType:: hidden.core.v1.volume, }, specType:: hidden.core.v1.podSpec, }, templateType:: hidden.core.v1.podTemplateSpec, // updateStrategy indicates the StatefulSetUpdateStrategy that will be employed to update Pods in the StatefulSet when a revision is made to Template. updateStrategy:: { local __updateStrategyMixin(updateStrategy) = {updateStrategy+: updateStrategy}, mixinInstance(updateStrategy):: __updateStrategyMixin(updateStrategy), // RollingUpdate is used to communicate parameters when Type is RollingUpdateStatefulSetStrategyType. rollingUpdate:: { local __rollingUpdateMixin(rollingUpdate) = __updateStrategyMixin({rollingUpdate+: rollingUpdate}), mixinInstance(rollingUpdate):: __rollingUpdateMixin(rollingUpdate), // Partition indicates the ordinal at which the StatefulSet should be partitioned. partition(partition):: __rollingUpdateMixin({partition: partition}), }, rollingUpdateType:: hidden.apps.v1beta1.rollingUpdateStatefulSetStrategy, // Type indicates the type of the StatefulSetUpdateStrategy. type(type):: __updateStrategyMixin({type: type}), }, updateStrategyType:: hidden.apps.v1beta1.statefulSetUpdateStrategy, }, }, // StatefulSetStatus represents the current state of a StatefulSet. statefulSetStatus:: { new():: {}, // currentReplicas is the number of Pods created by the StatefulSet controller from the StatefulSet version indicated by currentRevision. currentReplicas(currentReplicas):: {currentReplicas: currentReplicas}, // currentRevision, if not empty, indicates the version of the StatefulSet used to generate Pods in the sequence [0,currentReplicas). currentRevision(currentRevision):: {currentRevision: currentRevision}, // observedGeneration is the most recent generation observed for this StatefulSet. It corresponds to the StatefulSet's generation, which is updated on mutation by the API Server. observedGeneration(observedGeneration):: {observedGeneration: observedGeneration}, // readyReplicas is the number of Pods created by the StatefulSet controller that have a Ready Condition. readyReplicas(readyReplicas):: {readyReplicas: readyReplicas}, // replicas is the number of Pods created by the StatefulSet controller. replicas(replicas):: {replicas: replicas}, // updateRevision, if not empty, indicates the version of the StatefulSet used to generate Pods in the sequence [replicas-updatedReplicas,replicas) updateRevision(updateRevision):: {updateRevision: updateRevision}, // updatedReplicas is the number of Pods created by the StatefulSet controller from the StatefulSet version indicated by updateRevision. updatedReplicas(updatedReplicas):: {updatedReplicas: updatedReplicas}, mixin:: { }, }, // StatefulSetUpdateStrategy indicates the strategy that the StatefulSet controller will use to perform updates. It includes any additional parameters necessary to perform the update for the indicated strategy. statefulSetUpdateStrategy:: { new():: {}, // Type indicates the type of the StatefulSetUpdateStrategy. type(type):: {type: type}, mixin:: { // RollingUpdate is used to communicate parameters when Type is RollingUpdateStatefulSetStrategyType. rollingUpdate:: { local __rollingUpdateMixin(rollingUpdate) = {rollingUpdate+: rollingUpdate}, mixinInstance(rollingUpdate):: __rollingUpdateMixin(rollingUpdate), // Partition indicates the ordinal at which the StatefulSet should be partitioned. partition(partition):: __rollingUpdateMixin({partition: partition}), }, rollingUpdateType:: hidden.apps.v1beta1.rollingUpdateStatefulSetStrategy, }, }, }, }, authentication:: { v1:: { local apiVersion = {apiVersion: "authentication/v1"}, // TokenReviewSpec is a description of the token authentication request. tokenReviewSpec:: { new():: {}, // Token is the opaque bearer token. token(token):: {token: token}, mixin:: { }, }, // TokenReviewStatus is the result of the token authentication request. tokenReviewStatus:: { new():: {}, // Authenticated indicates that the token was associated with a known user. authenticated(authenticated):: {authenticated: authenticated}, mixin:: { // User is the UserInfo associated with the provided token. user:: { local __userMixin(user) = {user+: user}, mixinInstance(user):: __userMixin(user), // Any additional information provided by the authenticator. extra(extra):: __userMixin({extra+: extra}), // The names of groups this user is a part of. groups(groups):: if std.type(groups) == "array" then __userMixin({groups+: groups}) else __userMixin({groups+: [groups]}), // A unique value that identifies this user across time. If this user is deleted and another user by the same name is added, they will have different UIDs. uid(uid):: __userMixin({uid: uid}), // The name that uniquely identifies this user among all active users. username(username):: __userMixin({username: username}), }, userType:: hidden.authentication.v1.userInfo, }, }, // UserInfo holds the information about the user needed to implement the user.Info interface. userInfo:: { new():: {}, // Any additional information provided by the authenticator. extra(extra):: {extra+: extra}, // The names of groups this user is a part of. groups(groups):: if std.type(groups) == "array" then {groups+: groups} else {groups+: [groups]}, // A unique value that identifies this user across time. If this user is deleted and another user by the same name is added, they will have different UIDs. uid(uid):: {uid: uid}, // The name that uniquely identifies this user among all active users. username(username):: {username: username}, mixin:: { }, }, }, v1beta1:: { local apiVersion = {apiVersion: "authentication/v1beta1"}, // TokenReviewSpec is a description of the token authentication request. tokenReviewSpec:: { new():: {}, // Token is the opaque bearer token. token(token):: {token: token}, mixin:: { }, }, // TokenReviewStatus is the result of the token authentication request. tokenReviewStatus:: { new():: {}, // Authenticated indicates that the token was associated with a known user. authenticated(authenticated):: {authenticated: authenticated}, mixin:: { // User is the UserInfo associated with the provided token. user:: { local __userMixin(user) = {user+: user}, mixinInstance(user):: __userMixin(user), // Any additional information provided by the authenticator. extra(extra):: __userMixin({extra+: extra}), // The names of groups this user is a part of. groups(groups):: if std.type(groups) == "array" then __userMixin({groups+: groups}) else __userMixin({groups+: [groups]}), // A unique value that identifies this user across time. If this user is deleted and another user by the same name is added, they will have different UIDs. uid(uid):: __userMixin({uid: uid}), // The name that uniquely identifies this user among all active users. username(username):: __userMixin({username: username}), }, userType:: hidden.authentication.v1beta1.userInfo, }, }, // UserInfo holds the information about the user needed to implement the user.Info interface. userInfo:: { new():: {}, // Any additional information provided by the authenticator. extra(extra):: {extra+: extra}, // The names of groups this user is a part of. groups(groups):: if std.type(groups) == "array" then {groups+: groups} else {groups+: [groups]}, // A unique value that identifies this user across time. If this user is deleted and another user by the same name is added, they will have different UIDs. uid(uid):: {uid: uid}, // The name that uniquely identifies this user among all active users. username(username):: {username: username}, mixin:: { }, }, }, }, authorization:: { v1:: { local apiVersion = {apiVersion: "authorization/v1"}, // NonResourceAttributes includes the authorization attributes available for non-resource requests to the Authorizer interface nonResourceAttributes:: { new():: {}, // Path is the URL path of the request path(path):: {path: path}, // Verb is the standard HTTP verb verb(verb):: {verb: verb}, mixin:: { }, }, // ResourceAttributes includes the authorization attributes available for resource requests to the Authorizer interface resourceAttributes:: { new():: {}, // Group is the API Group of the Resource. "*" means all. group(group):: {group: group}, // Name is the name of the resource being requested for a "get" or deleted for a "delete". "" (empty) means all. name(name):: {name: name}, // Namespace is the namespace of the action being requested. Currently, there is no distinction between no namespace and all namespaces "" (empty) is defaulted for LocalSubjectAccessReviews "" (empty) is empty for cluster-scoped resources "" (empty) means "all" for namespace scoped resources from a SubjectAccessReview or SelfSubjectAccessReview namespace(namespace):: {namespace: namespace}, // Resource is one of the existing resource types. "*" means all. resource(resource):: {resource: resource}, // Subresource is one of the existing resource types. "" means none. subresource(subresource):: {subresource: subresource}, // Verb is a kubernetes resource API verb, like: get, list, watch, create, update, delete, proxy. "*" means all. verb(verb):: {verb: verb}, // Version is the API Version of the Resource. "*" means all. version(version):: {version: version}, mixin:: { }, }, // SelfSubjectAccessReviewSpec is a description of the access request. Exactly one of ResourceAuthorizationAttributes and NonResourceAuthorizationAttributes must be set selfSubjectAccessReviewSpec:: { new():: {}, mixin:: { // NonResourceAttributes describes information for a non-resource access request nonResourceAttributes:: { local __nonResourceAttributesMixin(nonResourceAttributes) = {nonResourceAttributes+: nonResourceAttributes}, mixinInstance(nonResourceAttributes):: __nonResourceAttributesMixin(nonResourceAttributes), // Path is the URL path of the request path(path):: __nonResourceAttributesMixin({path: path}), // Verb is the standard HTTP verb verb(verb):: __nonResourceAttributesMixin({verb: verb}), }, nonResourceAttributesType:: hidden.authorization.v1.nonResourceAttributes, // ResourceAuthorizationAttributes describes information for a resource access request resourceAttributes:: { local __resourceAttributesMixin(resourceAttributes) = {resourceAttributes+: resourceAttributes}, mixinInstance(resourceAttributes):: __resourceAttributesMixin(resourceAttributes), // Group is the API Group of the Resource. "*" means all. group(group):: __resourceAttributesMixin({group: group}), // Name is the name of the resource being requested for a "get" or deleted for a "delete". "" (empty) means all. name(name):: __resourceAttributesMixin({name: name}), // Namespace is the namespace of the action being requested. Currently, there is no distinction between no namespace and all namespaces "" (empty) is defaulted for LocalSubjectAccessReviews "" (empty) is empty for cluster-scoped resources "" (empty) means "all" for namespace scoped resources from a SubjectAccessReview or SelfSubjectAccessReview namespace(namespace):: __resourceAttributesMixin({namespace: namespace}), // Resource is one of the existing resource types. "*" means all. resource(resource):: __resourceAttributesMixin({resource: resource}), // Subresource is one of the existing resource types. "" means none. subresource(subresource):: __resourceAttributesMixin({subresource: subresource}), // Verb is a kubernetes resource API verb, like: get, list, watch, create, update, delete, proxy. "*" means all. verb(verb):: __resourceAttributesMixin({verb: verb}), // Version is the API Version of the Resource. "*" means all. version(version):: __resourceAttributesMixin({version: version}), }, resourceAttributesType:: hidden.authorization.v1.resourceAttributes, }, }, // SubjectAccessReviewSpec is a description of the access request. Exactly one of ResourceAuthorizationAttributes and NonResourceAuthorizationAttributes must be set subjectAccessReviewSpec:: { new():: {}, // Extra corresponds to the user.Info.GetExtra() method from the authenticator. Since that is input to the authorizer it needs a reflection here. extra(extra):: {extra+: extra}, // Groups is the groups you're testing for. groups(groups):: if std.type(groups) == "array" then {groups+: groups} else {groups+: [groups]}, // User is the user you're testing for. If you specify "User" but not "Groups", then is it interpreted as "What if User were not a member of any groups user(user):: {user: user}, mixin:: { // NonResourceAttributes describes information for a non-resource access request nonResourceAttributes:: { local __nonResourceAttributesMixin(nonResourceAttributes) = {nonResourceAttributes+: nonResourceAttributes}, mixinInstance(nonResourceAttributes):: __nonResourceAttributesMixin(nonResourceAttributes), // Path is the URL path of the request path(path):: __nonResourceAttributesMixin({path: path}), // Verb is the standard HTTP verb verb(verb):: __nonResourceAttributesMixin({verb: verb}), }, nonResourceAttributesType:: hidden.authorization.v1.nonResourceAttributes, // ResourceAuthorizationAttributes describes information for a resource access request resourceAttributes:: { local __resourceAttributesMixin(resourceAttributes) = {resourceAttributes+: resourceAttributes}, mixinInstance(resourceAttributes):: __resourceAttributesMixin(resourceAttributes), // Group is the API Group of the Resource. "*" means all. group(group):: __resourceAttributesMixin({group: group}), // Name is the name of the resource being requested for a "get" or deleted for a "delete". "" (empty) means all. name(name):: __resourceAttributesMixin({name: name}), // Namespace is the namespace of the action being requested. Currently, there is no distinction between no namespace and all namespaces "" (empty) is defaulted for LocalSubjectAccessReviews "" (empty) is empty for cluster-scoped resources "" (empty) means "all" for namespace scoped resources from a SubjectAccessReview or SelfSubjectAccessReview namespace(namespace):: __resourceAttributesMixin({namespace: namespace}), // Resource is one of the existing resource types. "*" means all. resource(resource):: __resourceAttributesMixin({resource: resource}), // Subresource is one of the existing resource types. "" means none. subresource(subresource):: __resourceAttributesMixin({subresource: subresource}), // Verb is a kubernetes resource API verb, like: get, list, watch, create, update, delete, proxy. "*" means all. verb(verb):: __resourceAttributesMixin({verb: verb}), // Version is the API Version of the Resource. "*" means all. version(version):: __resourceAttributesMixin({version: version}), }, resourceAttributesType:: hidden.authorization.v1.resourceAttributes, }, }, // SubjectAccessReviewStatus subjectAccessReviewStatus:: { new():: {}, // Allowed is required. True if the action would be allowed, false otherwise. allowed(allowed):: {allowed: allowed}, // EvaluationError is an indication that some error occurred during the authorization check. It is entirely possible to get an error and be able to continue determine authorization status in spite of it. For instance, RBAC can be missing a role, but enough roles are still present and bound to reason about the request. evaluationError(evaluationError):: {evaluationError: evaluationError}, // Reason is optional. It indicates why a request was allowed or denied. reason(reason):: {reason: reason}, mixin:: { }, }, }, v1beta1:: { local apiVersion = {apiVersion: "authorization/v1beta1"}, // NonResourceAttributes includes the authorization attributes available for non-resource requests to the Authorizer interface nonResourceAttributes:: { new():: {}, // Path is the URL path of the request path(path):: {path: path}, // Verb is the standard HTTP verb verb(verb):: {verb: verb}, mixin:: { }, }, // ResourceAttributes includes the authorization attributes available for resource requests to the Authorizer interface resourceAttributes:: { new():: {}, // Group is the API Group of the Resource. "*" means all. group(group):: {group: group}, // Name is the name of the resource being requested for a "get" or deleted for a "delete". "" (empty) means all. name(name):: {name: name}, // Namespace is the namespace of the action being requested. Currently, there is no distinction between no namespace and all namespaces "" (empty) is defaulted for LocalSubjectAccessReviews "" (empty) is empty for cluster-scoped resources "" (empty) means "all" for namespace scoped resources from a SubjectAccessReview or SelfSubjectAccessReview namespace(namespace):: {namespace: namespace}, // Resource is one of the existing resource types. "*" means all. resource(resource):: {resource: resource}, // Subresource is one of the existing resource types. "" means none. subresource(subresource):: {subresource: subresource}, // Verb is a kubernetes resource API verb, like: get, list, watch, create, update, delete, proxy. "*" means all. verb(verb):: {verb: verb}, // Version is the API Version of the Resource. "*" means all. version(version):: {version: version}, mixin:: { }, }, // SelfSubjectAccessReviewSpec is a description of the access request. Exactly one of ResourceAuthorizationAttributes and NonResourceAuthorizationAttributes must be set selfSubjectAccessReviewSpec:: { new():: {}, mixin:: { // NonResourceAttributes describes information for a non-resource access request nonResourceAttributes:: { local __nonResourceAttributesMixin(nonResourceAttributes) = {nonResourceAttributes+: nonResourceAttributes}, mixinInstance(nonResourceAttributes):: __nonResourceAttributesMixin(nonResourceAttributes), // Path is the URL path of the request path(path):: __nonResourceAttributesMixin({path: path}), // Verb is the standard HTTP verb verb(verb):: __nonResourceAttributesMixin({verb: verb}), }, nonResourceAttributesType:: hidden.authorization.v1beta1.nonResourceAttributes, // ResourceAuthorizationAttributes describes information for a resource access request resourceAttributes:: { local __resourceAttributesMixin(resourceAttributes) = {resourceAttributes+: resourceAttributes}, mixinInstance(resourceAttributes):: __resourceAttributesMixin(resourceAttributes), // Group is the API Group of the Resource. "*" means all. group(group):: __resourceAttributesMixin({group: group}), // Name is the name of the resource being requested for a "get" or deleted for a "delete". "" (empty) means all. name(name):: __resourceAttributesMixin({name: name}), // Namespace is the namespace of the action being requested. Currently, there is no distinction between no namespace and all namespaces "" (empty) is defaulted for LocalSubjectAccessReviews "" (empty) is empty for cluster-scoped resources "" (empty) means "all" for namespace scoped resources from a SubjectAccessReview or SelfSubjectAccessReview namespace(namespace):: __resourceAttributesMixin({namespace: namespace}), // Resource is one of the existing resource types. "*" means all. resource(resource):: __resourceAttributesMixin({resource: resource}), // Subresource is one of the existing resource types. "" means none. subresource(subresource):: __resourceAttributesMixin({subresource: subresource}), // Verb is a kubernetes resource API verb, like: get, list, watch, create, update, delete, proxy. "*" means all. verb(verb):: __resourceAttributesMixin({verb: verb}), // Version is the API Version of the Resource. "*" means all. version(version):: __resourceAttributesMixin({version: version}), }, resourceAttributesType:: hidden.authorization.v1beta1.resourceAttributes, }, }, // SubjectAccessReviewSpec is a description of the access request. Exactly one of ResourceAuthorizationAttributes and NonResourceAuthorizationAttributes must be set subjectAccessReviewSpec:: { new():: {}, // Extra corresponds to the user.Info.GetExtra() method from the authenticator. Since that is input to the authorizer it needs a reflection here. extra(extra):: {extra+: extra}, // Groups is the groups you're testing for. group(group):: if std.type(group) == "array" then {group+: group} else {group+: [group]}, // User is the user you're testing for. If you specify "User" but not "Group", then is it interpreted as "What if User were not a member of any groups user(user):: {user: user}, mixin:: { // NonResourceAttributes describes information for a non-resource access request nonResourceAttributes:: { local __nonResourceAttributesMixin(nonResourceAttributes) = {nonResourceAttributes+: nonResourceAttributes}, mixinInstance(nonResourceAttributes):: __nonResourceAttributesMixin(nonResourceAttributes), // Path is the URL path of the request path(path):: __nonResourceAttributesMixin({path: path}), // Verb is the standard HTTP verb verb(verb):: __nonResourceAttributesMixin({verb: verb}), }, nonResourceAttributesType:: hidden.authorization.v1beta1.nonResourceAttributes, // ResourceAuthorizationAttributes describes information for a resource access request resourceAttributes:: { local __resourceAttributesMixin(resourceAttributes) = {resourceAttributes+: resourceAttributes}, mixinInstance(resourceAttributes):: __resourceAttributesMixin(resourceAttributes), // Group is the API Group of the Resource. "*" means all. group(group):: __resourceAttributesMixin({group: group}), // Name is the name of the resource being requested for a "get" or deleted for a "delete". "" (empty) means all. name(name):: __resourceAttributesMixin({name: name}), // Namespace is the namespace of the action being requested. Currently, there is no distinction between no namespace and all namespaces "" (empty) is defaulted for LocalSubjectAccessReviews "" (empty) is empty for cluster-scoped resources "" (empty) means "all" for namespace scoped resources from a SubjectAccessReview or SelfSubjectAccessReview namespace(namespace):: __resourceAttributesMixin({namespace: namespace}), // Resource is one of the existing resource types. "*" means all. resource(resource):: __resourceAttributesMixin({resource: resource}), // Subresource is one of the existing resource types. "" means none. subresource(subresource):: __resourceAttributesMixin({subresource: subresource}), // Verb is a kubernetes resource API verb, like: get, list, watch, create, update, delete, proxy. "*" means all. verb(verb):: __resourceAttributesMixin({verb: verb}), // Version is the API Version of the Resource. "*" means all. version(version):: __resourceAttributesMixin({version: version}), }, resourceAttributesType:: hidden.authorization.v1beta1.resourceAttributes, }, }, // SubjectAccessReviewStatus subjectAccessReviewStatus:: { new():: {}, // Allowed is required. True if the action would be allowed, false otherwise. allowed(allowed):: {allowed: allowed}, // EvaluationError is an indication that some error occurred during the authorization check. It is entirely possible to get an error and be able to continue determine authorization status in spite of it. For instance, RBAC can be missing a role, but enough roles are still present and bound to reason about the request. evaluationError(evaluationError):: {evaluationError: evaluationError}, // Reason is optional. It indicates why a request was allowed or denied. reason(reason):: {reason: reason}, mixin:: { }, }, }, }, autoscaling:: { v1:: { local apiVersion = {apiVersion: "autoscaling/v1"}, // CrossVersionObjectReference contains enough information to let you identify the referred resource. crossVersionObjectReference:: { new():: {}, // Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: {name: name}, mixin:: { }, }, // specification of a horizontal pod autoscaler. horizontalPodAutoscalerSpec:: { new():: {}, // upper limit for the number of pods that can be set by the autoscaler; cannot be smaller than MinReplicas. maxReplicas(maxReplicas):: {maxReplicas: maxReplicas}, // lower limit for the number of pods that can be set by the autoscaler, default 1. minReplicas(minReplicas):: {minReplicas: minReplicas}, // target average CPU utilization (represented as a percentage of requested CPU) over all the pods; if not specified the default autoscaling policy will be used. targetCpuUtilizationPercentage(targetCpuUtilizationPercentage):: {targetCPUUtilizationPercentage: targetCpuUtilizationPercentage}, mixin:: { // reference to scaled resource; horizontal pod autoscaler will learn the current resource consumption and will set the desired number of pods by using its Scale subresource. scaleTargetRef:: { local __scaleTargetRefMixin(scaleTargetRef) = {scaleTargetRef+: scaleTargetRef}, mixinInstance(scaleTargetRef):: __scaleTargetRefMixin(scaleTargetRef), // Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __scaleTargetRefMixin({name: name}), }, scaleTargetRefType:: hidden.autoscaling.v1.crossVersionObjectReference, }, }, // current status of a horizontal pod autoscaler horizontalPodAutoscalerStatus:: { new():: {}, // current average CPU utilization over all pods, represented as a percentage of requested CPU, e.g. 70 means that an average pod is using now 70% of its requested CPU. currentCpuUtilizationPercentage(currentCpuUtilizationPercentage):: {currentCPUUtilizationPercentage: currentCpuUtilizationPercentage}, // current number of replicas of pods managed by this autoscaler. currentReplicas(currentReplicas):: {currentReplicas: currentReplicas}, // desired number of replicas of pods managed by this autoscaler. desiredReplicas(desiredReplicas):: {desiredReplicas: desiredReplicas}, // most recent generation observed by this autoscaler. observedGeneration(observedGeneration):: {observedGeneration: observedGeneration}, mixin:: { // last time the HorizontalPodAutoscaler scaled the number of pods; used by the autoscaler to control how often the number of pods is changed. lastScaleTime:: { local __lastScaleTimeMixin(lastScaleTime) = {lastScaleTime+: lastScaleTime}, mixinInstance(lastScaleTime):: __lastScaleTimeMixin(lastScaleTime), }, lastScaleTimeType:: hidden.meta.v1.time, }, }, // ScaleSpec describes the attributes of a scale subresource. scaleSpec:: { new():: {}, // desired number of instances for the scaled object. replicas(replicas):: {replicas: replicas}, mixin:: { }, }, // ScaleStatus represents the current status of a scale subresource. scaleStatus:: { new():: {}, // actual number of observed instances of the scaled object. replicas(replicas):: {replicas: replicas}, // label query over pods that should match the replicas count. This is same as the label selector but in the string format to avoid introspection by clients. The string will be in the same format as the query-param syntax. More info about label selectors: http://kubernetes.io/docs/user-guide/labels#label-selectors selector(selector):: {selector: selector}, mixin:: { }, }, }, v2alpha1:: { local apiVersion = {apiVersion: "autoscaling/v2alpha1"}, // CrossVersionObjectReference contains enough information to let you identify the referred resource. crossVersionObjectReference:: { new():: {}, // Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: {name: name}, mixin:: { }, }, // HorizontalPodAutoscalerCondition describes the state of a HorizontalPodAutoscaler at a certain point. horizontalPodAutoscalerCondition:: { new():: {}, // message is a human-readable explanation containing details about the transition message(message):: {message: message}, // reason is the reason for the condition's last transition. reason(reason):: {reason: reason}, // status is the status of the condition (True, False, Unknown) status(status):: {status: status}, // type describes the current condition type(type):: {type: type}, mixin:: { // lastTransitionTime is the last time the condition transitioned from one status to another lastTransitionTime:: { local __lastTransitionTimeMixin(lastTransitionTime) = {lastTransitionTime+: lastTransitionTime}, mixinInstance(lastTransitionTime):: __lastTransitionTimeMixin(lastTransitionTime), }, lastTransitionTimeType:: hidden.meta.v1.time, }, }, // HorizontalPodAutoscalerSpec describes the desired functionality of the HorizontalPodAutoscaler. horizontalPodAutoscalerSpec:: { new():: {}, // maxReplicas is the upper limit for the number of replicas to which the autoscaler can scale up. It cannot be less that minReplicas. maxReplicas(maxReplicas):: {maxReplicas: maxReplicas}, // metrics contains the specifications for which to use to calculate the desired replica count (the maximum replica count across all metrics will be used). The desired replica count is calculated multiplying the ratio between the target value and the current value by the current number of pods. Ergo, metrics used must decrease as the pod count is increased, and vice-versa. See the individual metric source types for more information about how each type of metric must respond. metrics(metrics):: if std.type(metrics) == "array" then {metrics+: metrics} else {metrics+: [metrics]}, metricsType:: hidden.autoscaling.v2alpha1.metricSpec, // minReplicas is the lower limit for the number of replicas to which the autoscaler can scale down. It defaults to 1 pod. minReplicas(minReplicas):: {minReplicas: minReplicas}, mixin:: { // scaleTargetRef points to the target resource to scale, and is used to the pods for which metrics should be collected, as well as to actually change the replica count. scaleTargetRef:: { local __scaleTargetRefMixin(scaleTargetRef) = {scaleTargetRef+: scaleTargetRef}, mixinInstance(scaleTargetRef):: __scaleTargetRefMixin(scaleTargetRef), // Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __scaleTargetRefMixin({name: name}), }, scaleTargetRefType:: hidden.autoscaling.v2alpha1.crossVersionObjectReference, }, }, // HorizontalPodAutoscalerStatus describes the current status of a horizontal pod autoscaler. horizontalPodAutoscalerStatus:: { new():: {}, // conditions is the set of conditions required for this autoscaler to scale its target, and indicates whether or not those conditions are met. conditions(conditions):: if std.type(conditions) == "array" then {conditions+: conditions} else {conditions+: [conditions]}, conditionsType:: hidden.autoscaling.v2alpha1.horizontalPodAutoscalerCondition, // currentMetrics is the last read state of the metrics used by this autoscaler. currentMetrics(currentMetrics):: if std.type(currentMetrics) == "array" then {currentMetrics+: currentMetrics} else {currentMetrics+: [currentMetrics]}, currentMetricsType:: hidden.autoscaling.v2alpha1.metricStatus, // currentReplicas is current number of replicas of pods managed by this autoscaler, as last seen by the autoscaler. currentReplicas(currentReplicas):: {currentReplicas: currentReplicas}, // desiredReplicas is the desired number of replicas of pods managed by this autoscaler, as last calculated by the autoscaler. desiredReplicas(desiredReplicas):: {desiredReplicas: desiredReplicas}, // observedGeneration is the most recent generation observed by this autoscaler. observedGeneration(observedGeneration):: {observedGeneration: observedGeneration}, mixin:: { // lastScaleTime is the last time the HorizontalPodAutoscaler scaled the number of pods, used by the autoscaler to control how often the number of pods is changed. lastScaleTime:: { local __lastScaleTimeMixin(lastScaleTime) = {lastScaleTime+: lastScaleTime}, mixinInstance(lastScaleTime):: __lastScaleTimeMixin(lastScaleTime), }, lastScaleTimeType:: hidden.meta.v1.time, }, }, // MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once). metricSpec:: { new():: {}, // type is the type of metric source. It should match one of the fields below. type(type):: {type: type}, mixin:: { // object refers to a metric describing a single kubernetes object (for example, hits-per-second on an Ingress object). object:: { local __objectMixin(object) = {object+: object}, mixinInstance(object):: __objectMixin(object), // metricName is the name of the metric in question. metricName(metricName):: __objectMixin({metricName: metricName}), // target is the described Kubernetes object. target:: { local __targetMixin(target) = __objectMixin({target+: target}), mixinInstance(target):: __targetMixin(target), // Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __targetMixin({name: name}), }, targetType:: hidden.autoscaling.v2alpha1.crossVersionObjectReference, // targetValue is the target value of the metric (as a quantity). targetValue:: { local __targetValueMixin(targetValue) = __objectMixin({targetValue+: targetValue}), mixinInstance(targetValue):: __targetValueMixin(targetValue), }, targetValueType:: hidden.core.resource.quantity, }, objectType:: hidden.autoscaling.v2alpha1.objectMetricSource, // pods refers to a metric describing each pod in the current scale target (for example, transactions-processed-per-second). The values will be averaged together before being compared to the target value. pods:: { local __podsMixin(pods) = {pods+: pods}, mixinInstance(pods):: __podsMixin(pods), // metricName is the name of the metric in question metricName(metricName):: __podsMixin({metricName: metricName}), // targetAverageValue is the target value of the average of the metric across all relevant pods (as a quantity) targetAverageValue:: { local __targetAverageValueMixin(targetAverageValue) = __podsMixin({targetAverageValue+: targetAverageValue}), mixinInstance(targetAverageValue):: __targetAverageValueMixin(targetAverageValue), }, targetAverageValueType:: hidden.core.resource.quantity, }, podsType:: hidden.autoscaling.v2alpha1.podsMetricSource, // resource refers to a resource metric (such as those specified in requests and limits) known to Kubernetes describing each pod in the current scale target (e.g. CPU or memory). Such metrics are built in to Kubernetes, and have special scaling options on top of those available to normal per-pod metrics using the "pods" source. resource:: { local __resourceMixin(resource) = {resource+: resource}, mixinInstance(resource):: __resourceMixin(resource), // name is the name of the resource in question. name(name):: __resourceMixin({name: name}), // targetAverageUtilization is the target value of the average of the resource metric across all relevant pods, represented as a percentage of the requested value of the resource for the pods. targetAverageUtilization(targetAverageUtilization):: __resourceMixin({targetAverageUtilization: targetAverageUtilization}), // targetAverageValue is the target value of the average of the resource metric across all relevant pods, as a raw value (instead of as a percentage of the request), similar to the "pods" metric source type. targetAverageValue:: { local __targetAverageValueMixin(targetAverageValue) = __resourceMixin({targetAverageValue+: targetAverageValue}), mixinInstance(targetAverageValue):: __targetAverageValueMixin(targetAverageValue), }, targetAverageValueType:: hidden.core.resource.quantity, }, resourceType:: hidden.autoscaling.v2alpha1.resourceMetricSource, }, }, // MetricStatus describes the last-read state of a single metric. metricStatus:: { new():: {}, // type is the type of metric source. It will match one of the fields below. type(type):: {type: type}, mixin:: { // object refers to a metric describing a single kubernetes object (for example, hits-per-second on an Ingress object). object:: { local __objectMixin(object) = {object+: object}, mixinInstance(object):: __objectMixin(object), // currentValue is the current value of the metric (as a quantity). currentValue:: { local __currentValueMixin(currentValue) = __objectMixin({currentValue+: currentValue}), mixinInstance(currentValue):: __currentValueMixin(currentValue), }, currentValueType:: hidden.core.resource.quantity, // metricName is the name of the metric in question. metricName(metricName):: __objectMixin({metricName: metricName}), // target is the described Kubernetes object. target:: { local __targetMixin(target) = __objectMixin({target+: target}), mixinInstance(target):: __targetMixin(target), // Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __targetMixin({name: name}), }, targetType:: hidden.autoscaling.v2alpha1.crossVersionObjectReference, }, objectType:: hidden.autoscaling.v2alpha1.objectMetricStatus, // pods refers to a metric describing each pod in the current scale target (for example, transactions-processed-per-second). The values will be averaged together before being compared to the target value. pods:: { local __podsMixin(pods) = {pods+: pods}, mixinInstance(pods):: __podsMixin(pods), // currentAverageValue is the current value of the average of the metric across all relevant pods (as a quantity) currentAverageValue:: { local __currentAverageValueMixin(currentAverageValue) = __podsMixin({currentAverageValue+: currentAverageValue}), mixinInstance(currentAverageValue):: __currentAverageValueMixin(currentAverageValue), }, currentAverageValueType:: hidden.core.resource.quantity, // metricName is the name of the metric in question metricName(metricName):: __podsMixin({metricName: metricName}), }, podsType:: hidden.autoscaling.v2alpha1.podsMetricStatus, // resource refers to a resource metric (such as those specified in requests and limits) known to Kubernetes describing each pod in the current scale target (e.g. CPU or memory). Such metrics are built in to Kubernetes, and have special scaling options on top of those available to normal per-pod metrics using the "pods" source. resource:: { local __resourceMixin(resource) = {resource+: resource}, mixinInstance(resource):: __resourceMixin(resource), // currentAverageUtilization is the current value of the average of the resource metric across all relevant pods, represented as a percentage of the requested value of the resource for the pods. It will only be present if `targetAverageValue` was set in the corresponding metric specification. currentAverageUtilization(currentAverageUtilization):: __resourceMixin({currentAverageUtilization: currentAverageUtilization}), // currentAverageValue is the current value of the average of the resource metric across all relevant pods, as a raw value (instead of as a percentage of the request), similar to the "pods" metric source type. It will always be set, regardless of the corresponding metric specification. currentAverageValue:: { local __currentAverageValueMixin(currentAverageValue) = __resourceMixin({currentAverageValue+: currentAverageValue}), mixinInstance(currentAverageValue):: __currentAverageValueMixin(currentAverageValue), }, currentAverageValueType:: hidden.core.resource.quantity, // name is the name of the resource in question. name(name):: __resourceMixin({name: name}), }, resourceType:: hidden.autoscaling.v2alpha1.resourceMetricStatus, }, }, // ObjectMetricSource indicates how to scale on a metric describing a kubernetes object (for example, hits-per-second on an Ingress object). objectMetricSource:: { new():: {}, // metricName is the name of the metric in question. metricName(metricName):: {metricName: metricName}, mixin:: { // target is the described Kubernetes object. target:: { local __targetMixin(target) = {target+: target}, mixinInstance(target):: __targetMixin(target), // Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __targetMixin({name: name}), }, targetType:: hidden.autoscaling.v2alpha1.crossVersionObjectReference, // targetValue is the target value of the metric (as a quantity). targetValue:: { local __targetValueMixin(targetValue) = {targetValue+: targetValue}, mixinInstance(targetValue):: __targetValueMixin(targetValue), }, targetValueType:: hidden.core.resource.quantity, }, }, // ObjectMetricStatus indicates the current value of a metric describing a kubernetes object (for example, hits-per-second on an Ingress object). objectMetricStatus:: { new():: {}, // metricName is the name of the metric in question. metricName(metricName):: {metricName: metricName}, mixin:: { // currentValue is the current value of the metric (as a quantity). currentValue:: { local __currentValueMixin(currentValue) = {currentValue+: currentValue}, mixinInstance(currentValue):: __currentValueMixin(currentValue), }, currentValueType:: hidden.core.resource.quantity, // target is the described Kubernetes object. target:: { local __targetMixin(target) = {target+: target}, mixinInstance(target):: __targetMixin(target), // Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __targetMixin({name: name}), }, targetType:: hidden.autoscaling.v2alpha1.crossVersionObjectReference, }, }, // PodsMetricSource indicates how to scale on a metric describing each pod in the current scale target (for example, transactions-processed-per-second). The values will be averaged together before being compared to the target value. podsMetricSource:: { new():: {}, // metricName is the name of the metric in question metricName(metricName):: {metricName: metricName}, mixin:: { // targetAverageValue is the target value of the average of the metric across all relevant pods (as a quantity) targetAverageValue:: { local __targetAverageValueMixin(targetAverageValue) = {targetAverageValue+: targetAverageValue}, mixinInstance(targetAverageValue):: __targetAverageValueMixin(targetAverageValue), }, targetAverageValueType:: hidden.core.resource.quantity, }, }, // PodsMetricStatus indicates the current value of a metric describing each pod in the current scale target (for example, transactions-processed-per-second). podsMetricStatus:: { new():: {}, // metricName is the name of the metric in question metricName(metricName):: {metricName: metricName}, mixin:: { // currentAverageValue is the current value of the average of the metric across all relevant pods (as a quantity) currentAverageValue:: { local __currentAverageValueMixin(currentAverageValue) = {currentAverageValue+: currentAverageValue}, mixinInstance(currentAverageValue):: __currentAverageValueMixin(currentAverageValue), }, currentAverageValueType:: hidden.core.resource.quantity, }, }, // ResourceMetricSource indicates how to scale on a resource metric known to Kubernetes, as specified in requests and limits, describing each pod in the current scale target (e.g. CPU or memory). The values will be averaged together before being compared to the target. Such metrics are built in to Kubernetes, and have special scaling options on top of those available to normal per-pod metrics using the "pods" source. Only one "target" type should be set. resourceMetricSource:: { new():: {}, // name is the name of the resource in question. name(name):: {name: name}, // targetAverageUtilization is the target value of the average of the resource metric across all relevant pods, represented as a percentage of the requested value of the resource for the pods. targetAverageUtilization(targetAverageUtilization):: {targetAverageUtilization: targetAverageUtilization}, mixin:: { // targetAverageValue is the target value of the average of the resource metric across all relevant pods, as a raw value (instead of as a percentage of the request), similar to the "pods" metric source type. targetAverageValue:: { local __targetAverageValueMixin(targetAverageValue) = {targetAverageValue+: targetAverageValue}, mixinInstance(targetAverageValue):: __targetAverageValueMixin(targetAverageValue), }, targetAverageValueType:: hidden.core.resource.quantity, }, }, // ResourceMetricStatus indicates the current value of a resource metric known to Kubernetes, as specified in requests and limits, describing each pod in the current scale target (e.g. CPU or memory). Such metrics are built in to Kubernetes, and have special scaling options on top of those available to normal per-pod metrics using the "pods" source. resourceMetricStatus:: { new():: {}, // currentAverageUtilization is the current value of the average of the resource metric across all relevant pods, represented as a percentage of the requested value of the resource for the pods. It will only be present if `targetAverageValue` was set in the corresponding metric specification. currentAverageUtilization(currentAverageUtilization):: {currentAverageUtilization: currentAverageUtilization}, // name is the name of the resource in question. name(name):: {name: name}, mixin:: { // currentAverageValue is the current value of the average of the resource metric across all relevant pods, as a raw value (instead of as a percentage of the request), similar to the "pods" metric source type. It will always be set, regardless of the corresponding metric specification. currentAverageValue:: { local __currentAverageValueMixin(currentAverageValue) = {currentAverageValue+: currentAverageValue}, mixinInstance(currentAverageValue):: __currentAverageValueMixin(currentAverageValue), }, currentAverageValueType:: hidden.core.resource.quantity, }, }, }, }, batch:: { v1:: { local apiVersion = {apiVersion: "batch/v1"}, // JobCondition describes current state of a job. jobCondition:: { new():: {}, // Human readable message indicating details about last transition. message(message):: {message: message}, // (brief) reason for the condition's last transition. reason(reason):: {reason: reason}, // Type of job condition, Complete or Failed. type(type):: {type: type}, mixin:: { // Last time the condition was checked. lastProbeTime:: { local __lastProbeTimeMixin(lastProbeTime) = {lastProbeTime+: lastProbeTime}, mixinInstance(lastProbeTime):: __lastProbeTimeMixin(lastProbeTime), }, lastProbeTimeType:: hidden.meta.v1.time, // Last time the condition transit from one status to another. lastTransitionTime:: { local __lastTransitionTimeMixin(lastTransitionTime) = {lastTransitionTime+: lastTransitionTime}, mixinInstance(lastTransitionTime):: __lastTransitionTimeMixin(lastTransitionTime), }, lastTransitionTimeType:: hidden.meta.v1.time, }, }, // JobSpec describes how the job execution will look like. jobSpec:: { new():: {}, // Optional duration in seconds relative to the startTime that the job may be active before the system tries to terminate it; value must be positive integer activeDeadlineSeconds(activeDeadlineSeconds):: {activeDeadlineSeconds: activeDeadlineSeconds}, // Specifies the desired number of successfully finished pods the job should be run with. Setting to nil means that the success of any pod signals the success of all pods, and allows parallelism to have any positive value. Setting to 1 means that parallelism is limited to 1 and the success of that pod signals the success of the job. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ completions(completions):: {completions: completions}, // manualSelector controls generation of pod labels and pod selectors. Leave `manualSelector` unset unless you are certain what you are doing. When false or unset, the system pick labels unique to this job and appends those labels to the pod template. When true, the user is responsible for picking unique labels and specifying the selector. Failure to pick a unique label may cause this and other jobs to not function correctly. However, You may see `manualSelector=true` in jobs that were created with the old `extensions/v1beta1` API. More info: https://git.k8s.io/community/contributors/design-proposals/selector-generation.md manualSelector(manualSelector):: {manualSelector: manualSelector}, // Specifies the maximum desired number of pods the job should run at any given time. The actual number of pods running in steady state will be less than this number when ((.spec.completions - .status.successful) < .spec.parallelism), i.e. when the work left to do is less than max parallelism. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ parallelism(parallelism):: {parallelism: parallelism}, mixin:: { // A label query over pods that should match the pod count. Normally, the system sets this field for you. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors selector:: { local __selectorMixin(selector) = {selector+: selector}, mixinInstance(selector):: __selectorMixin(selector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __selectorMixin({matchExpressions+: matchExpressions}) else __selectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __selectorMixin({matchLabels+: matchLabels}), }, selectorType:: hidden.meta.v1.labelSelector, // Describes the pod that will be created when executing a job. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ template:: { local __templateMixin(template) = {template+: template}, mixinInstance(template):: __templateMixin(template), // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = __templateMixin({metadata+: metadata}), mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = __templateMixin({spec+: spec}), mixinInstance(spec):: __specMixin(spec), // Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer. activeDeadlineSeconds(activeDeadlineSeconds):: __specMixin({activeDeadlineSeconds: activeDeadlineSeconds}), // If specified, the pod's scheduling constraints affinity:: { local __affinityMixin(affinity) = __specMixin({affinity+: affinity}), mixinInstance(affinity):: __affinityMixin(affinity), // Describes node affinity scheduling rules for the pod. nodeAffinity:: { local __nodeAffinityMixin(nodeAffinity) = __affinityMixin({nodeAffinity+: nodeAffinity}), mixinInstance(nodeAffinity):: __nodeAffinityMixin(nodeAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.preferredSchedulingTerm, // If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node. requiredDuringSchedulingIgnoredDuringExecution:: { local __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution) = __nodeAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}), mixinInstance(requiredDuringSchedulingIgnoredDuringExecution):: __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution), // Required. A list of node selector terms. The terms are ORed. nodeSelectorTerms(nodeSelectorTerms):: if std.type(nodeSelectorTerms) == "array" then __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: nodeSelectorTerms}) else __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: [nodeSelectorTerms]}), nodeSelectorTermsType:: hidden.core.v1.nodeSelectorTerm, }, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.nodeSelector, }, nodeAffinityType:: hidden.core.v1.nodeAffinity, // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)). podAffinity:: { local __podAffinityMixin(podAffinity) = __affinityMixin({podAffinity+: podAffinity}), mixinInstance(podAffinity):: __podAffinityMixin(podAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAffinityType:: hidden.core.v1.podAffinity, // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)). podAntiAffinity:: { local __podAntiAffinityMixin(podAntiAffinity) = __affinityMixin({podAntiAffinity+: podAntiAffinity}), mixinInstance(podAntiAffinity):: __podAntiAffinityMixin(podAntiAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAntiAffinityType:: hidden.core.v1.podAntiAffinity, }, affinityType:: hidden.core.v1.affinity, // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted. automountServiceAccountToken(automountServiceAccountToken):: __specMixin({automountServiceAccountToken: automountServiceAccountToken}), // List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated. containers(containers):: if std.type(containers) == "array" then __specMixin({containers+: containers}) else __specMixin({containers+: [containers]}), containersType:: hidden.core.v1.container, // Set DNS policy for containers within the pod. One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. Defaults to "ClusterFirst". To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. dnsPolicy(dnsPolicy):: __specMixin({dnsPolicy: dnsPolicy}), // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts file if specified. This is only valid for non-hostNetwork pods. hostAliases(hostAliases):: if std.type(hostAliases) == "array" then __specMixin({hostAliases+: hostAliases}) else __specMixin({hostAliases+: [hostAliases]}), hostAliasesType:: hidden.core.v1.hostAlias, // Use the host's ipc namespace. Optional: Default to false. hostIpc(hostIpc):: __specMixin({hostIPC: hostIpc}), // Host networking requested for this pod. Use the host's network namespace. If this option is set, the ports that will be used must be specified. Default to false. hostNetwork(hostNetwork):: __specMixin({hostNetwork: hostNetwork}), // Use the host's pid namespace. Optional: Default to false. hostPid(hostPid):: __specMixin({hostPID: hostPid}), // Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value. hostname(hostname):: __specMixin({hostname: hostname}), // 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. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod imagePullSecrets(imagePullSecrets):: if std.type(imagePullSecrets) == "array" then __specMixin({imagePullSecrets+: imagePullSecrets}) else __specMixin({imagePullSecrets+: [imagePullSecrets]}), imagePullSecretsType:: hidden.core.v1.localObjectReference, // List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ initContainers(initContainers):: if std.type(initContainers) == "array" then __specMixin({initContainers+: initContainers}) else __specMixin({initContainers+: [initContainers]}), initContainersType:: hidden.core.v1.container, // NodeName is a request to schedule this pod onto a specific node. If it is non-empty, the scheduler simply schedules this pod onto that node, assuming that it fits resource requirements. nodeName(nodeName):: __specMixin({nodeName: nodeName}), // NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ nodeSelector(nodeSelector):: __specMixin({nodeSelector+: nodeSelector}), // Restart policy for all containers within the pod. One of Always, OnFailure, Never. Default to Always. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy restartPolicy(restartPolicy):: __specMixin({restartPolicy: restartPolicy}), // If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler. schedulerName(schedulerName):: __specMixin({schedulerName: schedulerName}), // SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field. securityContext:: { local __securityContextMixin(securityContext) = __specMixin({securityContext+: securityContext}), mixinInstance(securityContext):: __securityContextMixin(securityContext), // A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod: // // 1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw---- // // If unset, the Kubelet will not modify the ownership and permissions of any volume. fsGroup(fsGroup):: __securityContextMixin({fsGroup: fsGroup}), // Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsNonRoot(runAsNonRoot):: __securityContextMixin({runAsNonRoot: runAsNonRoot}), // The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. runAsUser(runAsUser):: __securityContextMixin({runAsUser: runAsUser}), // The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = __securityContextMixin({seLinuxOptions+: seLinuxOptions}), mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, // A list of groups applied to the first process run in each container, in addition to the container's primary GID. If unspecified, no groups will be added to any container. supplementalGroups(supplementalGroups):: if std.type(supplementalGroups) == "array" then __securityContextMixin({supplementalGroups+: supplementalGroups}) else __securityContextMixin({supplementalGroups+: [supplementalGroups]}), }, securityContextType:: hidden.core.v1.podSecurityContext, // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead. serviceAccount(serviceAccount):: __specMixin({serviceAccount: serviceAccount}), // ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ serviceAccountName(serviceAccountName):: __specMixin({serviceAccountName: serviceAccountName}), // If specified, the fully qualified Pod hostname will be "...svc.". If not specified, the pod will not have a domainname at all. subdomain(subdomain):: __specMixin({subdomain: subdomain}), // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds. terminationGracePeriodSeconds(terminationGracePeriodSeconds):: __specMixin({terminationGracePeriodSeconds: terminationGracePeriodSeconds}), // If specified, the pod's tolerations. tolerations(tolerations):: if std.type(tolerations) == "array" then __specMixin({tolerations+: tolerations}) else __specMixin({tolerations+: [tolerations]}), tolerationsType:: hidden.core.v1.toleration, // List of volumes that can be mounted by containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes volumes(volumes):: if std.type(volumes) == "array" then __specMixin({volumes+: volumes}) else __specMixin({volumes+: [volumes]}), volumesType:: hidden.core.v1.volume, }, specType:: hidden.core.v1.podSpec, }, templateType:: hidden.core.v1.podTemplateSpec, }, }, // JobStatus represents the current state of a Job. jobStatus:: { new():: {}, // The number of actively running pods. active(active):: {active: active}, // The latest available observations of an object's current state. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ conditions(conditions):: if std.type(conditions) == "array" then {conditions+: conditions} else {conditions+: [conditions]}, conditionsType:: hidden.batch.v1.jobCondition, // The number of pods which reached phase Failed. failed(failed):: {failed: failed}, // The number of pods which reached phase Succeeded. succeeded(succeeded):: {succeeded: succeeded}, mixin:: { // Represents time when the job was completed. It is not guaranteed to be set in happens-before order across separate operations. It is represented in RFC3339 form and is in UTC. completionTime:: { local __completionTimeMixin(completionTime) = {completionTime+: completionTime}, mixinInstance(completionTime):: __completionTimeMixin(completionTime), }, completionTimeType:: hidden.meta.v1.time, // Represents time when the job was acknowledged by the job controller. It is not guaranteed to be set in happens-before order across separate operations. It is represented in RFC3339 form and is in UTC. startTime:: { local __startTimeMixin(startTime) = {startTime+: startTime}, mixinInstance(startTime):: __startTimeMixin(startTime), }, startTimeType:: hidden.meta.v1.time, }, }, }, v2alpha1:: { local apiVersion = {apiVersion: "batch/v2alpha1"}, // CronJobSpec describes how the job execution will look like and when it will actually run. cronJobSpec:: { new():: {}, // Specifies how to treat concurrent executions of a Job. Defaults to Allow. concurrencyPolicy(concurrencyPolicy):: {concurrencyPolicy: concurrencyPolicy}, // The number of failed finished jobs to retain. This is a pointer to distinguish between explicit zero and not specified. failedJobsHistoryLimit(failedJobsHistoryLimit):: {failedJobsHistoryLimit: failedJobsHistoryLimit}, // The schedule in Cron format, see https://en.wikipedia.org/wiki/Cron. schedule(schedule):: {schedule: schedule}, // Optional deadline in seconds for starting the job if it misses scheduled time for any reason. Missed jobs executions will be counted as failed ones. startingDeadlineSeconds(startingDeadlineSeconds):: {startingDeadlineSeconds: startingDeadlineSeconds}, // The number of successful finished jobs to retain. This is a pointer to distinguish between explicit zero and not specified. successfulJobsHistoryLimit(successfulJobsHistoryLimit):: {successfulJobsHistoryLimit: successfulJobsHistoryLimit}, // This flag tells the controller to suspend subsequent executions, it does not apply to already started executions. Defaults to false. suspend(suspend):: {suspend: suspend}, mixin:: { // Specifies the job that will be created when executing a CronJob. jobTemplate:: { local __jobTemplateMixin(jobTemplate) = {jobTemplate+: jobTemplate}, mixinInstance(jobTemplate):: __jobTemplateMixin(jobTemplate), // Standard object's metadata of the jobs created from this template. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = __jobTemplateMixin({metadata+: metadata}), mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the job. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = __jobTemplateMixin({spec+: spec}), mixinInstance(spec):: __specMixin(spec), // Optional duration in seconds relative to the startTime that the job may be active before the system tries to terminate it; value must be positive integer activeDeadlineSeconds(activeDeadlineSeconds):: __specMixin({activeDeadlineSeconds: activeDeadlineSeconds}), // Specifies the desired number of successfully finished pods the job should be run with. Setting to nil means that the success of any pod signals the success of all pods, and allows parallelism to have any positive value. Setting to 1 means that parallelism is limited to 1 and the success of that pod signals the success of the job. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ completions(completions):: __specMixin({completions: completions}), // manualSelector controls generation of pod labels and pod selectors. Leave `manualSelector` unset unless you are certain what you are doing. When false or unset, the system pick labels unique to this job and appends those labels to the pod template. When true, the user is responsible for picking unique labels and specifying the selector. Failure to pick a unique label may cause this and other jobs to not function correctly. However, You may see `manualSelector=true` in jobs that were created with the old `extensions/v1beta1` API. More info: https://git.k8s.io/community/contributors/design-proposals/selector-generation.md manualSelector(manualSelector):: __specMixin({manualSelector: manualSelector}), // Specifies the maximum desired number of pods the job should run at any given time. The actual number of pods running in steady state will be less than this number when ((.spec.completions - .status.successful) < .spec.parallelism), i.e. when the work left to do is less than max parallelism. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ parallelism(parallelism):: __specMixin({parallelism: parallelism}), // A label query over pods that should match the pod count. Normally, the system sets this field for you. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors selector:: { local __selectorMixin(selector) = __specMixin({selector+: selector}), mixinInstance(selector):: __selectorMixin(selector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __selectorMixin({matchExpressions+: matchExpressions}) else __selectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __selectorMixin({matchLabels+: matchLabels}), }, selectorType:: hidden.meta.v1.labelSelector, // Describes the pod that will be created when executing a job. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ template:: { local __templateMixin(template) = __specMixin({template+: template}), mixinInstance(template):: __templateMixin(template), // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = __templateMixin({metadata+: metadata}), mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = __templateMixin({spec+: spec}), mixinInstance(spec):: __specMixin(spec), // Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer. activeDeadlineSeconds(activeDeadlineSeconds):: __specMixin({activeDeadlineSeconds: activeDeadlineSeconds}), // If specified, the pod's scheduling constraints affinity:: { local __affinityMixin(affinity) = __specMixin({affinity+: affinity}), mixinInstance(affinity):: __affinityMixin(affinity), // Describes node affinity scheduling rules for the pod. nodeAffinity:: { local __nodeAffinityMixin(nodeAffinity) = __affinityMixin({nodeAffinity+: nodeAffinity}), mixinInstance(nodeAffinity):: __nodeAffinityMixin(nodeAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.preferredSchedulingTerm, // If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node. requiredDuringSchedulingIgnoredDuringExecution:: { local __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution) = __nodeAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}), mixinInstance(requiredDuringSchedulingIgnoredDuringExecution):: __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution), // Required. A list of node selector terms. The terms are ORed. nodeSelectorTerms(nodeSelectorTerms):: if std.type(nodeSelectorTerms) == "array" then __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: nodeSelectorTerms}) else __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: [nodeSelectorTerms]}), nodeSelectorTermsType:: hidden.core.v1.nodeSelectorTerm, }, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.nodeSelector, }, nodeAffinityType:: hidden.core.v1.nodeAffinity, // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)). podAffinity:: { local __podAffinityMixin(podAffinity) = __affinityMixin({podAffinity+: podAffinity}), mixinInstance(podAffinity):: __podAffinityMixin(podAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAffinityType:: hidden.core.v1.podAffinity, // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)). podAntiAffinity:: { local __podAntiAffinityMixin(podAntiAffinity) = __affinityMixin({podAntiAffinity+: podAntiAffinity}), mixinInstance(podAntiAffinity):: __podAntiAffinityMixin(podAntiAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAntiAffinityType:: hidden.core.v1.podAntiAffinity, }, affinityType:: hidden.core.v1.affinity, // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted. automountServiceAccountToken(automountServiceAccountToken):: __specMixin({automountServiceAccountToken: automountServiceAccountToken}), // List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated. containers(containers):: if std.type(containers) == "array" then __specMixin({containers+: containers}) else __specMixin({containers+: [containers]}), containersType:: hidden.core.v1.container, // Set DNS policy for containers within the pod. One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. Defaults to "ClusterFirst". To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. dnsPolicy(dnsPolicy):: __specMixin({dnsPolicy: dnsPolicy}), // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts file if specified. This is only valid for non-hostNetwork pods. hostAliases(hostAliases):: if std.type(hostAliases) == "array" then __specMixin({hostAliases+: hostAliases}) else __specMixin({hostAliases+: [hostAliases]}), hostAliasesType:: hidden.core.v1.hostAlias, // Use the host's ipc namespace. Optional: Default to false. hostIpc(hostIpc):: __specMixin({hostIPC: hostIpc}), // Host networking requested for this pod. Use the host's network namespace. If this option is set, the ports that will be used must be specified. Default to false. hostNetwork(hostNetwork):: __specMixin({hostNetwork: hostNetwork}), // Use the host's pid namespace. Optional: Default to false. hostPid(hostPid):: __specMixin({hostPID: hostPid}), // Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value. hostname(hostname):: __specMixin({hostname: hostname}), // 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. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod imagePullSecrets(imagePullSecrets):: if std.type(imagePullSecrets) == "array" then __specMixin({imagePullSecrets+: imagePullSecrets}) else __specMixin({imagePullSecrets+: [imagePullSecrets]}), imagePullSecretsType:: hidden.core.v1.localObjectReference, // List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ initContainers(initContainers):: if std.type(initContainers) == "array" then __specMixin({initContainers+: initContainers}) else __specMixin({initContainers+: [initContainers]}), initContainersType:: hidden.core.v1.container, // NodeName is a request to schedule this pod onto a specific node. If it is non-empty, the scheduler simply schedules this pod onto that node, assuming that it fits resource requirements. nodeName(nodeName):: __specMixin({nodeName: nodeName}), // NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ nodeSelector(nodeSelector):: __specMixin({nodeSelector+: nodeSelector}), // Restart policy for all containers within the pod. One of Always, OnFailure, Never. Default to Always. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy restartPolicy(restartPolicy):: __specMixin({restartPolicy: restartPolicy}), // If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler. schedulerName(schedulerName):: __specMixin({schedulerName: schedulerName}), // SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field. securityContext:: { local __securityContextMixin(securityContext) = __specMixin({securityContext+: securityContext}), mixinInstance(securityContext):: __securityContextMixin(securityContext), // A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod: // // 1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw---- // // If unset, the Kubelet will not modify the ownership and permissions of any volume. fsGroup(fsGroup):: __securityContextMixin({fsGroup: fsGroup}), // Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsNonRoot(runAsNonRoot):: __securityContextMixin({runAsNonRoot: runAsNonRoot}), // The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. runAsUser(runAsUser):: __securityContextMixin({runAsUser: runAsUser}), // The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = __securityContextMixin({seLinuxOptions+: seLinuxOptions}), mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, // A list of groups applied to the first process run in each container, in addition to the container's primary GID. If unspecified, no groups will be added to any container. supplementalGroups(supplementalGroups):: if std.type(supplementalGroups) == "array" then __securityContextMixin({supplementalGroups+: supplementalGroups}) else __securityContextMixin({supplementalGroups+: [supplementalGroups]}), }, securityContextType:: hidden.core.v1.podSecurityContext, // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead. serviceAccount(serviceAccount):: __specMixin({serviceAccount: serviceAccount}), // ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ serviceAccountName(serviceAccountName):: __specMixin({serviceAccountName: serviceAccountName}), // If specified, the fully qualified Pod hostname will be "...svc.". If not specified, the pod will not have a domainname at all. subdomain(subdomain):: __specMixin({subdomain: subdomain}), // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds. terminationGracePeriodSeconds(terminationGracePeriodSeconds):: __specMixin({terminationGracePeriodSeconds: terminationGracePeriodSeconds}), // If specified, the pod's tolerations. tolerations(tolerations):: if std.type(tolerations) == "array" then __specMixin({tolerations+: tolerations}) else __specMixin({tolerations+: [tolerations]}), tolerationsType:: hidden.core.v1.toleration, // List of volumes that can be mounted by containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes volumes(volumes):: if std.type(volumes) == "array" then __specMixin({volumes+: volumes}) else __specMixin({volumes+: [volumes]}), volumesType:: hidden.core.v1.volume, }, specType:: hidden.core.v1.podSpec, }, templateType:: hidden.core.v1.podTemplateSpec, }, specType:: hidden.batch.v1.jobSpec, }, jobTemplateType:: hidden.batch.v2alpha1.jobTemplateSpec, }, }, // CronJobStatus represents the current state of a cron job. cronJobStatus:: { new():: {}, // A list of pointers to currently running jobs. active(active):: if std.type(active) == "array" then {active+: active} else {active+: [active]}, activeType:: hidden.core.v1.objectReference, mixin:: { // Information when was the last time the job was successfully scheduled. lastScheduleTime:: { local __lastScheduleTimeMixin(lastScheduleTime) = {lastScheduleTime+: lastScheduleTime}, mixinInstance(lastScheduleTime):: __lastScheduleTimeMixin(lastScheduleTime), }, lastScheduleTimeType:: hidden.meta.v1.time, }, }, // JobTemplateSpec describes the data a Job should have when created from a template jobTemplateSpec:: { new():: {}, mixin:: { // Standard object's metadata of the jobs created from this template. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the job. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // Optional duration in seconds relative to the startTime that the job may be active before the system tries to terminate it; value must be positive integer activeDeadlineSeconds(activeDeadlineSeconds):: __specMixin({activeDeadlineSeconds: activeDeadlineSeconds}), // Specifies the desired number of successfully finished pods the job should be run with. Setting to nil means that the success of any pod signals the success of all pods, and allows parallelism to have any positive value. Setting to 1 means that parallelism is limited to 1 and the success of that pod signals the success of the job. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ completions(completions):: __specMixin({completions: completions}), // manualSelector controls generation of pod labels and pod selectors. Leave `manualSelector` unset unless you are certain what you are doing. When false or unset, the system pick labels unique to this job and appends those labels to the pod template. When true, the user is responsible for picking unique labels and specifying the selector. Failure to pick a unique label may cause this and other jobs to not function correctly. However, You may see `manualSelector=true` in jobs that were created with the old `extensions/v1beta1` API. More info: https://git.k8s.io/community/contributors/design-proposals/selector-generation.md manualSelector(manualSelector):: __specMixin({manualSelector: manualSelector}), // Specifies the maximum desired number of pods the job should run at any given time. The actual number of pods running in steady state will be less than this number when ((.spec.completions - .status.successful) < .spec.parallelism), i.e. when the work left to do is less than max parallelism. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ parallelism(parallelism):: __specMixin({parallelism: parallelism}), // A label query over pods that should match the pod count. Normally, the system sets this field for you. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors selector:: { local __selectorMixin(selector) = __specMixin({selector+: selector}), mixinInstance(selector):: __selectorMixin(selector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __selectorMixin({matchExpressions+: matchExpressions}) else __selectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __selectorMixin({matchLabels+: matchLabels}), }, selectorType:: hidden.meta.v1.labelSelector, // Describes the pod that will be created when executing a job. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ template:: { local __templateMixin(template) = __specMixin({template+: template}), mixinInstance(template):: __templateMixin(template), // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = __templateMixin({metadata+: metadata}), mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = __templateMixin({spec+: spec}), mixinInstance(spec):: __specMixin(spec), // Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer. activeDeadlineSeconds(activeDeadlineSeconds):: __specMixin({activeDeadlineSeconds: activeDeadlineSeconds}), // If specified, the pod's scheduling constraints affinity:: { local __affinityMixin(affinity) = __specMixin({affinity+: affinity}), mixinInstance(affinity):: __affinityMixin(affinity), // Describes node affinity scheduling rules for the pod. nodeAffinity:: { local __nodeAffinityMixin(nodeAffinity) = __affinityMixin({nodeAffinity+: nodeAffinity}), mixinInstance(nodeAffinity):: __nodeAffinityMixin(nodeAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.preferredSchedulingTerm, // If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node. requiredDuringSchedulingIgnoredDuringExecution:: { local __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution) = __nodeAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}), mixinInstance(requiredDuringSchedulingIgnoredDuringExecution):: __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution), // Required. A list of node selector terms. The terms are ORed. nodeSelectorTerms(nodeSelectorTerms):: if std.type(nodeSelectorTerms) == "array" then __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: nodeSelectorTerms}) else __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: [nodeSelectorTerms]}), nodeSelectorTermsType:: hidden.core.v1.nodeSelectorTerm, }, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.nodeSelector, }, nodeAffinityType:: hidden.core.v1.nodeAffinity, // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)). podAffinity:: { local __podAffinityMixin(podAffinity) = __affinityMixin({podAffinity+: podAffinity}), mixinInstance(podAffinity):: __podAffinityMixin(podAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAffinityType:: hidden.core.v1.podAffinity, // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)). podAntiAffinity:: { local __podAntiAffinityMixin(podAntiAffinity) = __affinityMixin({podAntiAffinity+: podAntiAffinity}), mixinInstance(podAntiAffinity):: __podAntiAffinityMixin(podAntiAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAntiAffinityType:: hidden.core.v1.podAntiAffinity, }, affinityType:: hidden.core.v1.affinity, // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted. automountServiceAccountToken(automountServiceAccountToken):: __specMixin({automountServiceAccountToken: automountServiceAccountToken}), // List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated. containers(containers):: if std.type(containers) == "array" then __specMixin({containers+: containers}) else __specMixin({containers+: [containers]}), containersType:: hidden.core.v1.container, // Set DNS policy for containers within the pod. One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. Defaults to "ClusterFirst". To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. dnsPolicy(dnsPolicy):: __specMixin({dnsPolicy: dnsPolicy}), // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts file if specified. This is only valid for non-hostNetwork pods. hostAliases(hostAliases):: if std.type(hostAliases) == "array" then __specMixin({hostAliases+: hostAliases}) else __specMixin({hostAliases+: [hostAliases]}), hostAliasesType:: hidden.core.v1.hostAlias, // Use the host's ipc namespace. Optional: Default to false. hostIpc(hostIpc):: __specMixin({hostIPC: hostIpc}), // Host networking requested for this pod. Use the host's network namespace. If this option is set, the ports that will be used must be specified. Default to false. hostNetwork(hostNetwork):: __specMixin({hostNetwork: hostNetwork}), // Use the host's pid namespace. Optional: Default to false. hostPid(hostPid):: __specMixin({hostPID: hostPid}), // Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value. hostname(hostname):: __specMixin({hostname: hostname}), // 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. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod imagePullSecrets(imagePullSecrets):: if std.type(imagePullSecrets) == "array" then __specMixin({imagePullSecrets+: imagePullSecrets}) else __specMixin({imagePullSecrets+: [imagePullSecrets]}), imagePullSecretsType:: hidden.core.v1.localObjectReference, // List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ initContainers(initContainers):: if std.type(initContainers) == "array" then __specMixin({initContainers+: initContainers}) else __specMixin({initContainers+: [initContainers]}), initContainersType:: hidden.core.v1.container, // NodeName is a request to schedule this pod onto a specific node. If it is non-empty, the scheduler simply schedules this pod onto that node, assuming that it fits resource requirements. nodeName(nodeName):: __specMixin({nodeName: nodeName}), // NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ nodeSelector(nodeSelector):: __specMixin({nodeSelector+: nodeSelector}), // Restart policy for all containers within the pod. One of Always, OnFailure, Never. Default to Always. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy restartPolicy(restartPolicy):: __specMixin({restartPolicy: restartPolicy}), // If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler. schedulerName(schedulerName):: __specMixin({schedulerName: schedulerName}), // SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field. securityContext:: { local __securityContextMixin(securityContext) = __specMixin({securityContext+: securityContext}), mixinInstance(securityContext):: __securityContextMixin(securityContext), // A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod: // // 1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw---- // // If unset, the Kubelet will not modify the ownership and permissions of any volume. fsGroup(fsGroup):: __securityContextMixin({fsGroup: fsGroup}), // Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsNonRoot(runAsNonRoot):: __securityContextMixin({runAsNonRoot: runAsNonRoot}), // The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. runAsUser(runAsUser):: __securityContextMixin({runAsUser: runAsUser}), // The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = __securityContextMixin({seLinuxOptions+: seLinuxOptions}), mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, // A list of groups applied to the first process run in each container, in addition to the container's primary GID. If unspecified, no groups will be added to any container. supplementalGroups(supplementalGroups):: if std.type(supplementalGroups) == "array" then __securityContextMixin({supplementalGroups+: supplementalGroups}) else __securityContextMixin({supplementalGroups+: [supplementalGroups]}), }, securityContextType:: hidden.core.v1.podSecurityContext, // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead. serviceAccount(serviceAccount):: __specMixin({serviceAccount: serviceAccount}), // ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ serviceAccountName(serviceAccountName):: __specMixin({serviceAccountName: serviceAccountName}), // If specified, the fully qualified Pod hostname will be "...svc.". If not specified, the pod will not have a domainname at all. subdomain(subdomain):: __specMixin({subdomain: subdomain}), // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds. terminationGracePeriodSeconds(terminationGracePeriodSeconds):: __specMixin({terminationGracePeriodSeconds: terminationGracePeriodSeconds}), // If specified, the pod's tolerations. tolerations(tolerations):: if std.type(tolerations) == "array" then __specMixin({tolerations+: tolerations}) else __specMixin({tolerations+: [tolerations]}), tolerationsType:: hidden.core.v1.toleration, // List of volumes that can be mounted by containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes volumes(volumes):: if std.type(volumes) == "array" then __specMixin({volumes+: volumes}) else __specMixin({volumes+: [volumes]}), volumesType:: hidden.core.v1.volume, }, specType:: hidden.core.v1.podSpec, }, templateType:: hidden.core.v1.podTemplateSpec, }, specType:: hidden.batch.v1.jobSpec, }, }, }, }, certificates:: { v1beta1:: { local apiVersion = {apiVersion: "certificates/v1beta1"}, // certificateSigningRequestCondition:: { new():: {}, // human readable message with details about the request state message(message):: {message: message}, // brief reason for the request state reason(reason):: {reason: reason}, // request approval state, currently Approved or Denied. type(type):: {type: type}, mixin:: { // timestamp for the last update to this condition lastUpdateTime:: { local __lastUpdateTimeMixin(lastUpdateTime) = {lastUpdateTime+: lastUpdateTime}, mixinInstance(lastUpdateTime):: __lastUpdateTimeMixin(lastUpdateTime), }, lastUpdateTimeType:: hidden.meta.v1.time, }, }, // This information is immutable after the request is created. Only the Request and Usages fields can be set on creation, other fields are derived by Kubernetes and cannot be modified by users. certificateSigningRequestSpec:: { new():: {}, // Extra information about the requesting user. See user.Info interface for details. extra(extra):: {extra+: extra}, // Group information about the requesting user. See user.Info interface for details. groups(groups):: if std.type(groups) == "array" then {groups+: groups} else {groups+: [groups]}, // Base64-encoded PKCS#10 CSR data request(request):: {request: request}, // UID information about the requesting user. See user.Info interface for details. uid(uid):: {uid: uid}, // allowedUsages specifies a set of usage contexts the key will be valid for. See: https://tools.ietf.org/html/rfc5280#section-4.2.1.3 // https://tools.ietf.org/html/rfc5280#section-4.2.1.12 usages(usages):: if std.type(usages) == "array" then {usages+: usages} else {usages+: [usages]}, // Information about the requesting user. See user.Info interface for details. username(username):: {username: username}, mixin:: { }, }, // certificateSigningRequestStatus:: { new():: {}, // If request was approved, the controller will place the issued certificate here. certificate(certificate):: {certificate: certificate}, // Conditions applied to the request, such as approval or denial. conditions(conditions):: if std.type(conditions) == "array" then {conditions+: conditions} else {conditions+: [conditions]}, conditionsType:: hidden.certificates.v1beta1.certificateSigningRequestCondition, mixin:: { }, }, }, }, core:: { intstr:: { local apiVersion = {apiVersion: "intstr"}, // intOrString:: { new():: {}, mixin:: { }, }, }, resource:: { local apiVersion = {apiVersion: "resource"}, // quantity:: { new():: {}, mixin:: { }, }, }, v1:: { local apiVersion = {apiVersion: "v1"}, // Represents a Persistent Disk resource in AWS. // // An AWS EBS disk must exist before mounting to a container. The disk must also be in the same AWS zone as the kubelet. An AWS EBS disk can only be mounted as read/write once. AWS EBS volumes support ownership management and SELinux relabeling. awsElasticBlockStoreVolumeSource:: { new():: {}, // Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore fsType(fsType):: {fsType: fsType}, // The partition in the volume that you want to mount. If omitted, the default is to mount by volume name. Examples: For volume /dev/sda1, you specify the partition as "1". Similarly, the volume partition for /dev/sda is "0" (or you can leave the property empty). partition(partition):: {partition: partition}, // Specify "true" to force and set the ReadOnly property in VolumeMounts to "true". If omitted, the default is "false". More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore readOnly(readOnly):: {readOnly: readOnly}, // Unique ID of the persistent disk resource in AWS (Amazon EBS volume). More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore volumeId(volumeId):: {volumeID: volumeId}, mixin:: { }, }, // Affinity is a group of affinity scheduling rules. affinity:: { new():: {}, mixin:: { // Describes node affinity scheduling rules for the pod. nodeAffinity:: { local __nodeAffinityMixin(nodeAffinity) = {nodeAffinity+: nodeAffinity}, mixinInstance(nodeAffinity):: __nodeAffinityMixin(nodeAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.preferredSchedulingTerm, // If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node. requiredDuringSchedulingIgnoredDuringExecution:: { local __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution) = __nodeAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}), mixinInstance(requiredDuringSchedulingIgnoredDuringExecution):: __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution), // Required. A list of node selector terms. The terms are ORed. nodeSelectorTerms(nodeSelectorTerms):: if std.type(nodeSelectorTerms) == "array" then __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: nodeSelectorTerms}) else __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: [nodeSelectorTerms]}), nodeSelectorTermsType:: hidden.core.v1.nodeSelectorTerm, }, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.nodeSelector, }, nodeAffinityType:: hidden.core.v1.nodeAffinity, // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)). podAffinity:: { local __podAffinityMixin(podAffinity) = {podAffinity+: podAffinity}, mixinInstance(podAffinity):: __podAffinityMixin(podAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAffinityType:: hidden.core.v1.podAffinity, // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)). podAntiAffinity:: { local __podAntiAffinityMixin(podAntiAffinity) = {podAntiAffinity+: podAntiAffinity}, mixinInstance(podAntiAffinity):: __podAntiAffinityMixin(podAntiAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAntiAffinityType:: hidden.core.v1.podAntiAffinity, }, }, // AttachedVolume describes a volume attached to a node attachedVolume:: { new():: {}, // DevicePath represents the device path where the volume should be available devicePath(devicePath):: {devicePath: devicePath}, // Name of the attached volume name(name):: {name: name}, mixin:: { }, }, // AzureDisk represents an Azure Data Disk mount on the host and bind mount to the pod. azureDiskVolumeSource:: { new():: {}, // Host Caching mode: None, Read Only, Read Write. cachingMode(cachingMode):: {cachingMode: cachingMode}, // The Name of the data disk in the blob storage diskName(diskName):: {diskName: diskName}, // The URI the data disk in the blob storage diskUri(diskUri):: {diskURI: diskUri}, // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: {fsType: fsType}, // Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: {readOnly: readOnly}, mixin:: { }, }, // AzureFile represents an Azure File Service mount on the host and bind mount to the pod. azureFileVolumeSource:: { new():: {}, // Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: {readOnly: readOnly}, // the name of secret that contains Azure Storage Account Name and Key secretName(secretName):: {secretName: secretName}, // Share Name shareName(shareName):: {shareName: shareName}, mixin:: { }, }, // Adds and removes POSIX capabilities from running containers. capabilities:: { new():: {}, // Added capabilities add(add):: if std.type(add) == "array" then {add+: add} else {add+: [add]}, // Removed capabilities drop(drop):: if std.type(drop) == "array" then {drop+: drop} else {drop+: [drop]}, mixin:: { }, }, // Represents a Ceph Filesystem mount that lasts the lifetime of a pod Cephfs volumes do not support ownership management or SELinux relabeling. cephFsVolumeSource:: { new():: {}, // Required: Monitors is a collection of Ceph monitors More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it monitors(monitors):: if std.type(monitors) == "array" then {monitors+: monitors} else {monitors+: [monitors]}, // Optional: Used as the mounted root, rather than the full Ceph tree, default is / path(path):: {path: path}, // Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it readOnly(readOnly):: {readOnly: readOnly}, // Optional: SecretFile is the path to key ring for User, default is /etc/ceph/user.secret More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it secretFile(secretFile):: {secretFile: secretFile}, // Optional: User is the rados user name, default is admin More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it user(user):: {user: user}, mixin:: { // Optional: SecretRef is reference to the authentication secret for User, default is empty. More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it secretRef:: { local __secretRefMixin(secretRef) = {secretRef+: secretRef}, mixinInstance(secretRef):: __secretRefMixin(secretRef), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), }, secretRefType:: hidden.core.v1.localObjectReference, }, }, // Represents a cinder volume resource in Openstack. A Cinder volume must exist before mounting to a container. The volume must also be in the same region as the kubelet. Cinder volumes support ownership management and SELinux relabeling. cinderVolumeSource:: { new():: {}, // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md fsType(fsType):: {fsType: fsType}, // Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md readOnly(readOnly):: {readOnly: readOnly}, // volume id used to identify the volume in cinder More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md volumeId(volumeId):: {volumeID: volumeId}, mixin:: { }, }, // Information about the condition of a component. componentCondition:: { new():: {}, // Message about the condition for a component. For example, information about a health check. message(message):: {message: message}, // Type of condition for a component. Valid value: "Healthy" type(type):: {type: type}, mixin:: { }, }, // ConfigMapEnvSource selects a ConfigMap to populate the environment variables with. // // The contents of the target ConfigMap's Data field will represent the key-value pairs as environment variables. configMapEnvSource:: { new():: {}, // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: {name: name}, // Specify whether the ConfigMap must be defined optional(optional):: {optional: optional}, mixin:: { }, }, // Selects a key from a ConfigMap. configMapKeySelector:: { new():: {}, // The key to select. key(key):: {key: key}, // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: {name: name}, // Specify whether the ConfigMap or it's key must be defined optional(optional):: {optional: optional}, mixin:: { }, }, // Adapts a ConfigMap into a projected volume. // // The contents of the target ConfigMap's Data field will be presented in a projected volume as files using the keys in the Data field as the file names, unless the items element is populated with specific mappings of keys to paths. Note that this is identical to a configmap volume source without the default mode. configMapProjection:: { new():: {}, // If unspecified, each key-value pair in the Data field of the referenced ConfigMap will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the ConfigMap, the volume setup will error unless it is marked optional. Paths must be relative and may not contain the '..' path or start with '..'. items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.core.v1.keyToPath, // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: {name: name}, // Specify whether the ConfigMap or it's keys must be defined optional(optional):: {optional: optional}, mixin:: { }, }, // Adapts a ConfigMap into a volume. // // The contents of the target ConfigMap's Data field will be presented in a volume as files using the keys in the Data field as the file names, unless the items element is populated with specific mappings of keys to paths. ConfigMap volumes support ownership management and SELinux relabeling. configMapVolumeSource:: { new():: {}, // Optional: mode bits to use on created files by default. Must be a value between 0 and 0777. Defaults to 0644. Directories within the path are not affected by this setting. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set. defaultMode(defaultMode):: {defaultMode: defaultMode}, // If unspecified, each key-value pair in the Data field of the referenced ConfigMap will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the ConfigMap, the volume setup will error unless it is marked optional. Paths must be relative and may not contain the '..' path or start with '..'. items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.core.v1.keyToPath, // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: {name: name}, // Specify whether the ConfigMap or it's keys must be defined optional(optional):: {optional: optional}, mixin:: { }, }, // A single application container that you want to run within a pod. container:: { new(name, image):: {} + self.name(name) + self.image(image), // Arguments to the entrypoint. The docker image's CMD is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell args(args):: if std.type(args) == "array" then {args+: args} else {args+: [args]}, // Entrypoint array. Not executed within a shell. The docker image's ENTRYPOINT is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell command(command):: if std.type(command) == "array" then {command+: command} else {command+: [command]}, // List of environment variables to set in the container. Cannot be updated. env(env):: if std.type(env) == "array" then {env+: env} else {env+: [env]}, // List of sources to populate environment variables in the container. The keys defined within a source must be a C_IDENTIFIER. All invalid keys will be reported as an event when the container is starting. When a key exists in multiple sources, the value associated with the last source will take precedence. Values defined by an Env with a duplicate key will take precedence. Cannot be updated. envFrom(envFrom):: if std.type(envFrom) == "array" then {envFrom+: envFrom} else {envFrom+: [envFrom]}, envFromType:: hidden.core.v1.envFromSource, envType:: hidden.core.v1.envVar, // Docker image name. More info: https://kubernetes.io/docs/concepts/containers/images image(image):: {image: image}, // Image pull policy. One of Always, Never, IfNotPresent. Defaults to Always if :latest tag is specified, or IfNotPresent otherwise. Cannot be updated. More info: https://kubernetes.io/docs/concepts/containers/images#updating-images imagePullPolicy(imagePullPolicy):: {imagePullPolicy: imagePullPolicy}, // Name of the container specified as a DNS_LABEL. Each container in a pod must have a unique name (DNS_LABEL). Cannot be updated. name(name):: {name: name}, // List of ports to expose from the container. Exposing a port here gives the system additional information about the network connections a container uses, but is primarily informational. Not specifying a port here DOES NOT prevent that port from being exposed. Any port which is listening on the default "0.0.0.0" address inside a container will be accessible from the network. Cannot be updated. ports(ports):: if std.type(ports) == "array" then {ports+: ports} else {ports+: [ports]}, portsType:: hidden.core.v1.containerPort, // Whether this container should allocate a buffer for stdin in the container runtime. If this is not set, reads from stdin in the container will always result in EOF. Default is false. stdin(stdin):: {stdin: stdin}, // Whether the container runtime should close the stdin channel after it has been opened by a single attach. When stdin is true the stdin stream will remain open across multiple attach sessions. If stdinOnce is set to true, stdin is opened on container start, is empty until the first client attaches to stdin, and then remains open and accepts data until the client disconnects, at which time stdin is closed and remains closed until the container is restarted. If this flag is false, a container processes that reads from stdin will never receive an EOF. Default is false stdinOnce(stdinOnce):: {stdinOnce: stdinOnce}, // Optional: Path at which the file to which the container's termination message will be written is mounted into the container's filesystem. Message written is intended to be brief final status, such as an assertion failure message. Will be truncated by the node if greater than 4096 bytes. The total message length across all containers will be limited to 12kb. Defaults to /dev/termination-log. Cannot be updated. terminationMessagePath(terminationMessagePath):: {terminationMessagePath: terminationMessagePath}, // Indicate how the termination message should be populated. File will use the contents of terminationMessagePath to populate the container status message on both success and failure. FallbackToLogsOnError will use the last chunk of container log output if the termination message file is empty and the container exited with an error. The log output is limited to 2048 bytes or 80 lines, whichever is smaller. Defaults to File. Cannot be updated. terminationMessagePolicy(terminationMessagePolicy):: {terminationMessagePolicy: terminationMessagePolicy}, // Whether this container should allocate a TTY for itself, also requires 'stdin' to be true. Default is false. tty(tty):: {tty: tty}, // Pod volumes to mount into the container's filesystem. Cannot be updated. volumeMounts(volumeMounts):: if std.type(volumeMounts) == "array" then {volumeMounts+: volumeMounts} else {volumeMounts+: [volumeMounts]}, volumeMountsType:: hidden.core.v1.volumeMount, // Container's working directory. If not specified, the container runtime's default will be used, which might be configured in the container image. Cannot be updated. workingDir(workingDir):: {workingDir: workingDir}, mixin:: { // Actions that the management system should take in response to container lifecycle events. Cannot be updated. lifecycle:: { local __lifecycleMixin(lifecycle) = {lifecycle+: lifecycle}, mixinInstance(lifecycle):: __lifecycleMixin(lifecycle), // PostStart is called immediately after a container is created. If the handler fails, the container is terminated and restarted according to its restart policy. Other management of the container blocks until the hook completes. More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks postStart:: { local __postStartMixin(postStart) = __lifecycleMixin({postStart+: postStart}), mixinInstance(postStart):: __postStartMixin(postStart), // One and only one of the following should be specified. Exec specifies the action to take. exec:: { local __execMixin(exec) = __postStartMixin({exec+: exec}), mixinInstance(exec):: __execMixin(exec), // Command is the command line to execute inside the container, the working directory for the command is root ('/') in the container's filesystem. The command is simply exec'd, it is not run inside a shell, so traditional shell instructions ('|', etc) won't work. To use a shell, you need to explicitly call out to that shell. Exit status of 0 is treated as live/healthy and non-zero is unhealthy. command(command):: if std.type(command) == "array" then __execMixin({command+: command}) else __execMixin({command+: [command]}), }, execType:: hidden.core.v1.execAction, // HTTPGet specifies the http request to perform. httpGet:: { local __httpGetMixin(httpGet) = __postStartMixin({httpGet+: httpGet}), mixinInstance(httpGet):: __httpGetMixin(httpGet), // Host name to connect to, defaults to the pod IP. You probably want to set "Host" in httpHeaders instead. host(host):: __httpGetMixin({host: host}), // Custom headers to set in the request. HTTP allows repeated headers. httpHeaders(httpHeaders):: if std.type(httpHeaders) == "array" then __httpGetMixin({httpHeaders+: httpHeaders}) else __httpGetMixin({httpHeaders+: [httpHeaders]}), httpHeadersType:: hidden.core.v1.httpHeader, // Path to access on the HTTP server. path(path):: __httpGetMixin({path: path}), // Name or number of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. port(port):: __httpGetMixin({port: port}), // Scheme to use for connecting to the host. Defaults to HTTP. scheme(scheme):: __httpGetMixin({scheme: scheme}), }, httpGetType:: hidden.core.v1.httpGetAction, // TCPSocket specifies an action involving a TCP port. TCP hooks not yet supported tcpSocket:: { local __tcpSocketMixin(tcpSocket) = __postStartMixin({tcpSocket+: tcpSocket}), mixinInstance(tcpSocket):: __tcpSocketMixin(tcpSocket), // Optional: Host name to connect to, defaults to the pod IP. host(host):: __tcpSocketMixin({host: host}), // Number or name of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. port(port):: __tcpSocketMixin({port: port}), }, tcpSocketType:: hidden.core.v1.tcpSocketAction, }, postStartType:: hidden.core.v1.handler, // PreStop is called immediately before a container is terminated. The container is terminated after the handler completes. The reason for termination is passed to the handler. Regardless of the outcome of the handler, the container is eventually terminated. Other management of the container blocks until the hook completes. More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks preStop:: { local __preStopMixin(preStop) = __lifecycleMixin({preStop+: preStop}), mixinInstance(preStop):: __preStopMixin(preStop), // One and only one of the following should be specified. Exec specifies the action to take. exec:: { local __execMixin(exec) = __preStopMixin({exec+: exec}), mixinInstance(exec):: __execMixin(exec), // Command is the command line to execute inside the container, the working directory for the command is root ('/') in the container's filesystem. The command is simply exec'd, it is not run inside a shell, so traditional shell instructions ('|', etc) won't work. To use a shell, you need to explicitly call out to that shell. Exit status of 0 is treated as live/healthy and non-zero is unhealthy. command(command):: if std.type(command) == "array" then __execMixin({command+: command}) else __execMixin({command+: [command]}), }, execType:: hidden.core.v1.execAction, // HTTPGet specifies the http request to perform. httpGet:: { local __httpGetMixin(httpGet) = __preStopMixin({httpGet+: httpGet}), mixinInstance(httpGet):: __httpGetMixin(httpGet), // Host name to connect to, defaults to the pod IP. You probably want to set "Host" in httpHeaders instead. host(host):: __httpGetMixin({host: host}), // Custom headers to set in the request. HTTP allows repeated headers. httpHeaders(httpHeaders):: if std.type(httpHeaders) == "array" then __httpGetMixin({httpHeaders+: httpHeaders}) else __httpGetMixin({httpHeaders+: [httpHeaders]}), httpHeadersType:: hidden.core.v1.httpHeader, // Path to access on the HTTP server. path(path):: __httpGetMixin({path: path}), // Name or number of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. port(port):: __httpGetMixin({port: port}), // Scheme to use for connecting to the host. Defaults to HTTP. scheme(scheme):: __httpGetMixin({scheme: scheme}), }, httpGetType:: hidden.core.v1.httpGetAction, // TCPSocket specifies an action involving a TCP port. TCP hooks not yet supported tcpSocket:: { local __tcpSocketMixin(tcpSocket) = __preStopMixin({tcpSocket+: tcpSocket}), mixinInstance(tcpSocket):: __tcpSocketMixin(tcpSocket), // Optional: Host name to connect to, defaults to the pod IP. host(host):: __tcpSocketMixin({host: host}), // Number or name of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. port(port):: __tcpSocketMixin({port: port}), }, tcpSocketType:: hidden.core.v1.tcpSocketAction, }, preStopType:: hidden.core.v1.handler, }, lifecycleType:: hidden.core.v1.lifecycle, // Periodic probe of container liveness. Container will be restarted if the probe fails. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes livenessProbe:: { local __livenessProbeMixin(livenessProbe) = {livenessProbe+: livenessProbe}, mixinInstance(livenessProbe):: __livenessProbeMixin(livenessProbe), // One and only one of the following should be specified. Exec specifies the action to take. exec:: { local __execMixin(exec) = __livenessProbeMixin({exec+: exec}), mixinInstance(exec):: __execMixin(exec), // Command is the command line to execute inside the container, the working directory for the command is root ('/') in the container's filesystem. The command is simply exec'd, it is not run inside a shell, so traditional shell instructions ('|', etc) won't work. To use a shell, you need to explicitly call out to that shell. Exit status of 0 is treated as live/healthy and non-zero is unhealthy. command(command):: if std.type(command) == "array" then __execMixin({command+: command}) else __execMixin({command+: [command]}), }, execType:: hidden.core.v1.execAction, // Minimum consecutive failures for the probe to be considered failed after having succeeded. Defaults to 3. Minimum value is 1. failureThreshold(failureThreshold):: __livenessProbeMixin({failureThreshold: failureThreshold}), // HTTPGet specifies the http request to perform. httpGet:: { local __httpGetMixin(httpGet) = __livenessProbeMixin({httpGet+: httpGet}), mixinInstance(httpGet):: __httpGetMixin(httpGet), // Host name to connect to, defaults to the pod IP. You probably want to set "Host" in httpHeaders instead. host(host):: __httpGetMixin({host: host}), // Custom headers to set in the request. HTTP allows repeated headers. httpHeaders(httpHeaders):: if std.type(httpHeaders) == "array" then __httpGetMixin({httpHeaders+: httpHeaders}) else __httpGetMixin({httpHeaders+: [httpHeaders]}), httpHeadersType:: hidden.core.v1.httpHeader, // Path to access on the HTTP server. path(path):: __httpGetMixin({path: path}), // Name or number of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. port(port):: __httpGetMixin({port: port}), // Scheme to use for connecting to the host. Defaults to HTTP. scheme(scheme):: __httpGetMixin({scheme: scheme}), }, httpGetType:: hidden.core.v1.httpGetAction, // Number of seconds after the container has started before liveness probes are initiated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes initialDelaySeconds(initialDelaySeconds):: __livenessProbeMixin({initialDelaySeconds: initialDelaySeconds}), // How often (in seconds) to perform the probe. Default to 10 seconds. Minimum value is 1. periodSeconds(periodSeconds):: __livenessProbeMixin({periodSeconds: periodSeconds}), // Minimum consecutive successes for the probe to be considered successful after having failed. Defaults to 1. Must be 1 for liveness. Minimum value is 1. successThreshold(successThreshold):: __livenessProbeMixin({successThreshold: successThreshold}), // TCPSocket specifies an action involving a TCP port. TCP hooks not yet supported tcpSocket:: { local __tcpSocketMixin(tcpSocket) = __livenessProbeMixin({tcpSocket+: tcpSocket}), mixinInstance(tcpSocket):: __tcpSocketMixin(tcpSocket), // Optional: Host name to connect to, defaults to the pod IP. host(host):: __tcpSocketMixin({host: host}), // Number or name of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. port(port):: __tcpSocketMixin({port: port}), }, tcpSocketType:: hidden.core.v1.tcpSocketAction, // Number of seconds after which the probe times out. Defaults to 1 second. Minimum value is 1. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes timeoutSeconds(timeoutSeconds):: __livenessProbeMixin({timeoutSeconds: timeoutSeconds}), }, livenessProbeType:: hidden.core.v1.probe, // Periodic probe of container service readiness. Container will be removed from service endpoints if the probe fails. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes readinessProbe:: { local __readinessProbeMixin(readinessProbe) = {readinessProbe+: readinessProbe}, mixinInstance(readinessProbe):: __readinessProbeMixin(readinessProbe), // One and only one of the following should be specified. Exec specifies the action to take. exec:: { local __execMixin(exec) = __readinessProbeMixin({exec+: exec}), mixinInstance(exec):: __execMixin(exec), // Command is the command line to execute inside the container, the working directory for the command is root ('/') in the container's filesystem. The command is simply exec'd, it is not run inside a shell, so traditional shell instructions ('|', etc) won't work. To use a shell, you need to explicitly call out to that shell. Exit status of 0 is treated as live/healthy and non-zero is unhealthy. command(command):: if std.type(command) == "array" then __execMixin({command+: command}) else __execMixin({command+: [command]}), }, execType:: hidden.core.v1.execAction, // Minimum consecutive failures for the probe to be considered failed after having succeeded. Defaults to 3. Minimum value is 1. failureThreshold(failureThreshold):: __readinessProbeMixin({failureThreshold: failureThreshold}), // HTTPGet specifies the http request to perform. httpGet:: { local __httpGetMixin(httpGet) = __readinessProbeMixin({httpGet+: httpGet}), mixinInstance(httpGet):: __httpGetMixin(httpGet), // Host name to connect to, defaults to the pod IP. You probably want to set "Host" in httpHeaders instead. host(host):: __httpGetMixin({host: host}), // Custom headers to set in the request. HTTP allows repeated headers. httpHeaders(httpHeaders):: if std.type(httpHeaders) == "array" then __httpGetMixin({httpHeaders+: httpHeaders}) else __httpGetMixin({httpHeaders+: [httpHeaders]}), httpHeadersType:: hidden.core.v1.httpHeader, // Path to access on the HTTP server. path(path):: __httpGetMixin({path: path}), // Name or number of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. port(port):: __httpGetMixin({port: port}), // Scheme to use for connecting to the host. Defaults to HTTP. scheme(scheme):: __httpGetMixin({scheme: scheme}), }, httpGetType:: hidden.core.v1.httpGetAction, // Number of seconds after the container has started before liveness probes are initiated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes initialDelaySeconds(initialDelaySeconds):: __readinessProbeMixin({initialDelaySeconds: initialDelaySeconds}), // How often (in seconds) to perform the probe. Default to 10 seconds. Minimum value is 1. periodSeconds(periodSeconds):: __readinessProbeMixin({periodSeconds: periodSeconds}), // Minimum consecutive successes for the probe to be considered successful after having failed. Defaults to 1. Must be 1 for liveness. Minimum value is 1. successThreshold(successThreshold):: __readinessProbeMixin({successThreshold: successThreshold}), // TCPSocket specifies an action involving a TCP port. TCP hooks not yet supported tcpSocket:: { local __tcpSocketMixin(tcpSocket) = __readinessProbeMixin({tcpSocket+: tcpSocket}), mixinInstance(tcpSocket):: __tcpSocketMixin(tcpSocket), // Optional: Host name to connect to, defaults to the pod IP. host(host):: __tcpSocketMixin({host: host}), // Number or name of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. port(port):: __tcpSocketMixin({port: port}), }, tcpSocketType:: hidden.core.v1.tcpSocketAction, // Number of seconds after which the probe times out. Defaults to 1 second. Minimum value is 1. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes timeoutSeconds(timeoutSeconds):: __readinessProbeMixin({timeoutSeconds: timeoutSeconds}), }, readinessProbeType:: hidden.core.v1.probe, // Compute Resources required by this container. Cannot be updated. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources resources:: { local __resourcesMixin(resources) = {resources+: resources}, mixinInstance(resources):: __resourcesMixin(resources), // Limits describes the maximum amount of compute resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ limits(limits):: __resourcesMixin({limits+: limits}), // Requests describes the minimum amount of compute resources required. If Requests is omitted for a container, it defaults to Limits if that is explicitly specified, otherwise to an implementation-defined value. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ requests(requests):: __resourcesMixin({requests+: requests}), }, resourcesType:: hidden.core.v1.resourceRequirements, // Security options the pod should run with. More info: https://kubernetes.io/docs/concepts/policy/security-context/ More info: https://git.k8s.io/community/contributors/design-proposals/security_context.md securityContext:: { local __securityContextMixin(securityContext) = {securityContext+: securityContext}, mixinInstance(securityContext):: __securityContextMixin(securityContext), // The capabilities to add/drop when running containers. Defaults to the default set of capabilities granted by the container runtime. capabilities:: { local __capabilitiesMixin(capabilities) = __securityContextMixin({capabilities+: capabilities}), mixinInstance(capabilities):: __capabilitiesMixin(capabilities), // Added capabilities add(add):: if std.type(add) == "array" then __capabilitiesMixin({add+: add}) else __capabilitiesMixin({add+: [add]}), // Removed capabilities drop(drop):: if std.type(drop) == "array" then __capabilitiesMixin({drop+: drop}) else __capabilitiesMixin({drop+: [drop]}), }, capabilitiesType:: hidden.core.v1.capabilities, // Run container in privileged mode. Processes in privileged containers are essentially equivalent to root on the host. Defaults to false. privileged(privileged):: __securityContextMixin({privileged: privileged}), // Whether this container has a read-only root filesystem. Default is false. readOnlyRootFilesystem(readOnlyRootFilesystem):: __securityContextMixin({readOnlyRootFilesystem: readOnlyRootFilesystem}), // Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsNonRoot(runAsNonRoot):: __securityContextMixin({runAsNonRoot: runAsNonRoot}), // The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsUser(runAsUser):: __securityContextMixin({runAsUser: runAsUser}), // The SELinux context to be applied to the container. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = __securityContextMixin({seLinuxOptions+: seLinuxOptions}), mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, }, securityContextType:: hidden.core.v1.securityContext, }, }, // Describe a container image containerImage:: { new():: {}, // Names by which this image is known. e.g. ["gcr.io/google_containers/hyperkube:v1.0.7", "dockerhub.io/google_containers/hyperkube:v1.0.7"] names(names):: if std.type(names) == "array" then {names+: names} else {names+: [names]}, // The size of the image in bytes. sizeBytes(sizeBytes):: {sizeBytes: sizeBytes}, mixin:: { }, }, // ContainerPort represents a network port in a single container. containerPort:: { new(containerPort):: {} + self.containerPort(containerPort), newNamed(name, containerPort):: {} + self.name(name) + self.containerPort(containerPort), // Number of port to expose on the pod's IP address. This must be a valid port number, 0 < x < 65536. containerPort(containerPort):: {containerPort: containerPort}, // What host IP to bind the external port to. hostIp(hostIp):: {hostIP: hostIp}, // Number of port to expose on the host. If specified, this must be a valid port number, 0 < x < 65536. If HostNetwork is specified, this must match ContainerPort. Most containers do not need this. hostPort(hostPort):: {hostPort: hostPort}, // If specified, this must be an IANA_SVC_NAME and unique within the pod. Each named port in a pod must have a unique name. Name for the port that can be referred to by services. name(name):: {name: name}, // Protocol for port. Must be UDP or TCP. Defaults to "TCP". protocol(protocol):: {protocol: protocol}, mixin:: { }, }, // ContainerState holds a possible state of container. Only one of its members may be specified. If none of them is specified, the default one is ContainerStateWaiting. containerState:: { new():: {}, mixin:: { // Details about a running container running:: { local __runningMixin(running) = {running+: running}, mixinInstance(running):: __runningMixin(running), // Time at which the container was last (re-)started startedAt:: { local __startedAtMixin(startedAt) = __runningMixin({startedAt+: startedAt}), mixinInstance(startedAt):: __startedAtMixin(startedAt), }, startedAtType:: hidden.meta.v1.time, }, runningType:: hidden.core.v1.containerStateRunning, // Details about a terminated container terminated:: { local __terminatedMixin(terminated) = {terminated+: terminated}, mixinInstance(terminated):: __terminatedMixin(terminated), // Container's ID in the format 'docker://' containerId(containerId):: __terminatedMixin({containerID: containerId}), // Exit status from the last termination of the container exitCode(exitCode):: __terminatedMixin({exitCode: exitCode}), // Time at which the container last terminated finishedAt:: { local __finishedAtMixin(finishedAt) = __terminatedMixin({finishedAt+: finishedAt}), mixinInstance(finishedAt):: __finishedAtMixin(finishedAt), }, finishedAtType:: hidden.meta.v1.time, // Message regarding the last termination of the container message(message):: __terminatedMixin({message: message}), // (brief) reason from the last termination of the container reason(reason):: __terminatedMixin({reason: reason}), // Signal from the last termination of the container signal(signal):: __terminatedMixin({signal: signal}), // Time at which previous execution of the container started startedAt:: { local __startedAtMixin(startedAt) = __terminatedMixin({startedAt+: startedAt}), mixinInstance(startedAt):: __startedAtMixin(startedAt), }, startedAtType:: hidden.meta.v1.time, }, terminatedType:: hidden.core.v1.containerStateTerminated, // Details about a waiting container waiting:: { local __waitingMixin(waiting) = {waiting+: waiting}, mixinInstance(waiting):: __waitingMixin(waiting), // Message regarding why the container is not yet running. message(message):: __waitingMixin({message: message}), // (brief) reason the container is not yet running. reason(reason):: __waitingMixin({reason: reason}), }, waitingType:: hidden.core.v1.containerStateWaiting, }, }, // ContainerStateRunning is a running state of a container. containerStateRunning:: { new():: {}, mixin:: { // Time at which the container was last (re-)started startedAt:: { local __startedAtMixin(startedAt) = {startedAt+: startedAt}, mixinInstance(startedAt):: __startedAtMixin(startedAt), }, startedAtType:: hidden.meta.v1.time, }, }, // ContainerStateTerminated is a terminated state of a container. containerStateTerminated:: { new():: {}, // Container's ID in the format 'docker://' containerId(containerId):: {containerID: containerId}, // Exit status from the last termination of the container exitCode(exitCode):: {exitCode: exitCode}, // Message regarding the last termination of the container message(message):: {message: message}, // (brief) reason from the last termination of the container reason(reason):: {reason: reason}, // Signal from the last termination of the container signal(signal):: {signal: signal}, mixin:: { // Time at which the container last terminated finishedAt:: { local __finishedAtMixin(finishedAt) = {finishedAt+: finishedAt}, mixinInstance(finishedAt):: __finishedAtMixin(finishedAt), }, finishedAtType:: hidden.meta.v1.time, // Time at which previous execution of the container started startedAt:: { local __startedAtMixin(startedAt) = {startedAt+: startedAt}, mixinInstance(startedAt):: __startedAtMixin(startedAt), }, startedAtType:: hidden.meta.v1.time, }, }, // ContainerStateWaiting is a waiting state of a container. containerStateWaiting:: { new():: {}, // Message regarding why the container is not yet running. message(message):: {message: message}, // (brief) reason the container is not yet running. reason(reason):: {reason: reason}, mixin:: { }, }, // ContainerStatus contains details for the current status of this container. containerStatus:: { new():: {}, // Container's ID in the format 'docker://'. containerId(containerId):: {containerID: containerId}, // The image the container is running. More info: https://kubernetes.io/docs/concepts/containers/images image(image):: {image: image}, // ImageID of the container's image. imageId(imageId):: {imageID: imageId}, // This must be a DNS_LABEL. Each container in a pod must have a unique name. Cannot be updated. name(name):: {name: name}, // Specifies whether the container has passed its readiness probe. ready(ready):: {ready: ready}, // The number of times the container has been restarted, currently based on the number of dead containers that have not yet been removed. Note that this is calculated from dead containers. But those containers are subject to garbage collection. This value will get capped at 5 by GC. restartCount(restartCount):: {restartCount: restartCount}, mixin:: { // Details about the container's last termination condition. lastState:: { local __lastStateMixin(lastState) = {lastState+: lastState}, mixinInstance(lastState):: __lastStateMixin(lastState), // Details about a running container running:: { local __runningMixin(running) = __lastStateMixin({running+: running}), mixinInstance(running):: __runningMixin(running), // Time at which the container was last (re-)started startedAt:: { local __startedAtMixin(startedAt) = __runningMixin({startedAt+: startedAt}), mixinInstance(startedAt):: __startedAtMixin(startedAt), }, startedAtType:: hidden.meta.v1.time, }, runningType:: hidden.core.v1.containerStateRunning, // Details about a terminated container terminated:: { local __terminatedMixin(terminated) = __lastStateMixin({terminated+: terminated}), mixinInstance(terminated):: __terminatedMixin(terminated), // Container's ID in the format 'docker://' containerId(containerId):: __terminatedMixin({containerID: containerId}), // Exit status from the last termination of the container exitCode(exitCode):: __terminatedMixin({exitCode: exitCode}), // Time at which the container last terminated finishedAt:: { local __finishedAtMixin(finishedAt) = __terminatedMixin({finishedAt+: finishedAt}), mixinInstance(finishedAt):: __finishedAtMixin(finishedAt), }, finishedAtType:: hidden.meta.v1.time, // Message regarding the last termination of the container message(message):: __terminatedMixin({message: message}), // (brief) reason from the last termination of the container reason(reason):: __terminatedMixin({reason: reason}), // Signal from the last termination of the container signal(signal):: __terminatedMixin({signal: signal}), // Time at which previous execution of the container started startedAt:: { local __startedAtMixin(startedAt) = __terminatedMixin({startedAt+: startedAt}), mixinInstance(startedAt):: __startedAtMixin(startedAt), }, startedAtType:: hidden.meta.v1.time, }, terminatedType:: hidden.core.v1.containerStateTerminated, // Details about a waiting container waiting:: { local __waitingMixin(waiting) = __lastStateMixin({waiting+: waiting}), mixinInstance(waiting):: __waitingMixin(waiting), // Message regarding why the container is not yet running. message(message):: __waitingMixin({message: message}), // (brief) reason the container is not yet running. reason(reason):: __waitingMixin({reason: reason}), }, waitingType:: hidden.core.v1.containerStateWaiting, }, lastStateType:: hidden.core.v1.containerState, // Details about the container's current condition. state:: { local __stateMixin(state) = {state+: state}, mixinInstance(state):: __stateMixin(state), // Details about a running container running:: { local __runningMixin(running) = __stateMixin({running+: running}), mixinInstance(running):: __runningMixin(running), // Time at which the container was last (re-)started startedAt:: { local __startedAtMixin(startedAt) = __runningMixin({startedAt+: startedAt}), mixinInstance(startedAt):: __startedAtMixin(startedAt), }, startedAtType:: hidden.meta.v1.time, }, runningType:: hidden.core.v1.containerStateRunning, // Details about a terminated container terminated:: { local __terminatedMixin(terminated) = __stateMixin({terminated+: terminated}), mixinInstance(terminated):: __terminatedMixin(terminated), // Container's ID in the format 'docker://' containerId(containerId):: __terminatedMixin({containerID: containerId}), // Exit status from the last termination of the container exitCode(exitCode):: __terminatedMixin({exitCode: exitCode}), // Time at which the container last terminated finishedAt:: { local __finishedAtMixin(finishedAt) = __terminatedMixin({finishedAt+: finishedAt}), mixinInstance(finishedAt):: __finishedAtMixin(finishedAt), }, finishedAtType:: hidden.meta.v1.time, // Message regarding the last termination of the container message(message):: __terminatedMixin({message: message}), // (brief) reason from the last termination of the container reason(reason):: __terminatedMixin({reason: reason}), // Signal from the last termination of the container signal(signal):: __terminatedMixin({signal: signal}), // Time at which previous execution of the container started startedAt:: { local __startedAtMixin(startedAt) = __terminatedMixin({startedAt+: startedAt}), mixinInstance(startedAt):: __startedAtMixin(startedAt), }, startedAtType:: hidden.meta.v1.time, }, terminatedType:: hidden.core.v1.containerStateTerminated, // Details about a waiting container waiting:: { local __waitingMixin(waiting) = __stateMixin({waiting+: waiting}), mixinInstance(waiting):: __waitingMixin(waiting), // Message regarding why the container is not yet running. message(message):: __waitingMixin({message: message}), // (brief) reason the container is not yet running. reason(reason):: __waitingMixin({reason: reason}), }, waitingType:: hidden.core.v1.containerStateWaiting, }, stateType:: hidden.core.v1.containerState, }, }, // DaemonEndpoint contains information about a single Daemon endpoint. daemonEndpoint:: { new():: {}, // Port number of the given endpoint. port(port):: {Port: port}, mixin:: { }, }, // Represents downward API info for projecting into a projected volume. Note that this is identical to a downwardAPI volume source without the default mode. downwardApiProjection:: { new():: {}, // Items is a list of DownwardAPIVolume file items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.core.v1.downwardApiVolumeFile, mixin:: { }, }, // DownwardAPIVolumeFile represents information to create the file containing the pod field downwardApiVolumeFile:: { new():: {}, // Optional: mode bits to use on this file, must be a value between 0 and 0777. If not specified, the volume defaultMode will be used. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set. mode(mode):: {mode: mode}, // 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 '..' path(path):: {path: path}, mixin:: { // Required: Selects a field of the pod: only annotations, labels, name and namespace are supported. fieldRef:: { local __fieldRefMixin(fieldRef) = {fieldRef+: fieldRef}, mixinInstance(fieldRef):: __fieldRefMixin(fieldRef), // Path of the field to select in the specified API version. fieldPath(fieldPath):: __fieldRefMixin({fieldPath: fieldPath}), }, fieldRefType:: hidden.core.v1.objectFieldSelector, // Selects a resource of the container: only resources limits and requests (limits.cpu, limits.memory, requests.cpu and requests.memory) are currently supported. resourceFieldRef:: { local __resourceFieldRefMixin(resourceFieldRef) = {resourceFieldRef+: resourceFieldRef}, mixinInstance(resourceFieldRef):: __resourceFieldRefMixin(resourceFieldRef), // Container name: required for volumes, optional for env vars containerName(containerName):: __resourceFieldRefMixin({containerName: containerName}), // Specifies the output format of the exposed resources, defaults to "1" divisor:: { local __divisorMixin(divisor) = __resourceFieldRefMixin({divisor+: divisor}), mixinInstance(divisor):: __divisorMixin(divisor), }, divisorType:: hidden.core.resource.quantity, // Required: resource to select resource(resource):: __resourceFieldRefMixin({resource: resource}), }, resourceFieldRefType:: hidden.core.v1.resourceFieldSelector, }, }, // DownwardAPIVolumeSource represents a volume containing downward API info. Downward API volumes support ownership management and SELinux relabeling. downwardApiVolumeSource:: { new():: {}, // Optional: mode bits to use on created files by default. Must be a value between 0 and 0777. Defaults to 0644. Directories within the path are not affected by this setting. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set. defaultMode(defaultMode):: {defaultMode: defaultMode}, // Items is a list of downward API volume file items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.core.v1.downwardApiVolumeFile, mixin:: { }, }, // Represents an empty directory for a pod. Empty directory volumes support ownership management and SELinux relabeling. emptyDirVolumeSource:: { new():: {}, // What type of storage medium should back this directory. The default is "" which means to use the node's default medium. Must be an empty string (default) or Memory. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir medium(medium):: {medium: medium}, mixin:: { // Total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: http://kubernetes.io/docs/user-guide/volumes#emptydir sizeLimit:: { local __sizeLimitMixin(sizeLimit) = {sizeLimit+: sizeLimit}, mixinInstance(sizeLimit):: __sizeLimitMixin(sizeLimit), }, sizeLimitType:: hidden.core.resource.quantity, }, }, // EndpointAddress is a tuple that describes single IP address. endpointAddress:: { new():: {}, // The Hostname of this endpoint hostname(hostname):: {hostname: hostname}, // The IP of this endpoint. May not be loopback (127.0.0.0/8), link-local (169.254.0.0/16), or link-local multicast ((224.0.0.0/24). IPv6 is also accepted but not fully supported on all platforms. Also, certain kubernetes components, like kube-proxy, are not IPv6 ready. ip(ip):: {ip: ip}, // Optional: Node hosting this endpoint. This can be used to determine endpoints local to a node. nodeName(nodeName):: {nodeName: nodeName}, mixin:: { // Reference to object providing the endpoint. targetRef:: { local __targetRefMixin(targetRef) = {targetRef+: targetRef}, mixinInstance(targetRef):: __targetRefMixin(targetRef), // If referring to a piece of an object instead of an entire object, this string should contain a valid JSON/Go field access statement, such as desiredState.manifest.containers[2]. For example, if the object reference is to a container within a pod, this would take on a value like: "spec.containers{name}" (where "name" refers to the name of the container that triggered the event) or if no container name is specified "spec.containers[2]" (container with index 2 in this pod). This syntax is chosen only to have some well-defined way of referencing a part of an object. fieldPath(fieldPath):: __targetRefMixin({fieldPath: fieldPath}), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __targetRefMixin({name: name}), // Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ namespace(namespace):: __targetRefMixin({namespace: namespace}), // Specific resourceVersion to which this reference is made, if any. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency resourceVersion(resourceVersion):: __targetRefMixin({resourceVersion: resourceVersion}), // UID of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids uid(uid):: __targetRefMixin({uid: uid}), }, targetRefType:: hidden.core.v1.objectReference, }, }, // EndpointPort is a tuple that describes a single port. endpointPort:: { new():: {}, // The name of this port (corresponds to ServicePort.Name). Must be a DNS_LABEL. Optional only if one port is defined. name(name):: {name: name}, // The port number of the endpoint. port(port):: {port: port}, // The IP protocol for this port. Must be UDP or TCP. Default is TCP. protocol(protocol):: {protocol: protocol}, mixin:: { }, }, // EndpointSubset is a group of addresses with a common set of ports. The expanded set of endpoints is the Cartesian product of Addresses x Ports. For example, given: // { // Addresses: [{"ip": "10.10.1.1"}, {"ip": "10.10.2.2"}], // Ports: [{"name": "a", "port": 8675}, {"name": "b", "port": 309}] // } // The resulting set of endpoints can be viewed as: // a: [ 10.10.1.1:8675, 10.10.2.2:8675 ], // b: [ 10.10.1.1:309, 10.10.2.2:309 ] endpointSubset:: { new():: {}, // IP addresses which offer the related ports that are marked as ready. These endpoints should be considered safe for load balancers and clients to utilize. addresses(addresses):: if std.type(addresses) == "array" then {addresses+: addresses} else {addresses+: [addresses]}, addressesType:: hidden.core.v1.endpointAddress, // IP addresses which offer the related ports but are not currently marked as ready because they have not yet finished starting, have recently failed a readiness check, or have recently failed a liveness check. notReadyAddresses(notReadyAddresses):: if std.type(notReadyAddresses) == "array" then {notReadyAddresses+: notReadyAddresses} else {notReadyAddresses+: [notReadyAddresses]}, notReadyAddressesType:: hidden.core.v1.endpointAddress, // Port numbers available on the related IP addresses. ports(ports):: if std.type(ports) == "array" then {ports+: ports} else {ports+: [ports]}, portsType:: hidden.core.v1.endpointPort, mixin:: { }, }, // EnvFromSource represents the source of a set of ConfigMaps envFromSource:: { new():: {}, // An optional identifer to prepend to each key in the ConfigMap. Must be a C_IDENTIFIER. prefix(prefix):: {prefix: prefix}, mixin:: { // The ConfigMap to select from configMapRef:: { local __configMapRefMixin(configMapRef) = {configMapRef+: configMapRef}, mixinInstance(configMapRef):: __configMapRefMixin(configMapRef), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __configMapRefMixin({name: name}), // Specify whether the ConfigMap must be defined optional(optional):: __configMapRefMixin({optional: optional}), }, configMapRefType:: hidden.core.v1.configMapEnvSource, // The Secret to select from secretRef:: { local __secretRefMixin(secretRef) = {secretRef+: secretRef}, mixinInstance(secretRef):: __secretRefMixin(secretRef), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), // Specify whether the Secret must be defined optional(optional):: __secretRefMixin({optional: optional}), }, secretRefType:: hidden.core.v1.secretEnvSource, }, }, // EnvVar represents an environment variable present in a Container. envVar:: { new(name, value):: {} + self.name(name) + self.value(value), fromSecretRef(name, secretRefName, secretRefKey):: {} + self.name(name) + self.mixin.valueFrom.secretKeyRef.name(secretRefName) + self.mixin.valueFrom.secretKeyRef.key(secretRefKey), fromFieldPath(name, fieldPath):: {} + self.name(name) + self.mixin.valueFrom.fieldRef.fieldPath(fieldPath), // Name of the environment variable. Must be a C_IDENTIFIER. name(name):: {name: name}, // Variable references $(VAR_NAME) are expanded using the previous defined environment variables in the container and any service environment variables. If a variable cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, regardless of whether the variable exists or not. Defaults to "". value(value):: {value: value}, mixin:: { // Source for the environment variable's value. Cannot be used if value is not empty. valueFrom:: { local __valueFromMixin(valueFrom) = {valueFrom+: valueFrom}, mixinInstance(valueFrom):: __valueFromMixin(valueFrom), // Selects a key of a ConfigMap. configMapKeyRef:: { local __configMapKeyRefMixin(configMapKeyRef) = __valueFromMixin({configMapKeyRef+: configMapKeyRef}), mixinInstance(configMapKeyRef):: __configMapKeyRefMixin(configMapKeyRef), // The key to select. key(key):: __configMapKeyRefMixin({key: key}), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __configMapKeyRefMixin({name: name}), // Specify whether the ConfigMap or it's key must be defined optional(optional):: __configMapKeyRefMixin({optional: optional}), }, configMapKeyRefType:: hidden.core.v1.configMapKeySelector, // Selects a field of the pod: supports metadata.name, metadata.namespace, metadata.labels, metadata.annotations, spec.nodeName, spec.serviceAccountName, status.hostIP, status.podIP. fieldRef:: { local __fieldRefMixin(fieldRef) = __valueFromMixin({fieldRef+: fieldRef}), mixinInstance(fieldRef):: __fieldRefMixin(fieldRef), // Path of the field to select in the specified API version. fieldPath(fieldPath):: __fieldRefMixin({fieldPath: fieldPath}), }, fieldRefType:: hidden.core.v1.objectFieldSelector, // Selects a resource of the container: only resources limits and requests (limits.cpu, limits.memory, requests.cpu and requests.memory) are currently supported. resourceFieldRef:: { local __resourceFieldRefMixin(resourceFieldRef) = __valueFromMixin({resourceFieldRef+: resourceFieldRef}), mixinInstance(resourceFieldRef):: __resourceFieldRefMixin(resourceFieldRef), // Container name: required for volumes, optional for env vars containerName(containerName):: __resourceFieldRefMixin({containerName: containerName}), // Specifies the output format of the exposed resources, defaults to "1" divisor:: { local __divisorMixin(divisor) = __resourceFieldRefMixin({divisor+: divisor}), mixinInstance(divisor):: __divisorMixin(divisor), }, divisorType:: hidden.core.resource.quantity, // Required: resource to select resource(resource):: __resourceFieldRefMixin({resource: resource}), }, resourceFieldRefType:: hidden.core.v1.resourceFieldSelector, // Selects a key of a secret in the pod's namespace secretKeyRef:: { local __secretKeyRefMixin(secretKeyRef) = __valueFromMixin({secretKeyRef+: secretKeyRef}), mixinInstance(secretKeyRef):: __secretKeyRefMixin(secretKeyRef), // The key of the secret to select from. Must be a valid secret key. key(key):: __secretKeyRefMixin({key: key}), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretKeyRefMixin({name: name}), // Specify whether the Secret or it's key must be defined optional(optional):: __secretKeyRefMixin({optional: optional}), }, secretKeyRefType:: hidden.core.v1.secretKeySelector, }, valueFromType:: hidden.core.v1.envVarSource, }, }, // EnvVarSource represents a source for the value of an EnvVar. envVarSource:: { new():: {}, mixin:: { // Selects a key of a ConfigMap. configMapKeyRef:: { local __configMapKeyRefMixin(configMapKeyRef) = {configMapKeyRef+: configMapKeyRef}, mixinInstance(configMapKeyRef):: __configMapKeyRefMixin(configMapKeyRef), // The key to select. key(key):: __configMapKeyRefMixin({key: key}), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __configMapKeyRefMixin({name: name}), // Specify whether the ConfigMap or it's key must be defined optional(optional):: __configMapKeyRefMixin({optional: optional}), }, configMapKeyRefType:: hidden.core.v1.configMapKeySelector, // Selects a field of the pod: supports metadata.name, metadata.namespace, metadata.labels, metadata.annotations, spec.nodeName, spec.serviceAccountName, status.hostIP, status.podIP. fieldRef:: { local __fieldRefMixin(fieldRef) = {fieldRef+: fieldRef}, mixinInstance(fieldRef):: __fieldRefMixin(fieldRef), // Path of the field to select in the specified API version. fieldPath(fieldPath):: __fieldRefMixin({fieldPath: fieldPath}), }, fieldRefType:: hidden.core.v1.objectFieldSelector, // Selects a resource of the container: only resources limits and requests (limits.cpu, limits.memory, requests.cpu and requests.memory) are currently supported. resourceFieldRef:: { local __resourceFieldRefMixin(resourceFieldRef) = {resourceFieldRef+: resourceFieldRef}, mixinInstance(resourceFieldRef):: __resourceFieldRefMixin(resourceFieldRef), // Container name: required for volumes, optional for env vars containerName(containerName):: __resourceFieldRefMixin({containerName: containerName}), // Specifies the output format of the exposed resources, defaults to "1" divisor:: { local __divisorMixin(divisor) = __resourceFieldRefMixin({divisor+: divisor}), mixinInstance(divisor):: __divisorMixin(divisor), }, divisorType:: hidden.core.resource.quantity, // Required: resource to select resource(resource):: __resourceFieldRefMixin({resource: resource}), }, resourceFieldRefType:: hidden.core.v1.resourceFieldSelector, // Selects a key of a secret in the pod's namespace secretKeyRef:: { local __secretKeyRefMixin(secretKeyRef) = {secretKeyRef+: secretKeyRef}, mixinInstance(secretKeyRef):: __secretKeyRefMixin(secretKeyRef), // The key of the secret to select from. Must be a valid secret key. key(key):: __secretKeyRefMixin({key: key}), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretKeyRefMixin({name: name}), // Specify whether the Secret or it's key must be defined optional(optional):: __secretKeyRefMixin({optional: optional}), }, secretKeyRefType:: hidden.core.v1.secretKeySelector, }, }, // EventSource contains information for an event. eventSource:: { new():: {}, // Component from which the event is generated. component(component):: {component: component}, // Node name on which the event is generated. host(host):: {host: host}, mixin:: { }, }, // ExecAction describes a "run in container" action. execAction:: { new():: {}, // Command is the command line to execute inside the container, the working directory for the command is root ('/') in the container's filesystem. The command is simply exec'd, it is not run inside a shell, so traditional shell instructions ('|', etc) won't work. To use a shell, you need to explicitly call out to that shell. Exit status of 0 is treated as live/healthy and non-zero is unhealthy. command(command):: if std.type(command) == "array" then {command+: command} else {command+: [command]}, mixin:: { }, }, // Represents a Fibre Channel volume. Fibre Channel volumes can only be mounted as read/write once. Fibre Channel volumes support ownership management and SELinux relabeling. fcVolumeSource:: { new():: {}, // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: {fsType: fsType}, // Required: FC target lun number lun(lun):: {lun: lun}, // Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: {readOnly: readOnly}, // Required: FC target worldwide names (WWNs) targetWwns(targetWwns):: if std.type(targetWwns) == "array" then {targetWWNs+: targetWwns} else {targetWWNs+: [targetWwns]}, mixin:: { }, }, // FlexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin. This is an alpha feature and may change in future. flexVolumeSource:: { new():: {}, // Driver is the name of the driver to use for this volume. driver(driver):: {driver: driver}, // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". The default filesystem depends on FlexVolume script. fsType(fsType):: {fsType: fsType}, // Optional: Extra command options if any. options(options):: {options+: options}, // Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: {readOnly: readOnly}, mixin:: { // Optional: SecretRef is reference to the secret object containing sensitive information to pass to the plugin scripts. This may be empty if no secret object is specified. If the secret object contains more than one secret, all secrets are passed to the plugin scripts. secretRef:: { local __secretRefMixin(secretRef) = {secretRef+: secretRef}, mixinInstance(secretRef):: __secretRefMixin(secretRef), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), }, secretRefType:: hidden.core.v1.localObjectReference, }, }, // Represents a Flocker volume mounted by the Flocker agent. One and only one of datasetName and datasetUUID should be set. Flocker volumes do not support ownership management or SELinux relabeling. flockerVolumeSource:: { new():: {}, // Name of the dataset stored as metadata -> name on the dataset for Flocker should be considered as deprecated datasetName(datasetName):: {datasetName: datasetName}, // UUID of the dataset. This is unique identifier of a Flocker dataset datasetUuid(datasetUuid):: {datasetUUID: datasetUuid}, mixin:: { }, }, // Represents a Persistent Disk resource in Google Compute Engine. // // A GCE PD must exist before mounting to a container. The disk must also be in the same GCE project and zone as the kubelet. A GCE PD can only be mounted as read/write once or read-only many times. GCE PDs support ownership management and SELinux relabeling. gcePersistentDiskVolumeSource:: { new():: {}, // Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk fsType(fsType):: {fsType: fsType}, // The partition in the volume that you want to mount. If omitted, the default is to mount by volume name. Examples: For volume /dev/sda1, you specify the partition as "1". Similarly, the volume partition for /dev/sda is "0" (or you can leave the property empty). More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk partition(partition):: {partition: partition}, // Unique name of the PD resource in GCE. Used to identify the disk in GCE. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk pdName(pdName):: {pdName: pdName}, // ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk readOnly(readOnly):: {readOnly: readOnly}, mixin:: { }, }, // Represents a volume that is populated with the contents of a git repository. Git repo volumes do not support ownership management. Git repo volumes support SELinux relabeling. gitRepoVolumeSource:: { new():: {}, // Target directory name. Must not contain or start with '..'. If '.' is supplied, the volume directory will be the git repository. Otherwise, if specified, the volume will contain the git repository in the subdirectory with the given name. directory(directory):: {directory: directory}, // Repository URL repository(repository):: {repository: repository}, // Commit hash for the specified revision. revision(revision):: {revision: revision}, mixin:: { }, }, // Represents a Glusterfs mount that lasts the lifetime of a pod. Glusterfs volumes do not support ownership management or SELinux relabeling. glusterfsVolumeSource:: { new():: {}, // EndpointsName is the endpoint name that details Glusterfs topology. More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod endpoints(endpoints):: {endpoints: endpoints}, // Path is the Glusterfs volume path. More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod path(path):: {path: path}, // ReadOnly here will force the Glusterfs volume to be mounted with read-only permissions. Defaults to false. More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod readOnly(readOnly):: {readOnly: readOnly}, mixin:: { }, }, // HTTPGetAction describes an action based on HTTP Get requests. httpGetAction:: { new():: {}, // Host name to connect to, defaults to the pod IP. You probably want to set "Host" in httpHeaders instead. host(host):: {host: host}, // Custom headers to set in the request. HTTP allows repeated headers. httpHeaders(httpHeaders):: if std.type(httpHeaders) == "array" then {httpHeaders+: httpHeaders} else {httpHeaders+: [httpHeaders]}, httpHeadersType:: hidden.core.v1.httpHeader, // Path to access on the HTTP server. path(path):: {path: path}, // Name or number of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. port(port):: {port: port}, // Scheme to use for connecting to the host. Defaults to HTTP. scheme(scheme):: {scheme: scheme}, mixin:: { }, }, // HTTPHeader describes a custom header to be used in HTTP probes httpHeader:: { new():: {}, // The header field name name(name):: {name: name}, // The header field value value(value):: {value: value}, mixin:: { }, }, // Handler defines a specific action that should be taken handler:: { new():: {}, mixin:: { // One and only one of the following should be specified. Exec specifies the action to take. exec:: { local __execMixin(exec) = {exec+: exec}, mixinInstance(exec):: __execMixin(exec), // Command is the command line to execute inside the container, the working directory for the command is root ('/') in the container's filesystem. The command is simply exec'd, it is not run inside a shell, so traditional shell instructions ('|', etc) won't work. To use a shell, you need to explicitly call out to that shell. Exit status of 0 is treated as live/healthy and non-zero is unhealthy. command(command):: if std.type(command) == "array" then __execMixin({command+: command}) else __execMixin({command+: [command]}), }, execType:: hidden.core.v1.execAction, // HTTPGet specifies the http request to perform. httpGet:: { local __httpGetMixin(httpGet) = {httpGet+: httpGet}, mixinInstance(httpGet):: __httpGetMixin(httpGet), // Host name to connect to, defaults to the pod IP. You probably want to set "Host" in httpHeaders instead. host(host):: __httpGetMixin({host: host}), // Custom headers to set in the request. HTTP allows repeated headers. httpHeaders(httpHeaders):: if std.type(httpHeaders) == "array" then __httpGetMixin({httpHeaders+: httpHeaders}) else __httpGetMixin({httpHeaders+: [httpHeaders]}), httpHeadersType:: hidden.core.v1.httpHeader, // Path to access on the HTTP server. path(path):: __httpGetMixin({path: path}), // Name or number of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. port(port):: __httpGetMixin({port: port}), // Scheme to use for connecting to the host. Defaults to HTTP. scheme(scheme):: __httpGetMixin({scheme: scheme}), }, httpGetType:: hidden.core.v1.httpGetAction, // TCPSocket specifies an action involving a TCP port. TCP hooks not yet supported tcpSocket:: { local __tcpSocketMixin(tcpSocket) = {tcpSocket+: tcpSocket}, mixinInstance(tcpSocket):: __tcpSocketMixin(tcpSocket), // Optional: Host name to connect to, defaults to the pod IP. host(host):: __tcpSocketMixin({host: host}), // Number or name of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. port(port):: __tcpSocketMixin({port: port}), }, tcpSocketType:: hidden.core.v1.tcpSocketAction, }, }, // HostAlias holds the mapping between IP and hostnames that will be injected as an entry in the pod's hosts file. hostAlias:: { new():: {}, // Hostnames for the above IP address. hostnames(hostnames):: if std.type(hostnames) == "array" then {hostnames+: hostnames} else {hostnames+: [hostnames]}, // IP address of the host file entry. ip(ip):: {ip: ip}, mixin:: { }, }, // Represents a host path mapped into a pod. Host path volumes do not support ownership management or SELinux relabeling. hostPathVolumeSource:: { new():: {}, // Path of the directory on the host. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath path(path):: {path: path}, mixin:: { }, }, // Represents an ISCSI disk. ISCSI volumes can only be mounted as read/write once. ISCSI volumes support ownership management and SELinux relabeling. iscsiVolumeSource:: { new():: {}, // whether support iSCSI Discovery CHAP authentication chapAuthDiscovery(chapAuthDiscovery):: {chapAuthDiscovery: chapAuthDiscovery}, // whether support iSCSI Session CHAP authentication chapAuthSession(chapAuthSession):: {chapAuthSession: chapAuthSession}, // Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#iscsi fsType(fsType):: {fsType: fsType}, // Target iSCSI Qualified Name. iqn(iqn):: {iqn: iqn}, // Optional: Defaults to 'default' (tcp). iSCSI interface name that uses an iSCSI transport. iscsiInterface(iscsiInterface):: {iscsiInterface: iscsiInterface}, // iSCSI target lun number. lun(lun):: {lun: lun}, // iSCSI target portal List. The portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260). portals(portals):: if std.type(portals) == "array" then {portals+: portals} else {portals+: [portals]}, // ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. readOnly(readOnly):: {readOnly: readOnly}, // iSCSI target portal. The portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260). targetPortal(targetPortal):: {targetPortal: targetPortal}, mixin:: { // CHAP secret for iSCSI target and initiator authentication secretRef:: { local __secretRefMixin(secretRef) = {secretRef+: secretRef}, mixinInstance(secretRef):: __secretRefMixin(secretRef), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), }, secretRefType:: hidden.core.v1.localObjectReference, }, }, // Maps a string key to a path within a volume. keyToPath:: { new(key, path):: {} + self.key(key) + self.path(path), // The key to project. key(key):: {key: key}, // Optional: mode bits to use on this file, must be a value between 0 and 0777. If not specified, the volume defaultMode will be used. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set. mode(mode):: {mode: mode}, // The relative path of the file to map the key to. May not be an absolute path. May not contain the path element '..'. May not start with the string '..'. path(path):: {path: path}, mixin:: { }, }, // Lifecycle describes actions that the management system should take in response to container lifecycle events. For the PostStart and PreStop lifecycle handlers, management of the container blocks until the action is complete, unless the container process fails, in which case the handler is aborted. lifecycle:: { new():: {}, mixin:: { // PostStart is called immediately after a container is created. If the handler fails, the container is terminated and restarted according to its restart policy. Other management of the container blocks until the hook completes. More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks postStart:: { local __postStartMixin(postStart) = {postStart+: postStart}, mixinInstance(postStart):: __postStartMixin(postStart), // One and only one of the following should be specified. Exec specifies the action to take. exec:: { local __execMixin(exec) = __postStartMixin({exec+: exec}), mixinInstance(exec):: __execMixin(exec), // Command is the command line to execute inside the container, the working directory for the command is root ('/') in the container's filesystem. The command is simply exec'd, it is not run inside a shell, so traditional shell instructions ('|', etc) won't work. To use a shell, you need to explicitly call out to that shell. Exit status of 0 is treated as live/healthy and non-zero is unhealthy. command(command):: if std.type(command) == "array" then __execMixin({command+: command}) else __execMixin({command+: [command]}), }, execType:: hidden.core.v1.execAction, // HTTPGet specifies the http request to perform. httpGet:: { local __httpGetMixin(httpGet) = __postStartMixin({httpGet+: httpGet}), mixinInstance(httpGet):: __httpGetMixin(httpGet), // Host name to connect to, defaults to the pod IP. You probably want to set "Host" in httpHeaders instead. host(host):: __httpGetMixin({host: host}), // Custom headers to set in the request. HTTP allows repeated headers. httpHeaders(httpHeaders):: if std.type(httpHeaders) == "array" then __httpGetMixin({httpHeaders+: httpHeaders}) else __httpGetMixin({httpHeaders+: [httpHeaders]}), httpHeadersType:: hidden.core.v1.httpHeader, // Path to access on the HTTP server. path(path):: __httpGetMixin({path: path}), // Name or number of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. port(port):: __httpGetMixin({port: port}), // Scheme to use for connecting to the host. Defaults to HTTP. scheme(scheme):: __httpGetMixin({scheme: scheme}), }, httpGetType:: hidden.core.v1.httpGetAction, // TCPSocket specifies an action involving a TCP port. TCP hooks not yet supported tcpSocket:: { local __tcpSocketMixin(tcpSocket) = __postStartMixin({tcpSocket+: tcpSocket}), mixinInstance(tcpSocket):: __tcpSocketMixin(tcpSocket), // Optional: Host name to connect to, defaults to the pod IP. host(host):: __tcpSocketMixin({host: host}), // Number or name of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. port(port):: __tcpSocketMixin({port: port}), }, tcpSocketType:: hidden.core.v1.tcpSocketAction, }, postStartType:: hidden.core.v1.handler, // PreStop is called immediately before a container is terminated. The container is terminated after the handler completes. The reason for termination is passed to the handler. Regardless of the outcome of the handler, the container is eventually terminated. Other management of the container blocks until the hook completes. More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks preStop:: { local __preStopMixin(preStop) = {preStop+: preStop}, mixinInstance(preStop):: __preStopMixin(preStop), // One and only one of the following should be specified. Exec specifies the action to take. exec:: { local __execMixin(exec) = __preStopMixin({exec+: exec}), mixinInstance(exec):: __execMixin(exec), // Command is the command line to execute inside the container, the working directory for the command is root ('/') in the container's filesystem. The command is simply exec'd, it is not run inside a shell, so traditional shell instructions ('|', etc) won't work. To use a shell, you need to explicitly call out to that shell. Exit status of 0 is treated as live/healthy and non-zero is unhealthy. command(command):: if std.type(command) == "array" then __execMixin({command+: command}) else __execMixin({command+: [command]}), }, execType:: hidden.core.v1.execAction, // HTTPGet specifies the http request to perform. httpGet:: { local __httpGetMixin(httpGet) = __preStopMixin({httpGet+: httpGet}), mixinInstance(httpGet):: __httpGetMixin(httpGet), // Host name to connect to, defaults to the pod IP. You probably want to set "Host" in httpHeaders instead. host(host):: __httpGetMixin({host: host}), // Custom headers to set in the request. HTTP allows repeated headers. httpHeaders(httpHeaders):: if std.type(httpHeaders) == "array" then __httpGetMixin({httpHeaders+: httpHeaders}) else __httpGetMixin({httpHeaders+: [httpHeaders]}), httpHeadersType:: hidden.core.v1.httpHeader, // Path to access on the HTTP server. path(path):: __httpGetMixin({path: path}), // Name or number of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. port(port):: __httpGetMixin({port: port}), // Scheme to use for connecting to the host. Defaults to HTTP. scheme(scheme):: __httpGetMixin({scheme: scheme}), }, httpGetType:: hidden.core.v1.httpGetAction, // TCPSocket specifies an action involving a TCP port. TCP hooks not yet supported tcpSocket:: { local __tcpSocketMixin(tcpSocket) = __preStopMixin({tcpSocket+: tcpSocket}), mixinInstance(tcpSocket):: __tcpSocketMixin(tcpSocket), // Optional: Host name to connect to, defaults to the pod IP. host(host):: __tcpSocketMixin({host: host}), // Number or name of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. port(port):: __tcpSocketMixin({port: port}), }, tcpSocketType:: hidden.core.v1.tcpSocketAction, }, preStopType:: hidden.core.v1.handler, }, }, // LimitRangeItem defines a min/max usage limit for any resource that matches on kind. limitRangeItem:: { new():: {}, // Default resource requirement limit value by resource name if resource limit is omitted. default(default):: {default+: default}, // DefaultRequest is the default resource requirement request value by resource name if resource request is omitted. defaultRequest(defaultRequest):: {defaultRequest+: defaultRequest}, // Max usage constraints on this kind by resource name. max(max):: {max+: max}, // 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. maxLimitRequestRatio(maxLimitRequestRatio):: {maxLimitRequestRatio+: maxLimitRequestRatio}, // Min usage constraints on this kind by resource name. min(min):: {min+: min}, // Type of resource that this limit applies to. type(type):: {type: type}, mixin:: { }, }, // LimitRangeSpec defines a min/max usage limit for resources that match on kind. limitRangeSpec:: { new():: {}, // Limits is the list of LimitRangeItem objects that are enforced. limits(limits):: if std.type(limits) == "array" then {limits+: limits} else {limits+: [limits]}, limitsType:: hidden.core.v1.limitRangeItem, mixin:: { }, }, // LoadBalancerIngress represents the status of a load-balancer ingress point: traffic intended for the service should be sent to an ingress point. loadBalancerIngress:: { new():: {}, // Hostname is set for load-balancer ingress points that are DNS based (typically AWS load-balancers) hostname(hostname):: {hostname: hostname}, // IP is set for load-balancer ingress points that are IP based (typically GCE or OpenStack load-balancers) ip(ip):: {ip: ip}, mixin:: { }, }, // LoadBalancerStatus represents the status of a load-balancer. loadBalancerStatus:: { new():: {}, // Ingress is a list containing ingress points for the load-balancer. Traffic intended for the service should be sent to these ingress points. ingress(ingress):: if std.type(ingress) == "array" then {ingress+: ingress} else {ingress+: [ingress]}, ingressType:: hidden.core.v1.loadBalancerIngress, mixin:: { }, }, // LocalObjectReference contains enough information to let you locate the referenced object inside the same namespace. localObjectReference:: { new():: {}, // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: {name: name}, mixin:: { }, }, // Local represents directly-attached storage with node affinity localVolumeSource:: { new():: {}, // The full path to the volume on the node For alpha, this path must be a directory Once block as a source is supported, then this path can point to a block device path(path):: {path: path}, mixin:: { }, }, // Represents an NFS mount that lasts the lifetime of a pod. NFS volumes do not support ownership management or SELinux relabeling. nfsVolumeSource:: { new():: {}, // Path that is exported by the NFS server. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs path(path):: {path: path}, // ReadOnly here will force the NFS export to be mounted with read-only permissions. Defaults to false. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs readOnly(readOnly):: {readOnly: readOnly}, // Server is the hostname or IP address of the NFS server. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs server(server):: {server: server}, mixin:: { }, }, // NamespaceSpec describes the attributes on a Namespace. namespaceSpec:: { new():: {}, // Finalizers is an opaque list of values that must be empty to permanently remove object from storage. More info: https://git.k8s.io/community/contributors/design-proposals/namespaces.md#finalizers finalizers(finalizers):: if std.type(finalizers) == "array" then {finalizers+: finalizers} else {finalizers+: [finalizers]}, mixin:: { }, }, // NamespaceStatus is information about the current status of a Namespace. namespaceStatus:: { new():: {}, // Phase is the current lifecycle phase of the namespace. More info: https://git.k8s.io/community/contributors/design-proposals/namespaces.md#phases phase(phase):: {phase: phase}, mixin:: { }, }, // NodeAddress contains information for the node's address. nodeAddress:: { new():: {}, // The node address. address(address):: {address: address}, // Node address type, one of Hostname, ExternalIP or InternalIP. type(type):: {type: type}, mixin:: { }, }, // Node affinity is a group of node affinity scheduling rules. nodeAffinity:: { new():: {}, // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then {preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution} else {preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}, preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.preferredSchedulingTerm, mixin:: { // If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node. requiredDuringSchedulingIgnoredDuringExecution:: { local __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution) = {requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}, mixinInstance(requiredDuringSchedulingIgnoredDuringExecution):: __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution), // Required. A list of node selector terms. The terms are ORed. nodeSelectorTerms(nodeSelectorTerms):: if std.type(nodeSelectorTerms) == "array" then __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: nodeSelectorTerms}) else __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: [nodeSelectorTerms]}), nodeSelectorTermsType:: hidden.core.v1.nodeSelectorTerm, }, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.nodeSelector, }, }, // NodeCondition contains condition information for a node. nodeCondition:: { new():: {}, // Human readable message indicating details about last transition. message(message):: {message: message}, // (brief) reason for the condition's last transition. reason(reason):: {reason: reason}, // Type of node condition. type(type):: {type: type}, mixin:: { // Last time we got an update on a given condition. lastHeartbeatTime:: { local __lastHeartbeatTimeMixin(lastHeartbeatTime) = {lastHeartbeatTime+: lastHeartbeatTime}, mixinInstance(lastHeartbeatTime):: __lastHeartbeatTimeMixin(lastHeartbeatTime), }, lastHeartbeatTimeType:: hidden.meta.v1.time, // Last time the condition transit from one status to another. lastTransitionTime:: { local __lastTransitionTimeMixin(lastTransitionTime) = {lastTransitionTime+: lastTransitionTime}, mixinInstance(lastTransitionTime):: __lastTransitionTimeMixin(lastTransitionTime), }, lastTransitionTimeType:: hidden.meta.v1.time, }, }, // NodeDaemonEndpoints lists ports opened by daemons running on the Node. nodeDaemonEndpoints:: { new():: {}, mixin:: { // Endpoint on which Kubelet is listening. kubeletEndpoint:: { local __kubeletEndpointMixin(kubeletEndpoint) = {kubeletEndpoint+: kubeletEndpoint}, mixinInstance(kubeletEndpoint):: __kubeletEndpointMixin(kubeletEndpoint), // Port number of the given endpoint. port(port):: __kubeletEndpointMixin({Port: port}), }, kubeletEndpointType:: hidden.core.v1.daemonEndpoint, }, }, // A node selector represents the union of the results of one or more label queries over a set of nodes; that is, it represents the OR of the selectors represented by the node selector terms. nodeSelector:: { new():: {}, // Required. A list of node selector terms. The terms are ORed. nodeSelectorTerms(nodeSelectorTerms):: if std.type(nodeSelectorTerms) == "array" then {nodeSelectorTerms+: nodeSelectorTerms} else {nodeSelectorTerms+: [nodeSelectorTerms]}, nodeSelectorTermsType:: hidden.core.v1.nodeSelectorTerm, mixin:: { }, }, // A node selector requirement is a selector that contains values, a key, and an operator that relates the key and values. nodeSelectorRequirement:: { new():: {}, // The label key that the selector applies to. key(key):: {key: key}, // Represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists, DoesNotExist. Gt, and Lt. operator(operator):: {operator: operator}, // An array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. If the operator is Gt or Lt, the values array must have a single element, which will be interpreted as an integer. This array is replaced during a strategic merge patch. values(values):: if std.type(values) == "array" then {values+: values} else {values+: [values]}, mixin:: { }, }, // A null or empty node selector term matches no objects. nodeSelectorTerm:: { new():: {}, // Required. A list of node selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then {matchExpressions+: matchExpressions} else {matchExpressions+: [matchExpressions]}, matchExpressionsType:: hidden.core.v1.nodeSelectorRequirement, mixin:: { }, }, // NodeSpec describes the attributes that a node is created with. nodeSpec:: { new():: {}, // External ID of the node assigned by some machine database (e.g. a cloud provider). Deprecated. externalId(externalId):: {externalID: externalId}, // PodCIDR represents the pod IP range assigned to the node. podCidr(podCidr):: {podCIDR: podCidr}, // ID of the node assigned by the cloud provider in the format: :// providerId(providerId):: {providerID: providerId}, // If specified, the node's taints. taints(taints):: if std.type(taints) == "array" then {taints+: taints} else {taints+: [taints]}, taintsType:: hidden.core.v1.taint, // Unschedulable controls node schedulability of new pods. By default, node is schedulable. More info: https://kubernetes.io/docs/concepts/nodes/node/#manual-node-administration unschedulable(unschedulable):: {unschedulable: unschedulable}, mixin:: { }, }, // NodeStatus is information about the current status of a node. nodeStatus:: { new():: {}, // List of addresses reachable to the node. Queried from cloud provider, if available. More info: https://kubernetes.io/docs/concepts/nodes/node/#addresses addresses(addresses):: if std.type(addresses) == "array" then {addresses+: addresses} else {addresses+: [addresses]}, addressesType:: hidden.core.v1.nodeAddress, // Allocatable represents the resources of a node that are available for scheduling. Defaults to Capacity. allocatable(allocatable):: {allocatable+: allocatable}, // Capacity represents the total resources of a node. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#capacity capacity(capacity):: {capacity+: capacity}, // Conditions is an array of current observed node conditions. More info: https://kubernetes.io/docs/concepts/nodes/node/#condition conditions(conditions):: if std.type(conditions) == "array" then {conditions+: conditions} else {conditions+: [conditions]}, conditionsType:: hidden.core.v1.nodeCondition, // List of container images on this node images(images):: if std.type(images) == "array" then {images+: images} else {images+: [images]}, imagesType:: hidden.core.v1.containerImage, // NodePhase is the recently observed lifecycle phase of the node. More info: https://kubernetes.io/docs/concepts/nodes/node/#phase The field is never populated, and now is deprecated. phase(phase):: {phase: phase}, // List of volumes that are attached to the node. volumesAttached(volumesAttached):: if std.type(volumesAttached) == "array" then {volumesAttached+: volumesAttached} else {volumesAttached+: [volumesAttached]}, volumesAttachedType:: hidden.core.v1.attachedVolume, // List of attachable volumes in use (mounted) by the node. volumesInUse(volumesInUse):: if std.type(volumesInUse) == "array" then {volumesInUse+: volumesInUse} else {volumesInUse+: [volumesInUse]}, mixin:: { // Endpoints of daemons running on the Node. daemonEndpoints:: { local __daemonEndpointsMixin(daemonEndpoints) = {daemonEndpoints+: daemonEndpoints}, mixinInstance(daemonEndpoints):: __daemonEndpointsMixin(daemonEndpoints), // Endpoint on which Kubelet is listening. kubeletEndpoint:: { local __kubeletEndpointMixin(kubeletEndpoint) = __daemonEndpointsMixin({kubeletEndpoint+: kubeletEndpoint}), mixinInstance(kubeletEndpoint):: __kubeletEndpointMixin(kubeletEndpoint), // Port number of the given endpoint. port(port):: __kubeletEndpointMixin({Port: port}), }, kubeletEndpointType:: hidden.core.v1.daemonEndpoint, }, daemonEndpointsType:: hidden.core.v1.nodeDaemonEndpoints, // Set of ids/uuids to uniquely identify the node. More info: https://kubernetes.io/docs/concepts/nodes/node/#info nodeInfo:: { local __nodeInfoMixin(nodeInfo) = {nodeInfo+: nodeInfo}, mixinInstance(nodeInfo):: __nodeInfoMixin(nodeInfo), // The Architecture reported by the node architecture(architecture):: __nodeInfoMixin({architecture: architecture}), // Boot ID reported by the node. bootId(bootId):: __nodeInfoMixin({bootID: bootId}), // ContainerRuntime Version reported by the node through runtime remote API (e.g. docker://1.5.0). containerRuntimeVersion(containerRuntimeVersion):: __nodeInfoMixin({containerRuntimeVersion: containerRuntimeVersion}), // Kernel Version reported by the node from 'uname -r' (e.g. 3.16.0-0.bpo.4-amd64). kernelVersion(kernelVersion):: __nodeInfoMixin({kernelVersion: kernelVersion}), // KubeProxy Version reported by the node. kubeProxyVersion(kubeProxyVersion):: __nodeInfoMixin({kubeProxyVersion: kubeProxyVersion}), // Kubelet Version reported by the node. kubeletVersion(kubeletVersion):: __nodeInfoMixin({kubeletVersion: kubeletVersion}), // MachineID reported by the node. For unique machine identification in the cluster this field is preferred. Learn more from man(5) machine-id: http://man7.org/linux/man-pages/man5/machine-id.5.html machineId(machineId):: __nodeInfoMixin({machineID: machineId}), // The Operating System reported by the node operatingSystem(operatingSystem):: __nodeInfoMixin({operatingSystem: operatingSystem}), // OS Image reported by the node from /etc/os-release (e.g. Debian GNU/Linux 7 (wheezy)). osImage(osImage):: __nodeInfoMixin({osImage: osImage}), // SystemUUID reported by the node. For unique machine identification MachineID is preferred. This field is specific to Red Hat hosts https://access.redhat.com/documentation/en-US/Red_Hat_Subscription_Management/1/html/RHSM/getting-system-uuid.html systemUuid(systemUuid):: __nodeInfoMixin({systemUUID: systemUuid}), }, nodeInfoType:: hidden.core.v1.nodeSystemInfo, }, }, // NodeSystemInfo is a set of ids/uuids to uniquely identify the node. nodeSystemInfo:: { new():: {}, // The Architecture reported by the node architecture(architecture):: {architecture: architecture}, // Boot ID reported by the node. bootId(bootId):: {bootID: bootId}, // ContainerRuntime Version reported by the node through runtime remote API (e.g. docker://1.5.0). containerRuntimeVersion(containerRuntimeVersion):: {containerRuntimeVersion: containerRuntimeVersion}, // Kernel Version reported by the node from 'uname -r' (e.g. 3.16.0-0.bpo.4-amd64). kernelVersion(kernelVersion):: {kernelVersion: kernelVersion}, // KubeProxy Version reported by the node. kubeProxyVersion(kubeProxyVersion):: {kubeProxyVersion: kubeProxyVersion}, // Kubelet Version reported by the node. kubeletVersion(kubeletVersion):: {kubeletVersion: kubeletVersion}, // MachineID reported by the node. For unique machine identification in the cluster this field is preferred. Learn more from man(5) machine-id: http://man7.org/linux/man-pages/man5/machine-id.5.html machineId(machineId):: {machineID: machineId}, // The Operating System reported by the node operatingSystem(operatingSystem):: {operatingSystem: operatingSystem}, // OS Image reported by the node from /etc/os-release (e.g. Debian GNU/Linux 7 (wheezy)). osImage(osImage):: {osImage: osImage}, // SystemUUID reported by the node. For unique machine identification MachineID is preferred. This field is specific to Red Hat hosts https://access.redhat.com/documentation/en-US/Red_Hat_Subscription_Management/1/html/RHSM/getting-system-uuid.html systemUuid(systemUuid):: {systemUUID: systemUuid}, mixin:: { }, }, // ObjectFieldSelector selects an APIVersioned field of an object. objectFieldSelector:: { new():: {}, // Path of the field to select in the specified API version. fieldPath(fieldPath):: {fieldPath: fieldPath}, mixin:: { }, }, // ObjectReference contains enough information to let you inspect or modify the referred object. objectReference:: { new():: {}, // If referring to a piece of an object instead of an entire object, this string should contain a valid JSON/Go field access statement, such as desiredState.manifest.containers[2]. For example, if the object reference is to a container within a pod, this would take on a value like: "spec.containers{name}" (where "name" refers to the name of the container that triggered the event) or if no container name is specified "spec.containers[2]" (container with index 2 in this pod). This syntax is chosen only to have some well-defined way of referencing a part of an object. fieldPath(fieldPath):: {fieldPath: fieldPath}, // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: {name: name}, // Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ namespace(namespace):: {namespace: namespace}, // Specific resourceVersion to which this reference is made, if any. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency resourceVersion(resourceVersion):: {resourceVersion: resourceVersion}, // UID of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids uid(uid):: {uid: uid}, mixin:: { }, }, // PersistentVolumeClaimSpec describes the common attributes of storage devices and allows a Source for provider-specific attributes persistentVolumeClaimSpec:: { new():: {}, // AccessModes contains the desired access modes the volume should have. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes-1 accessModes(accessModes):: if std.type(accessModes) == "array" then {accessModes+: accessModes} else {accessModes+: [accessModes]}, // Name of the StorageClass required by the claim. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#class-1 storageClassName(storageClassName):: {storageClassName: storageClassName}, // VolumeName is the binding reference to the PersistentVolume backing this claim. volumeName(volumeName):: {volumeName: volumeName}, mixin:: { // Resources represents the minimum resources the volume should have. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources resources:: { local __resourcesMixin(resources) = {resources+: resources}, mixinInstance(resources):: __resourcesMixin(resources), // Limits describes the maximum amount of compute resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ limits(limits):: __resourcesMixin({limits+: limits}), // Requests describes the minimum amount of compute resources required. If Requests is omitted for a container, it defaults to Limits if that is explicitly specified, otherwise to an implementation-defined value. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ requests(requests):: __resourcesMixin({requests+: requests}), }, resourcesType:: hidden.core.v1.resourceRequirements, // A label query over volumes to consider for binding. selector:: { local __selectorMixin(selector) = {selector+: selector}, mixinInstance(selector):: __selectorMixin(selector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __selectorMixin({matchExpressions+: matchExpressions}) else __selectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __selectorMixin({matchLabels+: matchLabels}), }, selectorType:: hidden.meta.v1.labelSelector, }, }, // PersistentVolumeClaimStatus is the current status of a persistent volume claim. persistentVolumeClaimStatus:: { new():: {}, // AccessModes contains the actual access modes the volume backing the PVC has. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes-1 accessModes(accessModes):: if std.type(accessModes) == "array" then {accessModes+: accessModes} else {accessModes+: [accessModes]}, // Represents the actual resources of the underlying volume. capacity(capacity):: {capacity+: capacity}, // Phase represents the current phase of PersistentVolumeClaim. phase(phase):: {phase: phase}, mixin:: { }, }, // PersistentVolumeClaimVolumeSource references the user's PVC in the same namespace. This volume finds the bound PV and mounts that volume for the pod. A PersistentVolumeClaimVolumeSource is, essentially, a wrapper around another type of volume that is owned by someone else (the system). persistentVolumeClaimVolumeSource:: { new():: {}, // ClaimName is the name of a PersistentVolumeClaim in the same namespace as the pod using this volume. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims claimName(claimName):: {claimName: claimName}, // Will force the ReadOnly setting in VolumeMounts. Default false. readOnly(readOnly):: {readOnly: readOnly}, mixin:: { }, }, // PersistentVolumeSpec is the specification of a persistent volume. persistentVolumeSpec:: { new():: {}, // AccessModes contains all ways the volume can be mounted. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes accessModes(accessModes):: if std.type(accessModes) == "array" then {accessModes+: accessModes} else {accessModes+: [accessModes]}, // A description of the persistent volume's resources and capacity. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#capacity capacity(capacity):: {capacity+: capacity}, // What happens to a persistent volume when released from its claim. Valid options are Retain (default) and Recycle. Recycling must be supported by the volume plugin underlying this persistent volume. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#reclaiming persistentVolumeReclaimPolicy(persistentVolumeReclaimPolicy):: {persistentVolumeReclaimPolicy: persistentVolumeReclaimPolicy}, // Name of StorageClass to which this persistent volume belongs. Empty value means that this volume does not belong to any StorageClass. storageClassName(storageClassName):: {storageClassName: storageClassName}, mixin:: { // AWSElasticBlockStore represents an AWS Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore awsElasticBlockStore:: { local __awsElasticBlockStoreMixin(awsElasticBlockStore) = {awsElasticBlockStore+: awsElasticBlockStore}, mixinInstance(awsElasticBlockStore):: __awsElasticBlockStoreMixin(awsElasticBlockStore), // Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore fsType(fsType):: __awsElasticBlockStoreMixin({fsType: fsType}), // The partition in the volume that you want to mount. If omitted, the default is to mount by volume name. Examples: For volume /dev/sda1, you specify the partition as "1". Similarly, the volume partition for /dev/sda is "0" (or you can leave the property empty). partition(partition):: __awsElasticBlockStoreMixin({partition: partition}), // Specify "true" to force and set the ReadOnly property in VolumeMounts to "true". If omitted, the default is "false". More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore readOnly(readOnly):: __awsElasticBlockStoreMixin({readOnly: readOnly}), // Unique ID of the persistent disk resource in AWS (Amazon EBS volume). More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore volumeId(volumeId):: __awsElasticBlockStoreMixin({volumeID: volumeId}), }, awsElasticBlockStoreType:: hidden.core.v1.awsElasticBlockStoreVolumeSource, // AzureDisk represents an Azure Data Disk mount on the host and bind mount to the pod. azureDisk:: { local __azureDiskMixin(azureDisk) = {azureDisk+: azureDisk}, mixinInstance(azureDisk):: __azureDiskMixin(azureDisk), // Host Caching mode: None, Read Only, Read Write. cachingMode(cachingMode):: __azureDiskMixin({cachingMode: cachingMode}), // The Name of the data disk in the blob storage diskName(diskName):: __azureDiskMixin({diskName: diskName}), // The URI the data disk in the blob storage diskUri(diskUri):: __azureDiskMixin({diskURI: diskUri}), // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: __azureDiskMixin({fsType: fsType}), // Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: __azureDiskMixin({readOnly: readOnly}), }, azureDiskType:: hidden.core.v1.azureDiskVolumeSource, // AzureFile represents an Azure File Service mount on the host and bind mount to the pod. azureFile:: { local __azureFileMixin(azureFile) = {azureFile+: azureFile}, mixinInstance(azureFile):: __azureFileMixin(azureFile), // Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: __azureFileMixin({readOnly: readOnly}), // the name of secret that contains Azure Storage Account Name and Key secretName(secretName):: __azureFileMixin({secretName: secretName}), // Share Name shareName(shareName):: __azureFileMixin({shareName: shareName}), }, azureFileType:: hidden.core.v1.azureFileVolumeSource, // CephFS represents a Ceph FS mount on the host that shares a pod's lifetime cephfs:: { local __cephfsMixin(cephfs) = {cephfs+: cephfs}, mixinInstance(cephfs):: __cephfsMixin(cephfs), // Required: Monitors is a collection of Ceph monitors More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it monitors(monitors):: if std.type(monitors) == "array" then __cephfsMixin({monitors+: monitors}) else __cephfsMixin({monitors+: [monitors]}), // Optional: Used as the mounted root, rather than the full Ceph tree, default is / path(path):: __cephfsMixin({path: path}), // Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it readOnly(readOnly):: __cephfsMixin({readOnly: readOnly}), // Optional: SecretFile is the path to key ring for User, default is /etc/ceph/user.secret More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it secretFile(secretFile):: __cephfsMixin({secretFile: secretFile}), // Optional: SecretRef is reference to the authentication secret for User, default is empty. More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it secretRef:: { local __secretRefMixin(secretRef) = __cephfsMixin({secretRef+: secretRef}), mixinInstance(secretRef):: __secretRefMixin(secretRef), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), }, secretRefType:: hidden.core.v1.localObjectReference, // Optional: User is the rados user name, default is admin More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it user(user):: __cephfsMixin({user: user}), }, cephfsType:: hidden.core.v1.cephFsVolumeSource, // Cinder represents a cinder volume attached and mounted on kubelets host machine More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md cinder:: { local __cinderMixin(cinder) = {cinder+: cinder}, mixinInstance(cinder):: __cinderMixin(cinder), // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md fsType(fsType):: __cinderMixin({fsType: fsType}), // Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md readOnly(readOnly):: __cinderMixin({readOnly: readOnly}), // volume id used to identify the volume in cinder More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md volumeId(volumeId):: __cinderMixin({volumeID: volumeId}), }, cinderType:: hidden.core.v1.cinderVolumeSource, // ClaimRef is part of a bi-directional binding between PersistentVolume and PersistentVolumeClaim. Expected to be non-nil when bound. claim.VolumeName is the authoritative bind between PV and PVC. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#binding claimRef:: { local __claimRefMixin(claimRef) = {claimRef+: claimRef}, mixinInstance(claimRef):: __claimRefMixin(claimRef), // If referring to a piece of an object instead of an entire object, this string should contain a valid JSON/Go field access statement, such as desiredState.manifest.containers[2]. For example, if the object reference is to a container within a pod, this would take on a value like: "spec.containers{name}" (where "name" refers to the name of the container that triggered the event) or if no container name is specified "spec.containers[2]" (container with index 2 in this pod). This syntax is chosen only to have some well-defined way of referencing a part of an object. fieldPath(fieldPath):: __claimRefMixin({fieldPath: fieldPath}), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __claimRefMixin({name: name}), // Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ namespace(namespace):: __claimRefMixin({namespace: namespace}), // Specific resourceVersion to which this reference is made, if any. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency resourceVersion(resourceVersion):: __claimRefMixin({resourceVersion: resourceVersion}), // UID of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids uid(uid):: __claimRefMixin({uid: uid}), }, claimRefType:: hidden.core.v1.objectReference, // FC represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod. fc:: { local __fcMixin(fc) = {fc+: fc}, mixinInstance(fc):: __fcMixin(fc), // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: __fcMixin({fsType: fsType}), // Required: FC target lun number lun(lun):: __fcMixin({lun: lun}), // Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: __fcMixin({readOnly: readOnly}), // Required: FC target worldwide names (WWNs) targetWwns(targetWwns):: if std.type(targetWwns) == "array" then __fcMixin({targetWWNs+: targetWwns}) else __fcMixin({targetWWNs+: [targetWwns]}), }, fcType:: hidden.core.v1.fcVolumeSource, // FlexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin. This is an alpha feature and may change in future. flexVolume:: { local __flexVolumeMixin(flexVolume) = {flexVolume+: flexVolume}, mixinInstance(flexVolume):: __flexVolumeMixin(flexVolume), // Driver is the name of the driver to use for this volume. driver(driver):: __flexVolumeMixin({driver: driver}), // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". The default filesystem depends on FlexVolume script. fsType(fsType):: __flexVolumeMixin({fsType: fsType}), // Optional: Extra command options if any. options(options):: __flexVolumeMixin({options+: options}), // Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: __flexVolumeMixin({readOnly: readOnly}), // Optional: SecretRef is reference to the secret object containing sensitive information to pass to the plugin scripts. This may be empty if no secret object is specified. If the secret object contains more than one secret, all secrets are passed to the plugin scripts. secretRef:: { local __secretRefMixin(secretRef) = __flexVolumeMixin({secretRef+: secretRef}), mixinInstance(secretRef):: __secretRefMixin(secretRef), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), }, secretRefType:: hidden.core.v1.localObjectReference, }, flexVolumeType:: hidden.core.v1.flexVolumeSource, // 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 flocker:: { local __flockerMixin(flocker) = {flocker+: flocker}, mixinInstance(flocker):: __flockerMixin(flocker), // Name of the dataset stored as metadata -> name on the dataset for Flocker should be considered as deprecated datasetName(datasetName):: __flockerMixin({datasetName: datasetName}), // UUID of the dataset. This is unique identifier of a Flocker dataset datasetUuid(datasetUuid):: __flockerMixin({datasetUUID: datasetUuid}), }, flockerType:: hidden.core.v1.flockerVolumeSource, // GCEPersistentDisk represents a GCE Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Provisioned by an admin. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk gcePersistentDisk:: { local __gcePersistentDiskMixin(gcePersistentDisk) = {gcePersistentDisk+: gcePersistentDisk}, mixinInstance(gcePersistentDisk):: __gcePersistentDiskMixin(gcePersistentDisk), // Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk fsType(fsType):: __gcePersistentDiskMixin({fsType: fsType}), // The partition in the volume that you want to mount. If omitted, the default is to mount by volume name. Examples: For volume /dev/sda1, you specify the partition as "1". Similarly, the volume partition for /dev/sda is "0" (or you can leave the property empty). More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk partition(partition):: __gcePersistentDiskMixin({partition: partition}), // Unique name of the PD resource in GCE. Used to identify the disk in GCE. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk pdName(pdName):: __gcePersistentDiskMixin({pdName: pdName}), // ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk readOnly(readOnly):: __gcePersistentDiskMixin({readOnly: readOnly}), }, gcePersistentDiskType:: hidden.core.v1.gcePersistentDiskVolumeSource, // Glusterfs represents a Glusterfs volume that is attached to a host and exposed to the pod. Provisioned by an admin. More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md glusterfs:: { local __glusterfsMixin(glusterfs) = {glusterfs+: glusterfs}, mixinInstance(glusterfs):: __glusterfsMixin(glusterfs), // EndpointsName is the endpoint name that details Glusterfs topology. More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod endpoints(endpoints):: __glusterfsMixin({endpoints: endpoints}), // Path is the Glusterfs volume path. More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod path(path):: __glusterfsMixin({path: path}), // ReadOnly here will force the Glusterfs volume to be mounted with read-only permissions. Defaults to false. More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod readOnly(readOnly):: __glusterfsMixin({readOnly: readOnly}), }, glusterfsType:: hidden.core.v1.glusterfsVolumeSource, // HostPath represents a directory on the host. Provisioned by a developer or tester. This is useful for single-node development and testing only! On-host storage is not supported in any way and WILL NOT WORK in a multi-node cluster. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath hostPath:: { local __hostPathMixin(hostPath) = {hostPath+: hostPath}, mixinInstance(hostPath):: __hostPathMixin(hostPath), // Path of the directory on the host. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath path(path):: __hostPathMixin({path: path}), }, hostPathType:: hidden.core.v1.hostPathVolumeSource, // ISCSI represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Provisioned by an admin. iscsi:: { local __iscsiMixin(iscsi) = {iscsi+: iscsi}, mixinInstance(iscsi):: __iscsiMixin(iscsi), // whether support iSCSI Discovery CHAP authentication chapAuthDiscovery(chapAuthDiscovery):: __iscsiMixin({chapAuthDiscovery: chapAuthDiscovery}), // whether support iSCSI Session CHAP authentication chapAuthSession(chapAuthSession):: __iscsiMixin({chapAuthSession: chapAuthSession}), // Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#iscsi fsType(fsType):: __iscsiMixin({fsType: fsType}), // Target iSCSI Qualified Name. iqn(iqn):: __iscsiMixin({iqn: iqn}), // Optional: Defaults to 'default' (tcp). iSCSI interface name that uses an iSCSI transport. iscsiInterface(iscsiInterface):: __iscsiMixin({iscsiInterface: iscsiInterface}), // iSCSI target lun number. lun(lun):: __iscsiMixin({lun: lun}), // iSCSI target portal List. The portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260). portals(portals):: if std.type(portals) == "array" then __iscsiMixin({portals+: portals}) else __iscsiMixin({portals+: [portals]}), // ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. readOnly(readOnly):: __iscsiMixin({readOnly: readOnly}), // CHAP secret for iSCSI target and initiator authentication secretRef:: { local __secretRefMixin(secretRef) = __iscsiMixin({secretRef+: secretRef}), mixinInstance(secretRef):: __secretRefMixin(secretRef), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), }, secretRefType:: hidden.core.v1.localObjectReference, // iSCSI target portal. The portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260). targetPortal(targetPortal):: __iscsiMixin({targetPortal: targetPortal}), }, iscsiType:: hidden.core.v1.iscsiVolumeSource, // Local represents directly-attached storage with node affinity localStorage:: { local __localStorageMixin(localStorage) = {"local"+: localStorage}, mixinInstance(localStorage):: __localStorageMixin(localStorage), // The full path to the volume on the node For alpha, this path must be a directory Once block as a source is supported, then this path can point to a block device path(path):: __localStorageMixin({path: path}), }, localStorageType:: hidden.core.v1.localVolumeSource, // NFS represents an NFS mount on the host. Provisioned by an admin. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs nfs:: { local __nfsMixin(nfs) = {nfs+: nfs}, mixinInstance(nfs):: __nfsMixin(nfs), // Path that is exported by the NFS server. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs path(path):: __nfsMixin({path: path}), // ReadOnly here will force the NFS export to be mounted with read-only permissions. Defaults to false. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs readOnly(readOnly):: __nfsMixin({readOnly: readOnly}), // Server is the hostname or IP address of the NFS server. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs server(server):: __nfsMixin({server: server}), }, nfsType:: hidden.core.v1.nfsVolumeSource, // PhotonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine photonPersistentDisk:: { local __photonPersistentDiskMixin(photonPersistentDisk) = {photonPersistentDisk+: photonPersistentDisk}, mixinInstance(photonPersistentDisk):: __photonPersistentDiskMixin(photonPersistentDisk), // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: __photonPersistentDiskMixin({fsType: fsType}), // ID that identifies Photon Controller persistent disk pdId(pdId):: __photonPersistentDiskMixin({pdID: pdId}), }, photonPersistentDiskType:: hidden.core.v1.photonPersistentDiskVolumeSource, // PortworxVolume represents a portworx volume attached and mounted on kubelets host machine portworxVolume:: { local __portworxVolumeMixin(portworxVolume) = {portworxVolume+: portworxVolume}, mixinInstance(portworxVolume):: __portworxVolumeMixin(portworxVolume), // FSType represents the filesystem type to mount Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: __portworxVolumeMixin({fsType: fsType}), // Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: __portworxVolumeMixin({readOnly: readOnly}), // VolumeID uniquely identifies a Portworx volume volumeId(volumeId):: __portworxVolumeMixin({volumeID: volumeId}), }, portworxVolumeType:: hidden.core.v1.portworxVolumeSource, // Quobyte represents a Quobyte mount on the host that shares a pod's lifetime quobyte:: { local __quobyteMixin(quobyte) = {quobyte+: quobyte}, mixinInstance(quobyte):: __quobyteMixin(quobyte), // Group to map volume access to Default is no group group(group):: __quobyteMixin({group: group}), // ReadOnly here will force the Quobyte volume to be mounted with read-only permissions. Defaults to false. readOnly(readOnly):: __quobyteMixin({readOnly: readOnly}), // Registry represents a single or multiple Quobyte Registry services specified as a string as host:port pair (multiple entries are separated with commas) which acts as the central registry for volumes registry(registry):: __quobyteMixin({registry: registry}), // User to map volume access to Defaults to serivceaccount user user(user):: __quobyteMixin({user: user}), // Volume is a string that references an already created Quobyte volume by name. volume(volume):: __quobyteMixin({volume: volume}), }, quobyteType:: hidden.core.v1.quobyteVolumeSource, // RBD represents a Rados Block Device mount on the host that shares a pod's lifetime. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md rbd:: { local __rbdMixin(rbd) = {rbd+: rbd}, mixinInstance(rbd):: __rbdMixin(rbd), // Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#rbd fsType(fsType):: __rbdMixin({fsType: fsType}), // The rados image name. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it image(image):: __rbdMixin({image: image}), // Keyring is the path to key ring for RBDUser. Default is /etc/ceph/keyring. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it keyring(keyring):: __rbdMixin({keyring: keyring}), // A collection of Ceph monitors. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it monitors(monitors):: if std.type(monitors) == "array" then __rbdMixin({monitors+: monitors}) else __rbdMixin({monitors+: [monitors]}), // The rados pool name. Default is rbd. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it pool(pool):: __rbdMixin({pool: pool}), // ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it readOnly(readOnly):: __rbdMixin({readOnly: readOnly}), // SecretRef is name of the authentication secret for RBDUser. If provided overrides keyring. Default is nil. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it secretRef:: { local __secretRefMixin(secretRef) = __rbdMixin({secretRef+: secretRef}), mixinInstance(secretRef):: __secretRefMixin(secretRef), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), }, secretRefType:: hidden.core.v1.localObjectReference, // The rados user name. Default is admin. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it user(user):: __rbdMixin({user: user}), }, rbdType:: hidden.core.v1.rbdVolumeSource, // ScaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes. scaleIo:: { local __scaleIoMixin(scaleIo) = {scaleIO+: scaleIo}, mixinInstance(scaleIo):: __scaleIoMixin(scaleIo), // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: __scaleIoMixin({fsType: fsType}), // The host address of the ScaleIO API Gateway. gateway(gateway):: __scaleIoMixin({gateway: gateway}), // The name of the Protection Domain for the configured storage (defaults to "default"). protectionDomain(protectionDomain):: __scaleIoMixin({protectionDomain: protectionDomain}), // Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: __scaleIoMixin({readOnly: readOnly}), // SecretRef references to the secret for ScaleIO user and other sensitive information. If this is not provided, Login operation will fail. secretRef:: { local __secretRefMixin(secretRef) = __scaleIoMixin({secretRef+: secretRef}), mixinInstance(secretRef):: __secretRefMixin(secretRef), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), }, secretRefType:: hidden.core.v1.localObjectReference, // Flag to enable/disable SSL communication with Gateway, default false sslEnabled(sslEnabled):: __scaleIoMixin({sslEnabled: sslEnabled}), // Indicates whether the storage for a volume should be thick or thin (defaults to "thin"). storageMode(storageMode):: __scaleIoMixin({storageMode: storageMode}), // The Storage Pool associated with the protection domain (defaults to "default"). storagePool(storagePool):: __scaleIoMixin({storagePool: storagePool}), // The name of the storage system as configured in ScaleIO. system(system):: __scaleIoMixin({system: system}), // The name of a volume already created in the ScaleIO system that is associated with this volume source. volumeName(volumeName):: __scaleIoMixin({volumeName: volumeName}), }, scaleIoType:: hidden.core.v1.scaleIoVolumeSource, // StorageOS represents a StorageOS volume that is attached to the kubelet's host machine and mounted into the pod More info: https://releases.k8s.io/HEAD/examples/volumes/storageos/README.md storageos:: { local __storageosMixin(storageos) = {storageos+: storageos}, mixinInstance(storageos):: __storageosMixin(storageos), // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: __storageosMixin({fsType: fsType}), // Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: __storageosMixin({readOnly: readOnly}), // SecretRef specifies the secret to use for obtaining the StorageOS API credentials. If not specified, default values will be attempted. secretRef:: { local __secretRefMixin(secretRef) = __storageosMixin({secretRef+: secretRef}), mixinInstance(secretRef):: __secretRefMixin(secretRef), // If referring to a piece of an object instead of an entire object, this string should contain a valid JSON/Go field access statement, such as desiredState.manifest.containers[2]. For example, if the object reference is to a container within a pod, this would take on a value like: "spec.containers{name}" (where "name" refers to the name of the container that triggered the event) or if no container name is specified "spec.containers[2]" (container with index 2 in this pod). This syntax is chosen only to have some well-defined way of referencing a part of an object. fieldPath(fieldPath):: __secretRefMixin({fieldPath: fieldPath}), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), // Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ namespace(namespace):: __secretRefMixin({namespace: namespace}), // Specific resourceVersion to which this reference is made, if any. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency resourceVersion(resourceVersion):: __secretRefMixin({resourceVersion: resourceVersion}), // UID of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids uid(uid):: __secretRefMixin({uid: uid}), }, secretRefType:: hidden.core.v1.objectReference, // VolumeName is the human-readable name of the StorageOS volume. Volume names are only unique within a namespace. volumeName(volumeName):: __storageosMixin({volumeName: volumeName}), // VolumeNamespace specifies the scope of the volume within StorageOS. If no namespace is specified then the Pod's namespace will be used. This allows the Kubernetes name scoping to be mirrored within StorageOS for tighter integration. Set VolumeName to any name to override the default behaviour. Set to "default" if you are not using namespaces within StorageOS. Namespaces that do not pre-exist within StorageOS will be created. volumeNamespace(volumeNamespace):: __storageosMixin({volumeNamespace: volumeNamespace}), }, storageosType:: hidden.core.v1.storageOSPersistentVolumeSource, // VsphereVolume represents a vSphere volume attached and mounted on kubelets host machine vsphereVolume:: { local __vsphereVolumeMixin(vsphereVolume) = {vsphereVolume+: vsphereVolume}, mixinInstance(vsphereVolume):: __vsphereVolumeMixin(vsphereVolume), // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: __vsphereVolumeMixin({fsType: fsType}), // Storage Policy Based Management (SPBM) profile ID associated with the StoragePolicyName. storagePolicyID(storagePolicyID):: __vsphereVolumeMixin({storagePolicyID: storagePolicyID}), // Storage Policy Based Management (SPBM) profile name. storagePolicyName(storagePolicyName):: __vsphereVolumeMixin({storagePolicyName: storagePolicyName}), // Path that identifies vSphere volume vmdk volumePath(volumePath):: __vsphereVolumeMixin({volumePath: volumePath}), }, vsphereVolumeType:: hidden.core.v1.vsphereVirtualDiskVolumeSource, }, }, // PersistentVolumeStatus is the current status of a persistent volume. persistentVolumeStatus:: { new():: {}, // A human-readable message indicating details about why the volume is in this state. message(message):: {message: message}, // Phase indicates if a volume is available, bound to a claim, or released by a claim. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#phase phase(phase):: {phase: phase}, // Reason is a brief CamelCase string that describes any failure and is meant for machine parsing and tidy display in the CLI. reason(reason):: {reason: reason}, mixin:: { }, }, // Represents a Photon Controller persistent disk resource. photonPersistentDiskVolumeSource:: { new():: {}, // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: {fsType: fsType}, // ID that identifies Photon Controller persistent disk pdId(pdId):: {pdID: pdId}, mixin:: { }, }, // Pod affinity is a group of inter pod affinity scheduling rules. podAffinity:: { new():: {}, // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then {preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution} else {preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}, preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then {requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution} else {requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, mixin:: { }, }, // Defines a set of pods (namely those matching the labelSelector relative to the given namespace(s)) that this pod should be co-located (affinity) or not co-located (anti-affinity) with, where co-located is defined as running on a node whose value of the label with key tches that of any node on which a pod of the set of pods is running podAffinityTerm:: { new():: {}, // namespaces specifies which namespaces the labelSelector applies to (matches against); null or empty list means "this pod's namespace" namespaces(namespaces):: if std.type(namespaces) == "array" then {namespaces+: namespaces} else {namespaces+: [namespaces]}, // This pod should be co-located (affinity) or not co-located (anti-affinity) with the pods matching the labelSelector in the specified namespaces, where co-located is defined as running on a node whose value of the label with key topologyKey matches that of any node on which any of the selected pods is running. For PreferredDuringScheduling pod anti-affinity, empty topologyKey is interpreted as "all topologies" ("all topologies" here means all the topologyKeys indicated by scheduler command-line argument --failure-domains); for affinity and for RequiredDuringScheduling pod anti-affinity, empty topologyKey is not allowed. topologyKey(topologyKey):: {topologyKey: topologyKey}, mixin:: { // A label query over a set of resources, in this case pods. labelSelector:: { local __labelSelectorMixin(labelSelector) = {labelSelector+: labelSelector}, mixinInstance(labelSelector):: __labelSelectorMixin(labelSelector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __labelSelectorMixin({matchExpressions+: matchExpressions}) else __labelSelectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __labelSelectorMixin({matchLabels+: matchLabels}), }, labelSelectorType:: hidden.meta.v1.labelSelector, }, }, // Pod anti affinity is a group of inter pod anti affinity scheduling rules. podAntiAffinity:: { new():: {}, // The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then {preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution} else {preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}, preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then {requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution} else {requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, mixin:: { }, }, // PodCondition contains details for the current condition of this pod. podCondition:: { new():: {}, // Human-readable message indicating details about last transition. message(message):: {message: message}, // Unique, one-word, CamelCase reason for the condition's last transition. reason(reason):: {reason: reason}, // Type is the type of the condition. Currently only Ready. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-conditions type(type):: {type: type}, mixin:: { // Last time we probed the condition. lastProbeTime:: { local __lastProbeTimeMixin(lastProbeTime) = {lastProbeTime+: lastProbeTime}, mixinInstance(lastProbeTime):: __lastProbeTimeMixin(lastProbeTime), }, lastProbeTimeType:: hidden.meta.v1.time, // Last time the condition transitioned from one status to another. lastTransitionTime:: { local __lastTransitionTimeMixin(lastTransitionTime) = {lastTransitionTime+: lastTransitionTime}, mixinInstance(lastTransitionTime):: __lastTransitionTimeMixin(lastTransitionTime), }, lastTransitionTimeType:: hidden.meta.v1.time, }, }, // PodSecurityContext holds pod-level security attributes and common container settings. Some fields are also present in container.securityContext. Field values of container.securityContext take precedence over field values of PodSecurityContext. podSecurityContext:: { new():: {}, // A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod: // // 1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw---- // // If unset, the Kubelet will not modify the ownership and permissions of any volume. fsGroup(fsGroup):: {fsGroup: fsGroup}, // Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsNonRoot(runAsNonRoot):: {runAsNonRoot: runAsNonRoot}, // The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. runAsUser(runAsUser):: {runAsUser: runAsUser}, // A list of groups applied to the first process run in each container, in addition to the container's primary GID. If unspecified, no groups will be added to any container. supplementalGroups(supplementalGroups):: if std.type(supplementalGroups) == "array" then {supplementalGroups+: supplementalGroups} else {supplementalGroups+: [supplementalGroups]}, mixin:: { // The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = {seLinuxOptions+: seLinuxOptions}, mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, }, }, // PodSpec is a description of a pod. podSpec:: { new():: {}, // Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer. activeDeadlineSeconds(activeDeadlineSeconds):: {activeDeadlineSeconds: activeDeadlineSeconds}, // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted. automountServiceAccountToken(automountServiceAccountToken):: {automountServiceAccountToken: automountServiceAccountToken}, // List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated. containers(containers):: if std.type(containers) == "array" then {containers+: containers} else {containers+: [containers]}, containersType:: hidden.core.v1.container, // Set DNS policy for containers within the pod. One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. Defaults to "ClusterFirst". To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. dnsPolicy(dnsPolicy):: {dnsPolicy: dnsPolicy}, // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts file if specified. This is only valid for non-hostNetwork pods. hostAliases(hostAliases):: if std.type(hostAliases) == "array" then {hostAliases+: hostAliases} else {hostAliases+: [hostAliases]}, hostAliasesType:: hidden.core.v1.hostAlias, // Use the host's ipc namespace. Optional: Default to false. hostIpc(hostIpc):: {hostIPC: hostIpc}, // Host networking requested for this pod. Use the host's network namespace. If this option is set, the ports that will be used must be specified. Default to false. hostNetwork(hostNetwork):: {hostNetwork: hostNetwork}, // Use the host's pid namespace. Optional: Default to false. hostPid(hostPid):: {hostPID: hostPid}, // Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value. hostname(hostname):: {hostname: hostname}, // 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. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod imagePullSecrets(imagePullSecrets):: if std.type(imagePullSecrets) == "array" then {imagePullSecrets+: imagePullSecrets} else {imagePullSecrets+: [imagePullSecrets]}, imagePullSecretsType:: hidden.core.v1.localObjectReference, // List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ initContainers(initContainers):: if std.type(initContainers) == "array" then {initContainers+: initContainers} else {initContainers+: [initContainers]}, initContainersType:: hidden.core.v1.container, // NodeName is a request to schedule this pod onto a specific node. If it is non-empty, the scheduler simply schedules this pod onto that node, assuming that it fits resource requirements. nodeName(nodeName):: {nodeName: nodeName}, // NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ nodeSelector(nodeSelector):: {nodeSelector+: nodeSelector}, // Restart policy for all containers within the pod. One of Always, OnFailure, Never. Default to Always. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy restartPolicy(restartPolicy):: {restartPolicy: restartPolicy}, // If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler. schedulerName(schedulerName):: {schedulerName: schedulerName}, // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead. serviceAccount(serviceAccount):: {serviceAccount: serviceAccount}, // ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ serviceAccountName(serviceAccountName):: {serviceAccountName: serviceAccountName}, // If specified, the fully qualified Pod hostname will be "...svc.". If not specified, the pod will not have a domainname at all. subdomain(subdomain):: {subdomain: subdomain}, // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds. terminationGracePeriodSeconds(terminationGracePeriodSeconds):: {terminationGracePeriodSeconds: terminationGracePeriodSeconds}, // If specified, the pod's tolerations. tolerations(tolerations):: if std.type(tolerations) == "array" then {tolerations+: tolerations} else {tolerations+: [tolerations]}, tolerationsType:: hidden.core.v1.toleration, // List of volumes that can be mounted by containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes volumes(volumes):: if std.type(volumes) == "array" then {volumes+: volumes} else {volumes+: [volumes]}, volumesType:: hidden.core.v1.volume, mixin:: { // If specified, the pod's scheduling constraints affinity:: { local __affinityMixin(affinity) = {affinity+: affinity}, mixinInstance(affinity):: __affinityMixin(affinity), // Describes node affinity scheduling rules for the pod. nodeAffinity:: { local __nodeAffinityMixin(nodeAffinity) = __affinityMixin({nodeAffinity+: nodeAffinity}), mixinInstance(nodeAffinity):: __nodeAffinityMixin(nodeAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.preferredSchedulingTerm, // If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node. requiredDuringSchedulingIgnoredDuringExecution:: { local __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution) = __nodeAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}), mixinInstance(requiredDuringSchedulingIgnoredDuringExecution):: __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution), // Required. A list of node selector terms. The terms are ORed. nodeSelectorTerms(nodeSelectorTerms):: if std.type(nodeSelectorTerms) == "array" then __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: nodeSelectorTerms}) else __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: [nodeSelectorTerms]}), nodeSelectorTermsType:: hidden.core.v1.nodeSelectorTerm, }, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.nodeSelector, }, nodeAffinityType:: hidden.core.v1.nodeAffinity, // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)). podAffinity:: { local __podAffinityMixin(podAffinity) = __affinityMixin({podAffinity+: podAffinity}), mixinInstance(podAffinity):: __podAffinityMixin(podAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAffinityType:: hidden.core.v1.podAffinity, // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)). podAntiAffinity:: { local __podAntiAffinityMixin(podAntiAffinity) = __affinityMixin({podAntiAffinity+: podAntiAffinity}), mixinInstance(podAntiAffinity):: __podAntiAffinityMixin(podAntiAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAntiAffinityType:: hidden.core.v1.podAntiAffinity, }, affinityType:: hidden.core.v1.affinity, // SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field. securityContext:: { local __securityContextMixin(securityContext) = {securityContext+: securityContext}, mixinInstance(securityContext):: __securityContextMixin(securityContext), // A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod: // // 1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw---- // // If unset, the Kubelet will not modify the ownership and permissions of any volume. fsGroup(fsGroup):: __securityContextMixin({fsGroup: fsGroup}), // Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsNonRoot(runAsNonRoot):: __securityContextMixin({runAsNonRoot: runAsNonRoot}), // The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. runAsUser(runAsUser):: __securityContextMixin({runAsUser: runAsUser}), // The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = __securityContextMixin({seLinuxOptions+: seLinuxOptions}), mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, // A list of groups applied to the first process run in each container, in addition to the container's primary GID. If unspecified, no groups will be added to any container. supplementalGroups(supplementalGroups):: if std.type(supplementalGroups) == "array" then __securityContextMixin({supplementalGroups+: supplementalGroups}) else __securityContextMixin({supplementalGroups+: [supplementalGroups]}), }, securityContextType:: hidden.core.v1.podSecurityContext, }, }, // PodStatus represents information about the status of a pod. Status may trail the actual state of a system. podStatus:: { new():: {}, // Current service state of pod. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-conditions conditions(conditions):: if std.type(conditions) == "array" then {conditions+: conditions} else {conditions+: [conditions]}, conditionsType:: hidden.core.v1.podCondition, // The list has one entry per container in the manifest. Each entry is currently the output of `docker inspect`. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-and-container-status containerStatuses(containerStatuses):: if std.type(containerStatuses) == "array" then {containerStatuses+: containerStatuses} else {containerStatuses+: [containerStatuses]}, containerStatusesType:: hidden.core.v1.containerStatus, // IP address of the host to which the pod is assigned. Empty if not yet scheduled. hostIp(hostIp):: {hostIP: hostIp}, // The list has one entry per init container in the manifest. The most recent successful init container will have ready = true, the most recently started container will have startTime set. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-and-container-status initContainerStatuses(initContainerStatuses):: if std.type(initContainerStatuses) == "array" then {initContainerStatuses+: initContainerStatuses} else {initContainerStatuses+: [initContainerStatuses]}, initContainerStatusesType:: hidden.core.v1.containerStatus, // A human readable message indicating details about why the pod is in this condition. message(message):: {message: message}, // Current condition of the pod. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-phase phase(phase):: {phase: phase}, // IP address allocated to the pod. Routable at least within the cluster. Empty if not yet allocated. podIp(podIp):: {podIP: podIp}, // The Quality of Service (QOS) classification assigned to the pod based on resource requirements See PodQOSClass type for available QOS classes More info: https://github.com/kubernetes/kubernetes/blob/master/docs/design/resource-qos.md qosClass(qosClass):: {qosClass: qosClass}, // A brief CamelCase message indicating details about why the pod is in this state. e.g. 'OutOfDisk' reason(reason):: {reason: reason}, mixin:: { // RFC 3339 date and time at which the object was acknowledged by the Kubelet. This is before the Kubelet pulled the container image(s) for the pod. startTime:: { local __startTimeMixin(startTime) = {startTime+: startTime}, mixinInstance(startTime):: __startTimeMixin(startTime), }, startTimeType:: hidden.meta.v1.time, }, }, // PodTemplateSpec describes the data a pod should have when created from a template podTemplateSpec:: { new():: {}, mixin:: { // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = {metadata+: metadata}, mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = {spec+: spec}, mixinInstance(spec):: __specMixin(spec), // Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer. activeDeadlineSeconds(activeDeadlineSeconds):: __specMixin({activeDeadlineSeconds: activeDeadlineSeconds}), // If specified, the pod's scheduling constraints affinity:: { local __affinityMixin(affinity) = __specMixin({affinity+: affinity}), mixinInstance(affinity):: __affinityMixin(affinity), // Describes node affinity scheduling rules for the pod. nodeAffinity:: { local __nodeAffinityMixin(nodeAffinity) = __affinityMixin({nodeAffinity+: nodeAffinity}), mixinInstance(nodeAffinity):: __nodeAffinityMixin(nodeAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.preferredSchedulingTerm, // If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node. requiredDuringSchedulingIgnoredDuringExecution:: { local __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution) = __nodeAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}), mixinInstance(requiredDuringSchedulingIgnoredDuringExecution):: __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution), // Required. A list of node selector terms. The terms are ORed. nodeSelectorTerms(nodeSelectorTerms):: if std.type(nodeSelectorTerms) == "array" then __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: nodeSelectorTerms}) else __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: [nodeSelectorTerms]}), nodeSelectorTermsType:: hidden.core.v1.nodeSelectorTerm, }, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.nodeSelector, }, nodeAffinityType:: hidden.core.v1.nodeAffinity, // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)). podAffinity:: { local __podAffinityMixin(podAffinity) = __affinityMixin({podAffinity+: podAffinity}), mixinInstance(podAffinity):: __podAffinityMixin(podAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAffinityType:: hidden.core.v1.podAffinity, // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)). podAntiAffinity:: { local __podAntiAffinityMixin(podAntiAffinity) = __affinityMixin({podAntiAffinity+: podAntiAffinity}), mixinInstance(podAntiAffinity):: __podAntiAffinityMixin(podAntiAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAntiAffinityType:: hidden.core.v1.podAntiAffinity, }, affinityType:: hidden.core.v1.affinity, // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted. automountServiceAccountToken(automountServiceAccountToken):: __specMixin({automountServiceAccountToken: automountServiceAccountToken}), // List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated. containers(containers):: if std.type(containers) == "array" then __specMixin({containers+: containers}) else __specMixin({containers+: [containers]}), containersType:: hidden.core.v1.container, // Set DNS policy for containers within the pod. One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. Defaults to "ClusterFirst". To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. dnsPolicy(dnsPolicy):: __specMixin({dnsPolicy: dnsPolicy}), // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts file if specified. This is only valid for non-hostNetwork pods. hostAliases(hostAliases):: if std.type(hostAliases) == "array" then __specMixin({hostAliases+: hostAliases}) else __specMixin({hostAliases+: [hostAliases]}), hostAliasesType:: hidden.core.v1.hostAlias, // Use the host's ipc namespace. Optional: Default to false. hostIpc(hostIpc):: __specMixin({hostIPC: hostIpc}), // Host networking requested for this pod. Use the host's network namespace. If this option is set, the ports that will be used must be specified. Default to false. hostNetwork(hostNetwork):: __specMixin({hostNetwork: hostNetwork}), // Use the host's pid namespace. Optional: Default to false. hostPid(hostPid):: __specMixin({hostPID: hostPid}), // Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value. hostname(hostname):: __specMixin({hostname: hostname}), // 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. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod imagePullSecrets(imagePullSecrets):: if std.type(imagePullSecrets) == "array" then __specMixin({imagePullSecrets+: imagePullSecrets}) else __specMixin({imagePullSecrets+: [imagePullSecrets]}), imagePullSecretsType:: hidden.core.v1.localObjectReference, // List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ initContainers(initContainers):: if std.type(initContainers) == "array" then __specMixin({initContainers+: initContainers}) else __specMixin({initContainers+: [initContainers]}), initContainersType:: hidden.core.v1.container, // NodeName is a request to schedule this pod onto a specific node. If it is non-empty, the scheduler simply schedules this pod onto that node, assuming that it fits resource requirements. nodeName(nodeName):: __specMixin({nodeName: nodeName}), // NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ nodeSelector(nodeSelector):: __specMixin({nodeSelector+: nodeSelector}), // Restart policy for all containers within the pod. One of Always, OnFailure, Never. Default to Always. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy restartPolicy(restartPolicy):: __specMixin({restartPolicy: restartPolicy}), // If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler. schedulerName(schedulerName):: __specMixin({schedulerName: schedulerName}), // SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field. securityContext:: { local __securityContextMixin(securityContext) = __specMixin({securityContext+: securityContext}), mixinInstance(securityContext):: __securityContextMixin(securityContext), // A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod: // // 1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw---- // // If unset, the Kubelet will not modify the ownership and permissions of any volume. fsGroup(fsGroup):: __securityContextMixin({fsGroup: fsGroup}), // Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsNonRoot(runAsNonRoot):: __securityContextMixin({runAsNonRoot: runAsNonRoot}), // The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. runAsUser(runAsUser):: __securityContextMixin({runAsUser: runAsUser}), // The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = __securityContextMixin({seLinuxOptions+: seLinuxOptions}), mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, // A list of groups applied to the first process run in each container, in addition to the container's primary GID. If unspecified, no groups will be added to any container. supplementalGroups(supplementalGroups):: if std.type(supplementalGroups) == "array" then __securityContextMixin({supplementalGroups+: supplementalGroups}) else __securityContextMixin({supplementalGroups+: [supplementalGroups]}), }, securityContextType:: hidden.core.v1.podSecurityContext, // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead. serviceAccount(serviceAccount):: __specMixin({serviceAccount: serviceAccount}), // ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ serviceAccountName(serviceAccountName):: __specMixin({serviceAccountName: serviceAccountName}), // If specified, the fully qualified Pod hostname will be "...svc.". If not specified, the pod will not have a domainname at all. subdomain(subdomain):: __specMixin({subdomain: subdomain}), // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds. terminationGracePeriodSeconds(terminationGracePeriodSeconds):: __specMixin({terminationGracePeriodSeconds: terminationGracePeriodSeconds}), // If specified, the pod's tolerations. tolerations(tolerations):: if std.type(tolerations) == "array" then __specMixin({tolerations+: tolerations}) else __specMixin({tolerations+: [tolerations]}), tolerationsType:: hidden.core.v1.toleration, // List of volumes that can be mounted by containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes volumes(volumes):: if std.type(volumes) == "array" then __specMixin({volumes+: volumes}) else __specMixin({volumes+: [volumes]}), volumesType:: hidden.core.v1.volume, }, specType:: hidden.core.v1.podSpec, }, }, // PortworxVolumeSource represents a Portworx volume resource. portworxVolumeSource:: { new():: {}, // FSType represents the filesystem type to mount Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: {fsType: fsType}, // Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: {readOnly: readOnly}, // VolumeID uniquely identifies a Portworx volume volumeId(volumeId):: {volumeID: volumeId}, mixin:: { }, }, // An empty preferred scheduling term matches all objects with implicit weight 0 (i.e. it's a no-op). A null preferred scheduling term matches no objects (i.e. is also a no-op). preferredSchedulingTerm:: { new():: {}, // Weight associated with matching the corresponding nodeSelectorTerm, in the range 1-100. weight(weight):: {weight: weight}, mixin:: { // A node selector term, associated with the corresponding weight. preference:: { local __preferenceMixin(preference) = {preference+: preference}, mixinInstance(preference):: __preferenceMixin(preference), // Required. A list of node selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __preferenceMixin({matchExpressions+: matchExpressions}) else __preferenceMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.core.v1.nodeSelectorRequirement, }, preferenceType:: hidden.core.v1.nodeSelectorTerm, }, }, // Probe describes a health check to be performed against a container to determine whether it is alive or ready to receive traffic. probe:: { new():: {}, // Minimum consecutive failures for the probe to be considered failed after having succeeded. Defaults to 3. Minimum value is 1. failureThreshold(failureThreshold):: {failureThreshold: failureThreshold}, // Number of seconds after the container has started before liveness probes are initiated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes initialDelaySeconds(initialDelaySeconds):: {initialDelaySeconds: initialDelaySeconds}, // How often (in seconds) to perform the probe. Default to 10 seconds. Minimum value is 1. periodSeconds(periodSeconds):: {periodSeconds: periodSeconds}, // Minimum consecutive successes for the probe to be considered successful after having failed. Defaults to 1. Must be 1 for liveness. Minimum value is 1. successThreshold(successThreshold):: {successThreshold: successThreshold}, // Number of seconds after which the probe times out. Defaults to 1 second. Minimum value is 1. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes timeoutSeconds(timeoutSeconds):: {timeoutSeconds: timeoutSeconds}, mixin:: { // One and only one of the following should be specified. Exec specifies the action to take. exec:: { local __execMixin(exec) = {exec+: exec}, mixinInstance(exec):: __execMixin(exec), // Command is the command line to execute inside the container, the working directory for the command is root ('/') in the container's filesystem. The command is simply exec'd, it is not run inside a shell, so traditional shell instructions ('|', etc) won't work. To use a shell, you need to explicitly call out to that shell. Exit status of 0 is treated as live/healthy and non-zero is unhealthy. command(command):: if std.type(command) == "array" then __execMixin({command+: command}) else __execMixin({command+: [command]}), }, execType:: hidden.core.v1.execAction, // HTTPGet specifies the http request to perform. httpGet:: { local __httpGetMixin(httpGet) = {httpGet+: httpGet}, mixinInstance(httpGet):: __httpGetMixin(httpGet), // Host name to connect to, defaults to the pod IP. You probably want to set "Host" in httpHeaders instead. host(host):: __httpGetMixin({host: host}), // Custom headers to set in the request. HTTP allows repeated headers. httpHeaders(httpHeaders):: if std.type(httpHeaders) == "array" then __httpGetMixin({httpHeaders+: httpHeaders}) else __httpGetMixin({httpHeaders+: [httpHeaders]}), httpHeadersType:: hidden.core.v1.httpHeader, // Path to access on the HTTP server. path(path):: __httpGetMixin({path: path}), // Name or number of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. port(port):: __httpGetMixin({port: port}), // Scheme to use for connecting to the host. Defaults to HTTP. scheme(scheme):: __httpGetMixin({scheme: scheme}), }, httpGetType:: hidden.core.v1.httpGetAction, // TCPSocket specifies an action involving a TCP port. TCP hooks not yet supported tcpSocket:: { local __tcpSocketMixin(tcpSocket) = {tcpSocket+: tcpSocket}, mixinInstance(tcpSocket):: __tcpSocketMixin(tcpSocket), // Optional: Host name to connect to, defaults to the pod IP. host(host):: __tcpSocketMixin({host: host}), // Number or name of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. port(port):: __tcpSocketMixin({port: port}), }, tcpSocketType:: hidden.core.v1.tcpSocketAction, }, }, // Represents a projected volume source projectedVolumeSource:: { new():: {}, // Mode bits to use on created files by default. Must be a value between 0 and 0777. Directories within the path are not affected by this setting. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set. defaultMode(defaultMode):: {defaultMode: defaultMode}, // list of volume projections sources(sources):: if std.type(sources) == "array" then {sources+: sources} else {sources+: [sources]}, sourcesType:: hidden.core.v1.volumeProjection, mixin:: { }, }, // Represents a Quobyte mount that lasts the lifetime of a pod. Quobyte volumes do not support ownership management or SELinux relabeling. quobyteVolumeSource:: { new():: {}, // Group to map volume access to Default is no group group(group):: {group: group}, // ReadOnly here will force the Quobyte volume to be mounted with read-only permissions. Defaults to false. readOnly(readOnly):: {readOnly: readOnly}, // Registry represents a single or multiple Quobyte Registry services specified as a string as host:port pair (multiple entries are separated with commas) which acts as the central registry for volumes registry(registry):: {registry: registry}, // User to map volume access to Defaults to serivceaccount user user(user):: {user: user}, // Volume is a string that references an already created Quobyte volume by name. volume(volume):: {volume: volume}, mixin:: { }, }, // Represents a Rados Block Device mount that lasts the lifetime of a pod. RBD volumes support ownership management and SELinux relabeling. rbdVolumeSource:: { new():: {}, // Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#rbd fsType(fsType):: {fsType: fsType}, // The rados image name. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it image(image):: {image: image}, // Keyring is the path to key ring for RBDUser. Default is /etc/ceph/keyring. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it keyring(keyring):: {keyring: keyring}, // A collection of Ceph monitors. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it monitors(monitors):: if std.type(monitors) == "array" then {monitors+: monitors} else {monitors+: [monitors]}, // The rados pool name. Default is rbd. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it pool(pool):: {pool: pool}, // ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it readOnly(readOnly):: {readOnly: readOnly}, // The rados user name. Default is admin. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it user(user):: {user: user}, mixin:: { // SecretRef is name of the authentication secret for RBDUser. If provided overrides keyring. Default is nil. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it secretRef:: { local __secretRefMixin(secretRef) = {secretRef+: secretRef}, mixinInstance(secretRef):: __secretRefMixin(secretRef), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), }, secretRefType:: hidden.core.v1.localObjectReference, }, }, // ReplicationControllerCondition describes the state of a replication controller at a certain point. replicationControllerCondition:: { new():: {}, // A human readable message indicating details about the transition. message(message):: {message: message}, // The reason for the condition's last transition. reason(reason):: {reason: reason}, // Type of replication controller condition. type(type):: {type: type}, mixin:: { // The last time the condition transitioned from one status to another. lastTransitionTime:: { local __lastTransitionTimeMixin(lastTransitionTime) = {lastTransitionTime+: lastTransitionTime}, mixinInstance(lastTransitionTime):: __lastTransitionTimeMixin(lastTransitionTime), }, lastTransitionTimeType:: hidden.meta.v1.time, }, }, // ReplicationControllerSpec is the specification of a replication controller. replicationControllerSpec:: { new():: {}, // Minimum number of seconds for which a newly created pod should be ready without any of its container crashing, for it to be considered available. Defaults to 0 (pod will be considered available as soon as it is ready) minReadySeconds(minReadySeconds):: {minReadySeconds: minReadySeconds}, // Replicas is the number of desired replicas. This is a pointer to distinguish between explicit zero and unspecified. Defaults to 1. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#what-is-a-replicationcontroller replicas(replicas):: {replicas: replicas}, // Selector is a label query over pods that should match the Replicas count. If Selector is empty, it is defaulted to the labels present on the Pod template. Label keys and values that must match in order to be controlled by this replication controller, if empty defaulted to labels on Pod template. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors selector(selector):: {selector+: selector}, mixin:: { // Template is the object that describes the pod that will be created if insufficient replicas are detected. This takes precedence over a TemplateRef. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#pod-template template:: { local __templateMixin(template) = {template+: template}, mixinInstance(template):: __templateMixin(template), // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = __templateMixin({metadata+: metadata}), mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = __templateMixin({spec+: spec}), mixinInstance(spec):: __specMixin(spec), // Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer. activeDeadlineSeconds(activeDeadlineSeconds):: __specMixin({activeDeadlineSeconds: activeDeadlineSeconds}), // If specified, the pod's scheduling constraints affinity:: { local __affinityMixin(affinity) = __specMixin({affinity+: affinity}), mixinInstance(affinity):: __affinityMixin(affinity), // Describes node affinity scheduling rules for the pod. nodeAffinity:: { local __nodeAffinityMixin(nodeAffinity) = __affinityMixin({nodeAffinity+: nodeAffinity}), mixinInstance(nodeAffinity):: __nodeAffinityMixin(nodeAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.preferredSchedulingTerm, // If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node. requiredDuringSchedulingIgnoredDuringExecution:: { local __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution) = __nodeAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}), mixinInstance(requiredDuringSchedulingIgnoredDuringExecution):: __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution), // Required. A list of node selector terms. The terms are ORed. nodeSelectorTerms(nodeSelectorTerms):: if std.type(nodeSelectorTerms) == "array" then __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: nodeSelectorTerms}) else __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: [nodeSelectorTerms]}), nodeSelectorTermsType:: hidden.core.v1.nodeSelectorTerm, }, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.nodeSelector, }, nodeAffinityType:: hidden.core.v1.nodeAffinity, // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)). podAffinity:: { local __podAffinityMixin(podAffinity) = __affinityMixin({podAffinity+: podAffinity}), mixinInstance(podAffinity):: __podAffinityMixin(podAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAffinityType:: hidden.core.v1.podAffinity, // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)). podAntiAffinity:: { local __podAntiAffinityMixin(podAntiAffinity) = __affinityMixin({podAntiAffinity+: podAntiAffinity}), mixinInstance(podAntiAffinity):: __podAntiAffinityMixin(podAntiAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAntiAffinityType:: hidden.core.v1.podAntiAffinity, }, affinityType:: hidden.core.v1.affinity, // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted. automountServiceAccountToken(automountServiceAccountToken):: __specMixin({automountServiceAccountToken: automountServiceAccountToken}), // List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated. containers(containers):: if std.type(containers) == "array" then __specMixin({containers+: containers}) else __specMixin({containers+: [containers]}), containersType:: hidden.core.v1.container, // Set DNS policy for containers within the pod. One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. Defaults to "ClusterFirst". To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. dnsPolicy(dnsPolicy):: __specMixin({dnsPolicy: dnsPolicy}), // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts file if specified. This is only valid for non-hostNetwork pods. hostAliases(hostAliases):: if std.type(hostAliases) == "array" then __specMixin({hostAliases+: hostAliases}) else __specMixin({hostAliases+: [hostAliases]}), hostAliasesType:: hidden.core.v1.hostAlias, // Use the host's ipc namespace. Optional: Default to false. hostIpc(hostIpc):: __specMixin({hostIPC: hostIpc}), // Host networking requested for this pod. Use the host's network namespace. If this option is set, the ports that will be used must be specified. Default to false. hostNetwork(hostNetwork):: __specMixin({hostNetwork: hostNetwork}), // Use the host's pid namespace. Optional: Default to false. hostPid(hostPid):: __specMixin({hostPID: hostPid}), // Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value. hostname(hostname):: __specMixin({hostname: hostname}), // 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. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod imagePullSecrets(imagePullSecrets):: if std.type(imagePullSecrets) == "array" then __specMixin({imagePullSecrets+: imagePullSecrets}) else __specMixin({imagePullSecrets+: [imagePullSecrets]}), imagePullSecretsType:: hidden.core.v1.localObjectReference, // List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ initContainers(initContainers):: if std.type(initContainers) == "array" then __specMixin({initContainers+: initContainers}) else __specMixin({initContainers+: [initContainers]}), initContainersType:: hidden.core.v1.container, // NodeName is a request to schedule this pod onto a specific node. If it is non-empty, the scheduler simply schedules this pod onto that node, assuming that it fits resource requirements. nodeName(nodeName):: __specMixin({nodeName: nodeName}), // NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ nodeSelector(nodeSelector):: __specMixin({nodeSelector+: nodeSelector}), // Restart policy for all containers within the pod. One of Always, OnFailure, Never. Default to Always. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy restartPolicy(restartPolicy):: __specMixin({restartPolicy: restartPolicy}), // If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler. schedulerName(schedulerName):: __specMixin({schedulerName: schedulerName}), // SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field. securityContext:: { local __securityContextMixin(securityContext) = __specMixin({securityContext+: securityContext}), mixinInstance(securityContext):: __securityContextMixin(securityContext), // A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod: // // 1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw---- // // If unset, the Kubelet will not modify the ownership and permissions of any volume. fsGroup(fsGroup):: __securityContextMixin({fsGroup: fsGroup}), // Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsNonRoot(runAsNonRoot):: __securityContextMixin({runAsNonRoot: runAsNonRoot}), // The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. runAsUser(runAsUser):: __securityContextMixin({runAsUser: runAsUser}), // The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = __securityContextMixin({seLinuxOptions+: seLinuxOptions}), mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, // A list of groups applied to the first process run in each container, in addition to the container's primary GID. If unspecified, no groups will be added to any container. supplementalGroups(supplementalGroups):: if std.type(supplementalGroups) == "array" then __securityContextMixin({supplementalGroups+: supplementalGroups}) else __securityContextMixin({supplementalGroups+: [supplementalGroups]}), }, securityContextType:: hidden.core.v1.podSecurityContext, // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead. serviceAccount(serviceAccount):: __specMixin({serviceAccount: serviceAccount}), // ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ serviceAccountName(serviceAccountName):: __specMixin({serviceAccountName: serviceAccountName}), // If specified, the fully qualified Pod hostname will be "...svc.". If not specified, the pod will not have a domainname at all. subdomain(subdomain):: __specMixin({subdomain: subdomain}), // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds. terminationGracePeriodSeconds(terminationGracePeriodSeconds):: __specMixin({terminationGracePeriodSeconds: terminationGracePeriodSeconds}), // If specified, the pod's tolerations. tolerations(tolerations):: if std.type(tolerations) == "array" then __specMixin({tolerations+: tolerations}) else __specMixin({tolerations+: [tolerations]}), tolerationsType:: hidden.core.v1.toleration, // List of volumes that can be mounted by containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes volumes(volumes):: if std.type(volumes) == "array" then __specMixin({volumes+: volumes}) else __specMixin({volumes+: [volumes]}), volumesType:: hidden.core.v1.volume, }, specType:: hidden.core.v1.podSpec, }, templateType:: hidden.core.v1.podTemplateSpec, }, }, // ReplicationControllerStatus represents the current status of a replication controller. replicationControllerStatus:: { new():: {}, // The number of available replicas (ready for at least minReadySeconds) for this replication controller. availableReplicas(availableReplicas):: {availableReplicas: availableReplicas}, // Represents the latest available observations of a replication controller's current state. conditions(conditions):: if std.type(conditions) == "array" then {conditions+: conditions} else {conditions+: [conditions]}, conditionsType:: hidden.core.v1.replicationControllerCondition, // The number of pods that have labels matching the labels of the pod template of the replication controller. fullyLabeledReplicas(fullyLabeledReplicas):: {fullyLabeledReplicas: fullyLabeledReplicas}, // ObservedGeneration reflects the generation of the most recently observed replication controller. observedGeneration(observedGeneration):: {observedGeneration: observedGeneration}, // The number of ready replicas for this replication controller. readyReplicas(readyReplicas):: {readyReplicas: readyReplicas}, // Replicas is the most recently oberved number of replicas. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#what-is-a-replicationcontroller replicas(replicas):: {replicas: replicas}, mixin:: { }, }, // ResourceFieldSelector represents container resources (cpu, memory) and their output format resourceFieldSelector:: { new():: {}, // Container name: required for volumes, optional for env vars containerName(containerName):: {containerName: containerName}, // Required: resource to select resource(resource):: {resource: resource}, mixin:: { // Specifies the output format of the exposed resources, defaults to "1" divisor:: { local __divisorMixin(divisor) = {divisor+: divisor}, mixinInstance(divisor):: __divisorMixin(divisor), }, divisorType:: hidden.core.resource.quantity, }, }, // ResourceQuotaSpec defines the desired hard limits to enforce for Quota. resourceQuotaSpec:: { new():: {}, // Hard is the set of desired hard limits for each named resource. More info: https://git.k8s.io/community/contributors/design-proposals/admission_control_resource_quota.md hard(hard):: {hard+: hard}, // A collection of filters that must match each object tracked by a quota. If not specified, the quota matches all objects. scopes(scopes):: if std.type(scopes) == "array" then {scopes+: scopes} else {scopes+: [scopes]}, mixin:: { }, }, // ResourceQuotaStatus defines the enforced hard limits and observed use. resourceQuotaStatus:: { new():: {}, // Hard is the set of enforced hard limits for each named resource. More info: https://git.k8s.io/community/contributors/design-proposals/admission_control_resource_quota.md hard(hard):: {hard+: hard}, // Used is the current observed total usage of the resource in the namespace. used(used):: {used+: used}, mixin:: { }, }, // ResourceRequirements describes the compute resource requirements. resourceRequirements:: { new():: {}, // Limits describes the maximum amount of compute resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ limits(limits):: {limits+: limits}, // Requests describes the minimum amount of compute resources required. If Requests is omitted for a container, it defaults to Limits if that is explicitly specified, otherwise to an implementation-defined value. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ requests(requests):: {requests+: requests}, mixin:: { }, }, // SELinuxOptions are the labels to be applied to the container seLinuxOptions:: { new():: {}, // Level is SELinux level label that applies to the container. level(level):: {level: level}, // Role is a SELinux role label that applies to the container. role(role):: {role: role}, // Type is a SELinux type label that applies to the container. type(type):: {type: type}, // User is a SELinux user label that applies to the container. user(user):: {user: user}, mixin:: { }, }, // ScaleIOVolumeSource represents a persistent ScaleIO volume scaleIoVolumeSource:: { new():: {}, // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: {fsType: fsType}, // The host address of the ScaleIO API Gateway. gateway(gateway):: {gateway: gateway}, // The name of the Protection Domain for the configured storage (defaults to "default"). protectionDomain(protectionDomain):: {protectionDomain: protectionDomain}, // Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: {readOnly: readOnly}, // Flag to enable/disable SSL communication with Gateway, default false sslEnabled(sslEnabled):: {sslEnabled: sslEnabled}, // Indicates whether the storage for a volume should be thick or thin (defaults to "thin"). storageMode(storageMode):: {storageMode: storageMode}, // The Storage Pool associated with the protection domain (defaults to "default"). storagePool(storagePool):: {storagePool: storagePool}, // The name of the storage system as configured in ScaleIO. system(system):: {system: system}, // The name of a volume already created in the ScaleIO system that is associated with this volume source. volumeName(volumeName):: {volumeName: volumeName}, mixin:: { // SecretRef references to the secret for ScaleIO user and other sensitive information. If this is not provided, Login operation will fail. secretRef:: { local __secretRefMixin(secretRef) = {secretRef+: secretRef}, mixinInstance(secretRef):: __secretRefMixin(secretRef), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), }, secretRefType:: hidden.core.v1.localObjectReference, }, }, // SecretEnvSource selects a Secret to populate the environment variables with. // // The contents of the target Secret's Data field will represent the key-value pairs as environment variables. secretEnvSource:: { new():: {}, // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: {name: name}, // Specify whether the Secret must be defined optional(optional):: {optional: optional}, mixin:: { }, }, // SecretKeySelector selects a key of a Secret. secretKeySelector:: { new():: {}, // The key of the secret to select from. Must be a valid secret key. key(key):: {key: key}, // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: {name: name}, // Specify whether the Secret or it's key must be defined optional(optional):: {optional: optional}, mixin:: { }, }, // Adapts a secret into a projected volume. // // The contents of the target Secret's Data field will be presented in a projected volume as files using the keys in the Data field as the file names. Note that this is identical to a secret volume source without the default mode. secretProjection:: { new():: {}, // If unspecified, each key-value pair in the Data field of the referenced Secret will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the Secret, the volume setup will error unless it is marked optional. Paths must be relative and may not contain the '..' path or start with '..'. items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.core.v1.keyToPath, // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: {name: name}, // Specify whether the Secret or its key must be defined optional(optional):: {optional: optional}, mixin:: { }, }, // Adapts a Secret into a volume. // // The contents of the target Secret's Data field will be presented in a volume as files using the keys in the Data field as the file names. Secret volumes support ownership management and SELinux relabeling. secretVolumeSource:: { new():: {}, // Optional: mode bits to use on created files by default. Must be a value between 0 and 0777. Defaults to 0644. Directories within the path are not affected by this setting. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set. defaultMode(defaultMode):: {defaultMode: defaultMode}, // If unspecified, each key-value pair in the Data field of the referenced Secret will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the Secret, the volume setup will error unless it is marked optional. Paths must be relative and may not contain the '..' path or start with '..'. items(items):: if std.type(items) == "array" then {items+: items} else {items+: [items]}, itemsType:: hidden.core.v1.keyToPath, // Specify whether the Secret or it's keys must be defined optional(optional):: {optional: optional}, // Name of the secret in the pod's namespace to use. More info: https://kubernetes.io/docs/concepts/storage/volumes#secret secretName(secretName):: {secretName: secretName}, mixin:: { }, }, // SecurityContext holds security configuration that will be applied to a container. Some fields are present in both SecurityContext and PodSecurityContext. When both are set, the values in SecurityContext take precedence. securityContext:: { new():: {}, // Run container in privileged mode. Processes in privileged containers are essentially equivalent to root on the host. Defaults to false. privileged(privileged):: {privileged: privileged}, // Whether this container has a read-only root filesystem. Default is false. readOnlyRootFilesystem(readOnlyRootFilesystem):: {readOnlyRootFilesystem: readOnlyRootFilesystem}, // Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsNonRoot(runAsNonRoot):: {runAsNonRoot: runAsNonRoot}, // The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsUser(runAsUser):: {runAsUser: runAsUser}, mixin:: { // The capabilities to add/drop when running containers. Defaults to the default set of capabilities granted by the container runtime. capabilities:: { local __capabilitiesMixin(capabilities) = {capabilities+: capabilities}, mixinInstance(capabilities):: __capabilitiesMixin(capabilities), // Added capabilities add(add):: if std.type(add) == "array" then __capabilitiesMixin({add+: add}) else __capabilitiesMixin({add+: [add]}), // Removed capabilities drop(drop):: if std.type(drop) == "array" then __capabilitiesMixin({drop+: drop}) else __capabilitiesMixin({drop+: [drop]}), }, capabilitiesType:: hidden.core.v1.capabilities, // The SELinux context to be applied to the container. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = {seLinuxOptions+: seLinuxOptions}, mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, }, }, // ServicePort contains information on service's port. servicePort:: { new(port, targetPort):: {} + self.port(port) + self.targetPort(targetPort), newNamed(name, port, targetPort):: {} + self.name(name) + self.port(port) + self.targetPort(targetPort), // The name of this port within the service. This must be a DNS_LABEL. All ports within a ServiceSpec must have unique names. This maps to the 'Name' field in EndpointPort objects. Optional if only one ServicePort is defined on this service. name(name):: {name: name}, // The port on each node on which this service is exposed when type=NodePort or LoadBalancer. Usually assigned by the system. If specified, it will be allocated to the service if unused or else creation of the service will fail. Default is to auto-allocate a port if the ServiceType of this Service requires one. More info: https://kubernetes.io/docs/concepts/services-networking/service/#type-nodeport nodePort(nodePort):: {nodePort: nodePort}, // The port that will be exposed by this service. port(port):: {port: port}, // The IP protocol for this port. Supports "TCP" and "UDP". Default is TCP. protocol(protocol):: {protocol: protocol}, // Number or name of the port to access on the pods targeted by the service. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. If this is a string, it will be looked up as a named port in the target Pod's container ports. If this is not specified, the value of the 'port' field is used (an identity map). This field is ignored for services with clusterIP=None, and should be omitted or set equal to the 'port' field. More info: https://kubernetes.io/docs/concepts/services-networking/service/#defining-a-service targetPort(targetPort):: {targetPort: targetPort}, mixin:: { }, }, // ServiceSpec describes the attributes that a user creates on a service. serviceSpec:: { new():: {}, // clusterIP is the IP address of the service and is usually assigned randomly by the master. If an address is specified manually and is not in use by others, it will be allocated to the service; otherwise, creation of the service will fail. This field can not be changed through updates. Valid values are "None", empty string (""), or a valid IP address. "None" can be specified for headless services when proxying is not required. Only applies to types ClusterIP, NodePort, and LoadBalancer. Ignored if type is ExternalName. More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies clusterIp(clusterIp):: {clusterIP: clusterIp}, // externalIPs is a list of IP addresses for which nodes in the cluster will also accept traffic for this service. These IPs are not managed by Kubernetes. The user is responsible for ensuring that traffic arrives at a node with this IP. A common example is external load-balancers that are not part of the Kubernetes system. externalIps(externalIps):: if std.type(externalIps) == "array" then {externalIPs+: externalIps} else {externalIPs+: [externalIps]}, // externalName is the external reference that kubedns or equivalent will return as a CNAME record for this service. No proxying will be involved. Must be a valid DNS name and requires Type to be ExternalName. externalName(externalName):: {externalName: externalName}, // externalTrafficPolicy denotes if this Service desires to route external traffic to node-local or cluster-wide endpoints. "Local" preserves the client source IP and avoids a second hop for LoadBalancer and Nodeport type services, but risks potentially imbalanced traffic spreading. "Cluster" obscures the client source IP and may cause a second hop to another node, but should have good overall load-spreading. externalTrafficPolicy(externalTrafficPolicy):: {externalTrafficPolicy: externalTrafficPolicy}, // healthCheckNodePort specifies the healthcheck nodePort for the service. If not specified, HealthCheckNodePort is created by the service api backend with the allocated nodePort. Will use user-specified nodePort value if specified by the client. Only effects when Type is set to LoadBalancer and ExternalTrafficPolicy is set to Local. healthCheckNodePort(healthCheckNodePort):: {healthCheckNodePort: healthCheckNodePort}, // Only applies to Service Type: LoadBalancer LoadBalancer will get created with the IP specified in this field. This feature depends on whether the underlying cloud-provider supports specifying the loadBalancerIP when a load balancer is created. This field will be ignored if the cloud-provider does not support the feature. loadBalancerIp(loadBalancerIp):: {loadBalancerIP: loadBalancerIp}, // If specified and supported by the platform, this will restrict traffic through the cloud-provider load-balancer will be restricted to the specified client IPs. This field will be ignored if the cloud-provider does not support the feature." More info: https://kubernetes.io/docs/tasks/access-application-cluster/configure-cloud-provider-firewall/ loadBalancerSourceRanges(loadBalancerSourceRanges):: if std.type(loadBalancerSourceRanges) == "array" then {loadBalancerSourceRanges+: loadBalancerSourceRanges} else {loadBalancerSourceRanges+: [loadBalancerSourceRanges]}, // The list of ports that are exposed by this service. More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies ports(ports):: if std.type(ports) == "array" then {ports+: ports} else {ports+: [ports]}, portsType:: hidden.core.v1.servicePort, // Route service traffic to pods with label keys and values matching this selector. If empty or not present, the service is assumed to have an external process managing its endpoints, which Kubernetes will not modify. Only applies to types ClusterIP, NodePort, and LoadBalancer. Ignored if type is ExternalName. More info: https://kubernetes.io/docs/concepts/services-networking/service/ selector(selector):: {selector+: selector}, // Supports "ClientIP" and "None". Used to maintain session affinity. Enable client IP based session affinity. Must be ClientIP or None. Defaults to None. More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies sessionAffinity(sessionAffinity):: {sessionAffinity: sessionAffinity}, // type determines how the Service is exposed. Defaults to ClusterIP. Valid options are ExternalName, ClusterIP, NodePort, and LoadBalancer. "ExternalName" maps to the specified externalName. "ClusterIP" allocates a cluster-internal IP address for load-balancing to endpoints. Endpoints are determined by the selector or if that is not specified, by manual construction of an Endpoints object. If clusterIP is "None", no virtual IP is allocated and the endpoints are published as a set of endpoints rather than a stable IP. "NodePort" builds on ClusterIP and allocates a port on every node which routes to the clusterIP. "LoadBalancer" builds on NodePort and creates an external load-balancer (if supported in the current cloud) which routes to the clusterIP. More info: https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services---service-types type(type):: {type: type}, mixin:: { }, }, // ServiceStatus represents the current status of a service. serviceStatus:: { new():: {}, mixin:: { // LoadBalancer contains the current status of the load-balancer, if one is present. loadBalancer:: { local __loadBalancerMixin(loadBalancer) = {loadBalancer+: loadBalancer}, mixinInstance(loadBalancer):: __loadBalancerMixin(loadBalancer), // Ingress is a list containing ingress points for the load-balancer. Traffic intended for the service should be sent to these ingress points. ingress(ingress):: if std.type(ingress) == "array" then __loadBalancerMixin({ingress+: ingress}) else __loadBalancerMixin({ingress+: [ingress]}), ingressType:: hidden.core.v1.loadBalancerIngress, }, loadBalancerType:: hidden.core.v1.loadBalancerStatus, }, }, // Represents a StorageOS persistent volume resource. storageOSPersistentVolumeSource:: { new():: {}, // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: {fsType: fsType}, // Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: {readOnly: readOnly}, // VolumeName is the human-readable name of the StorageOS volume. Volume names are only unique within a namespace. volumeName(volumeName):: {volumeName: volumeName}, // VolumeNamespace specifies the scope of the volume within StorageOS. If no namespace is specified then the Pod's namespace will be used. This allows the Kubernetes name scoping to be mirrored within StorageOS for tighter integration. Set VolumeName to any name to override the default behaviour. Set to "default" if you are not using namespaces within StorageOS. Namespaces that do not pre-exist within StorageOS will be created. volumeNamespace(volumeNamespace):: {volumeNamespace: volumeNamespace}, mixin:: { // SecretRef specifies the secret to use for obtaining the StorageOS API credentials. If not specified, default values will be attempted. secretRef:: { local __secretRefMixin(secretRef) = {secretRef+: secretRef}, mixinInstance(secretRef):: __secretRefMixin(secretRef), // If referring to a piece of an object instead of an entire object, this string should contain a valid JSON/Go field access statement, such as desiredState.manifest.containers[2]. For example, if the object reference is to a container within a pod, this would take on a value like: "spec.containers{name}" (where "name" refers to the name of the container that triggered the event) or if no container name is specified "spec.containers[2]" (container with index 2 in this pod). This syntax is chosen only to have some well-defined way of referencing a part of an object. fieldPath(fieldPath):: __secretRefMixin({fieldPath: fieldPath}), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), // Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ namespace(namespace):: __secretRefMixin({namespace: namespace}), // Specific resourceVersion to which this reference is made, if any. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency resourceVersion(resourceVersion):: __secretRefMixin({resourceVersion: resourceVersion}), // UID of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids uid(uid):: __secretRefMixin({uid: uid}), }, secretRefType:: hidden.core.v1.objectReference, }, }, // Represents a StorageOS persistent volume resource. storageOSVolumeSource:: { new():: {}, // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: {fsType: fsType}, // Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: {readOnly: readOnly}, // VolumeName is the human-readable name of the StorageOS volume. Volume names are only unique within a namespace. volumeName(volumeName):: {volumeName: volumeName}, // VolumeNamespace specifies the scope of the volume within StorageOS. If no namespace is specified then the Pod's namespace will be used. This allows the Kubernetes name scoping to be mirrored within StorageOS for tighter integration. Set VolumeName to any name to override the default behaviour. Set to "default" if you are not using namespaces within StorageOS. Namespaces that do not pre-exist within StorageOS will be created. volumeNamespace(volumeNamespace):: {volumeNamespace: volumeNamespace}, mixin:: { // SecretRef specifies the secret to use for obtaining the StorageOS API credentials. If not specified, default values will be attempted. secretRef:: { local __secretRefMixin(secretRef) = {secretRef+: secretRef}, mixinInstance(secretRef):: __secretRefMixin(secretRef), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), }, secretRefType:: hidden.core.v1.localObjectReference, }, }, // TCPSocketAction describes an action based on opening a socket tcpSocketAction:: { new():: {}, // Optional: Host name to connect to, defaults to the pod IP. host(host):: {host: host}, // Number or name of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. port(port):: {port: port}, mixin:: { }, }, // The node this Taint is attached to has the effect "effect" on any pod that that does not tolerate the Taint. taint:: { new():: {}, // Required. The effect of the taint on pods that do not tolerate the taint. Valid effects are NoSchedule, PreferNoSchedule and NoExecute. effect(effect):: {effect: effect}, // Required. The taint key to be applied to a node. key(key):: {key: key}, // Required. The taint value corresponding to the taint key. value(value):: {value: value}, mixin:: { // TimeAdded represents the time at which the taint was added. It is only written for NoExecute taints. timeAdded:: { local __timeAddedMixin(timeAdded) = {timeAdded+: timeAdded}, mixinInstance(timeAdded):: __timeAddedMixin(timeAdded), }, timeAddedType:: hidden.meta.v1.time, }, }, // The pod this Toleration is attached to tolerates any taint that matches the triple using the matching operator . toleration:: { new():: {}, // Effect indicates the taint effect to match. Empty means match all taint effects. When specified, allowed values are NoSchedule, PreferNoSchedule and NoExecute. effect(effect):: {effect: effect}, // Key is the taint key that the toleration applies to. Empty means match all taint keys. If the key is empty, operator must be Exists; this combination means to match all values and all keys. key(key):: {key: key}, // Operator represents a key's relationship to the value. Valid operators are Exists and Equal. Defaults to Equal. Exists is equivalent to wildcard for value, so that a pod can tolerate all taints of a particular category. operator(operator):: {operator: operator}, // TolerationSeconds represents the period of time the toleration (which must be of effect NoExecute, otherwise this field is ignored) tolerates the taint. By default, it is not set, which means tolerate the taint forever (do not evict). Zero and negative values will be treated as 0 (evict immediately) by the system. tolerationSeconds(tolerationSeconds):: {tolerationSeconds: tolerationSeconds}, // Value is the taint value the toleration matches to. If the operator is Exists, the value should be empty, otherwise just a regular string. value(value):: {value: value}, mixin:: { }, }, // Volume represents a named volume in a pod that may be accessed by any container in the pod. volume:: { fromConfigMap(name, configMapName, configMapItems):: {} + self.name(name) + self.mixin.configMap.name(configMapName) + self.mixin.configMap.items(configMapItems), fromEmptyDir(name, emptyDir={}):: {} + self.name(name) + self.mixin.emptyDir.mixinInstance(emptyDir), fromPersistentVolumeClaim(name, claimName):: {} + self.name(name) + self.mixin.persistentVolumeClaim.claimName(claimName), fromHostPath(name, hostPath):: {} + self.name(name) + self.mixin.hostPath.path(hostPath), // Volume's name. Must be a DNS_LABEL and unique within the pod. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: {name: name}, mixin:: { // AWSElasticBlockStore represents an AWS Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore awsElasticBlockStore:: { local __awsElasticBlockStoreMixin(awsElasticBlockStore) = {awsElasticBlockStore+: awsElasticBlockStore}, mixinInstance(awsElasticBlockStore):: __awsElasticBlockStoreMixin(awsElasticBlockStore), // Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore fsType(fsType):: __awsElasticBlockStoreMixin({fsType: fsType}), // The partition in the volume that you want to mount. If omitted, the default is to mount by volume name. Examples: For volume /dev/sda1, you specify the partition as "1". Similarly, the volume partition for /dev/sda is "0" (or you can leave the property empty). partition(partition):: __awsElasticBlockStoreMixin({partition: partition}), // Specify "true" to force and set the ReadOnly property in VolumeMounts to "true". If omitted, the default is "false". More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore readOnly(readOnly):: __awsElasticBlockStoreMixin({readOnly: readOnly}), // Unique ID of the persistent disk resource in AWS (Amazon EBS volume). More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore volumeId(volumeId):: __awsElasticBlockStoreMixin({volumeID: volumeId}), }, awsElasticBlockStoreType:: hidden.core.v1.awsElasticBlockStoreVolumeSource, // AzureDisk represents an Azure Data Disk mount on the host and bind mount to the pod. azureDisk:: { local __azureDiskMixin(azureDisk) = {azureDisk+: azureDisk}, mixinInstance(azureDisk):: __azureDiskMixin(azureDisk), // Host Caching mode: None, Read Only, Read Write. cachingMode(cachingMode):: __azureDiskMixin({cachingMode: cachingMode}), // The Name of the data disk in the blob storage diskName(diskName):: __azureDiskMixin({diskName: diskName}), // The URI the data disk in the blob storage diskUri(diskUri):: __azureDiskMixin({diskURI: diskUri}), // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: __azureDiskMixin({fsType: fsType}), // Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: __azureDiskMixin({readOnly: readOnly}), }, azureDiskType:: hidden.core.v1.azureDiskVolumeSource, // AzureFile represents an Azure File Service mount on the host and bind mount to the pod. azureFile:: { local __azureFileMixin(azureFile) = {azureFile+: azureFile}, mixinInstance(azureFile):: __azureFileMixin(azureFile), // Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: __azureFileMixin({readOnly: readOnly}), // the name of secret that contains Azure Storage Account Name and Key secretName(secretName):: __azureFileMixin({secretName: secretName}), // Share Name shareName(shareName):: __azureFileMixin({shareName: shareName}), }, azureFileType:: hidden.core.v1.azureFileVolumeSource, // CephFS represents a Ceph FS mount on the host that shares a pod's lifetime cephfs:: { local __cephfsMixin(cephfs) = {cephfs+: cephfs}, mixinInstance(cephfs):: __cephfsMixin(cephfs), // Required: Monitors is a collection of Ceph monitors More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it monitors(monitors):: if std.type(monitors) == "array" then __cephfsMixin({monitors+: monitors}) else __cephfsMixin({monitors+: [monitors]}), // Optional: Used as the mounted root, rather than the full Ceph tree, default is / path(path):: __cephfsMixin({path: path}), // Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it readOnly(readOnly):: __cephfsMixin({readOnly: readOnly}), // Optional: SecretFile is the path to key ring for User, default is /etc/ceph/user.secret More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it secretFile(secretFile):: __cephfsMixin({secretFile: secretFile}), // Optional: SecretRef is reference to the authentication secret for User, default is empty. More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it secretRef:: { local __secretRefMixin(secretRef) = __cephfsMixin({secretRef+: secretRef}), mixinInstance(secretRef):: __secretRefMixin(secretRef), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), }, secretRefType:: hidden.core.v1.localObjectReference, // Optional: User is the rados user name, default is admin More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it user(user):: __cephfsMixin({user: user}), }, cephfsType:: hidden.core.v1.cephFsVolumeSource, // Cinder represents a cinder volume attached and mounted on kubelets host machine More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md cinder:: { local __cinderMixin(cinder) = {cinder+: cinder}, mixinInstance(cinder):: __cinderMixin(cinder), // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md fsType(fsType):: __cinderMixin({fsType: fsType}), // Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md readOnly(readOnly):: __cinderMixin({readOnly: readOnly}), // volume id used to identify the volume in cinder More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md volumeId(volumeId):: __cinderMixin({volumeID: volumeId}), }, cinderType:: hidden.core.v1.cinderVolumeSource, // ConfigMap represents a configMap that should populate this volume configMap:: { local __configMapMixin(configMap) = {configMap+: configMap}, mixinInstance(configMap):: __configMapMixin(configMap), // Optional: mode bits to use on created files by default. Must be a value between 0 and 0777. Defaults to 0644. Directories within the path are not affected by this setting. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set. defaultMode(defaultMode):: __configMapMixin({defaultMode: defaultMode}), // If unspecified, each key-value pair in the Data field of the referenced ConfigMap will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the ConfigMap, the volume setup will error unless it is marked optional. Paths must be relative and may not contain the '..' path or start with '..'. items(items):: if std.type(items) == "array" then __configMapMixin({items+: items}) else __configMapMixin({items+: [items]}), itemsType:: hidden.core.v1.keyToPath, // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __configMapMixin({name: name}), // Specify whether the ConfigMap or it's keys must be defined optional(optional):: __configMapMixin({optional: optional}), }, configMapType:: hidden.core.v1.configMapVolumeSource, // DownwardAPI represents downward API about the pod that should populate this volume downwardApi:: { local __downwardApiMixin(downwardApi) = {downwardAPI+: downwardApi}, mixinInstance(downwardApi):: __downwardApiMixin(downwardApi), // Optional: mode bits to use on created files by default. Must be a value between 0 and 0777. Defaults to 0644. Directories within the path are not affected by this setting. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set. defaultMode(defaultMode):: __downwardApiMixin({defaultMode: defaultMode}), // Items is a list of downward API volume file items(items):: if std.type(items) == "array" then __downwardApiMixin({items+: items}) else __downwardApiMixin({items+: [items]}), itemsType:: hidden.core.v1.downwardApiVolumeFile, }, downwardApiType:: hidden.core.v1.downwardApiVolumeSource, // EmptyDir represents a temporary directory that shares a pod's lifetime. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir emptyDir:: { local __emptyDirMixin(emptyDir) = {emptyDir+: emptyDir}, mixinInstance(emptyDir):: __emptyDirMixin(emptyDir), // What type of storage medium should back this directory. The default is "" which means to use the node's default medium. Must be an empty string (default) or Memory. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir medium(medium):: __emptyDirMixin({medium: medium}), // Total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: http://kubernetes.io/docs/user-guide/volumes#emptydir sizeLimit:: { local __sizeLimitMixin(sizeLimit) = __emptyDirMixin({sizeLimit+: sizeLimit}), mixinInstance(sizeLimit):: __sizeLimitMixin(sizeLimit), }, sizeLimitType:: hidden.core.resource.quantity, }, emptyDirType:: hidden.core.v1.emptyDirVolumeSource, // FC represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod. fc:: { local __fcMixin(fc) = {fc+: fc}, mixinInstance(fc):: __fcMixin(fc), // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: __fcMixin({fsType: fsType}), // Required: FC target lun number lun(lun):: __fcMixin({lun: lun}), // Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: __fcMixin({readOnly: readOnly}), // Required: FC target worldwide names (WWNs) targetWwns(targetWwns):: if std.type(targetWwns) == "array" then __fcMixin({targetWWNs+: targetWwns}) else __fcMixin({targetWWNs+: [targetWwns]}), }, fcType:: hidden.core.v1.fcVolumeSource, // FlexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin. This is an alpha feature and may change in future. flexVolume:: { local __flexVolumeMixin(flexVolume) = {flexVolume+: flexVolume}, mixinInstance(flexVolume):: __flexVolumeMixin(flexVolume), // Driver is the name of the driver to use for this volume. driver(driver):: __flexVolumeMixin({driver: driver}), // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". The default filesystem depends on FlexVolume script. fsType(fsType):: __flexVolumeMixin({fsType: fsType}), // Optional: Extra command options if any. options(options):: __flexVolumeMixin({options+: options}), // Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: __flexVolumeMixin({readOnly: readOnly}), // Optional: SecretRef is reference to the secret object containing sensitive information to pass to the plugin scripts. This may be empty if no secret object is specified. If the secret object contains more than one secret, all secrets are passed to the plugin scripts. secretRef:: { local __secretRefMixin(secretRef) = __flexVolumeMixin({secretRef+: secretRef}), mixinInstance(secretRef):: __secretRefMixin(secretRef), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), }, secretRefType:: hidden.core.v1.localObjectReference, }, flexVolumeType:: hidden.core.v1.flexVolumeSource, // Flocker represents a Flocker volume attached to a kubelet's host machine. This depends on the Flocker control service being running flocker:: { local __flockerMixin(flocker) = {flocker+: flocker}, mixinInstance(flocker):: __flockerMixin(flocker), // Name of the dataset stored as metadata -> name on the dataset for Flocker should be considered as deprecated datasetName(datasetName):: __flockerMixin({datasetName: datasetName}), // UUID of the dataset. This is unique identifier of a Flocker dataset datasetUuid(datasetUuid):: __flockerMixin({datasetUUID: datasetUuid}), }, flockerType:: hidden.core.v1.flockerVolumeSource, // GCEPersistentDisk represents a GCE Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk gcePersistentDisk:: { local __gcePersistentDiskMixin(gcePersistentDisk) = {gcePersistentDisk+: gcePersistentDisk}, mixinInstance(gcePersistentDisk):: __gcePersistentDiskMixin(gcePersistentDisk), // Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk fsType(fsType):: __gcePersistentDiskMixin({fsType: fsType}), // The partition in the volume that you want to mount. If omitted, the default is to mount by volume name. Examples: For volume /dev/sda1, you specify the partition as "1". Similarly, the volume partition for /dev/sda is "0" (or you can leave the property empty). More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk partition(partition):: __gcePersistentDiskMixin({partition: partition}), // Unique name of the PD resource in GCE. Used to identify the disk in GCE. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk pdName(pdName):: __gcePersistentDiskMixin({pdName: pdName}), // ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk readOnly(readOnly):: __gcePersistentDiskMixin({readOnly: readOnly}), }, gcePersistentDiskType:: hidden.core.v1.gcePersistentDiskVolumeSource, // GitRepo represents a git repository at a particular revision. gitRepo:: { local __gitRepoMixin(gitRepo) = {gitRepo+: gitRepo}, mixinInstance(gitRepo):: __gitRepoMixin(gitRepo), // Target directory name. Must not contain or start with '..'. If '.' is supplied, the volume directory will be the git repository. Otherwise, if specified, the volume will contain the git repository in the subdirectory with the given name. directory(directory):: __gitRepoMixin({directory: directory}), // Repository URL repository(repository):: __gitRepoMixin({repository: repository}), // Commit hash for the specified revision. revision(revision):: __gitRepoMixin({revision: revision}), }, gitRepoType:: hidden.core.v1.gitRepoVolumeSource, // Glusterfs represents a Glusterfs mount on the host that shares a pod's lifetime. More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md glusterfs:: { local __glusterfsMixin(glusterfs) = {glusterfs+: glusterfs}, mixinInstance(glusterfs):: __glusterfsMixin(glusterfs), // EndpointsName is the endpoint name that details Glusterfs topology. More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod endpoints(endpoints):: __glusterfsMixin({endpoints: endpoints}), // Path is the Glusterfs volume path. More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod path(path):: __glusterfsMixin({path: path}), // ReadOnly here will force the Glusterfs volume to be mounted with read-only permissions. Defaults to false. More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod readOnly(readOnly):: __glusterfsMixin({readOnly: readOnly}), }, glusterfsType:: hidden.core.v1.glusterfsVolumeSource, // HostPath represents a pre-existing file or directory on the host machine that is directly exposed to the container. This is generally used for system agents or other privileged things that are allowed to see the host machine. Most containers will NOT need this. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath hostPath:: { local __hostPathMixin(hostPath) = {hostPath+: hostPath}, mixinInstance(hostPath):: __hostPathMixin(hostPath), // Path of the directory on the host. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath path(path):: __hostPathMixin({path: path}), }, hostPathType:: hidden.core.v1.hostPathVolumeSource, // ISCSI represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: https://releases.k8s.io/HEAD/examples/volumes/iscsi/README.md iscsi:: { local __iscsiMixin(iscsi) = {iscsi+: iscsi}, mixinInstance(iscsi):: __iscsiMixin(iscsi), // whether support iSCSI Discovery CHAP authentication chapAuthDiscovery(chapAuthDiscovery):: __iscsiMixin({chapAuthDiscovery: chapAuthDiscovery}), // whether support iSCSI Session CHAP authentication chapAuthSession(chapAuthSession):: __iscsiMixin({chapAuthSession: chapAuthSession}), // Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#iscsi fsType(fsType):: __iscsiMixin({fsType: fsType}), // Target iSCSI Qualified Name. iqn(iqn):: __iscsiMixin({iqn: iqn}), // Optional: Defaults to 'default' (tcp). iSCSI interface name that uses an iSCSI transport. iscsiInterface(iscsiInterface):: __iscsiMixin({iscsiInterface: iscsiInterface}), // iSCSI target lun number. lun(lun):: __iscsiMixin({lun: lun}), // iSCSI target portal List. The portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260). portals(portals):: if std.type(portals) == "array" then __iscsiMixin({portals+: portals}) else __iscsiMixin({portals+: [portals]}), // ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. readOnly(readOnly):: __iscsiMixin({readOnly: readOnly}), // CHAP secret for iSCSI target and initiator authentication secretRef:: { local __secretRefMixin(secretRef) = __iscsiMixin({secretRef+: secretRef}), mixinInstance(secretRef):: __secretRefMixin(secretRef), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), }, secretRefType:: hidden.core.v1.localObjectReference, // iSCSI target portal. The portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260). targetPortal(targetPortal):: __iscsiMixin({targetPortal: targetPortal}), }, iscsiType:: hidden.core.v1.iscsiVolumeSource, // NFS represents an NFS mount on the host that shares a pod's lifetime More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs nfs:: { local __nfsMixin(nfs) = {nfs+: nfs}, mixinInstance(nfs):: __nfsMixin(nfs), // Path that is exported by the NFS server. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs path(path):: __nfsMixin({path: path}), // ReadOnly here will force the NFS export to be mounted with read-only permissions. Defaults to false. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs readOnly(readOnly):: __nfsMixin({readOnly: readOnly}), // Server is the hostname or IP address of the NFS server. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs server(server):: __nfsMixin({server: server}), }, nfsType:: hidden.core.v1.nfsVolumeSource, // PersistentVolumeClaimVolumeSource represents a reference to a PersistentVolumeClaim in the same namespace. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims persistentVolumeClaim:: { local __persistentVolumeClaimMixin(persistentVolumeClaim) = {persistentVolumeClaim+: persistentVolumeClaim}, mixinInstance(persistentVolumeClaim):: __persistentVolumeClaimMixin(persistentVolumeClaim), // ClaimName is the name of a PersistentVolumeClaim in the same namespace as the pod using this volume. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims claimName(claimName):: __persistentVolumeClaimMixin({claimName: claimName}), // Will force the ReadOnly setting in VolumeMounts. Default false. readOnly(readOnly):: __persistentVolumeClaimMixin({readOnly: readOnly}), }, persistentVolumeClaimType:: hidden.core.v1.persistentVolumeClaimVolumeSource, // PhotonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine photonPersistentDisk:: { local __photonPersistentDiskMixin(photonPersistentDisk) = {photonPersistentDisk+: photonPersistentDisk}, mixinInstance(photonPersistentDisk):: __photonPersistentDiskMixin(photonPersistentDisk), // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: __photonPersistentDiskMixin({fsType: fsType}), // ID that identifies Photon Controller persistent disk pdId(pdId):: __photonPersistentDiskMixin({pdID: pdId}), }, photonPersistentDiskType:: hidden.core.v1.photonPersistentDiskVolumeSource, // PortworxVolume represents a portworx volume attached and mounted on kubelets host machine portworxVolume:: { local __portworxVolumeMixin(portworxVolume) = {portworxVolume+: portworxVolume}, mixinInstance(portworxVolume):: __portworxVolumeMixin(portworxVolume), // FSType represents the filesystem type to mount Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: __portworxVolumeMixin({fsType: fsType}), // Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: __portworxVolumeMixin({readOnly: readOnly}), // VolumeID uniquely identifies a Portworx volume volumeId(volumeId):: __portworxVolumeMixin({volumeID: volumeId}), }, portworxVolumeType:: hidden.core.v1.portworxVolumeSource, // Items for all in one resources secrets, configmaps, and downward API projected:: { local __projectedMixin(projected) = {projected+: projected}, mixinInstance(projected):: __projectedMixin(projected), // Mode bits to use on created files by default. Must be a value between 0 and 0777. Directories within the path are not affected by this setting. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set. defaultMode(defaultMode):: __projectedMixin({defaultMode: defaultMode}), // list of volume projections sources(sources):: if std.type(sources) == "array" then __projectedMixin({sources+: sources}) else __projectedMixin({sources+: [sources]}), sourcesType:: hidden.core.v1.volumeProjection, }, projectedType:: hidden.core.v1.projectedVolumeSource, // Quobyte represents a Quobyte mount on the host that shares a pod's lifetime quobyte:: { local __quobyteMixin(quobyte) = {quobyte+: quobyte}, mixinInstance(quobyte):: __quobyteMixin(quobyte), // Group to map volume access to Default is no group group(group):: __quobyteMixin({group: group}), // ReadOnly here will force the Quobyte volume to be mounted with read-only permissions. Defaults to false. readOnly(readOnly):: __quobyteMixin({readOnly: readOnly}), // Registry represents a single or multiple Quobyte Registry services specified as a string as host:port pair (multiple entries are separated with commas) which acts as the central registry for volumes registry(registry):: __quobyteMixin({registry: registry}), // User to map volume access to Defaults to serivceaccount user user(user):: __quobyteMixin({user: user}), // Volume is a string that references an already created Quobyte volume by name. volume(volume):: __quobyteMixin({volume: volume}), }, quobyteType:: hidden.core.v1.quobyteVolumeSource, // RBD represents a Rados Block Device mount on the host that shares a pod's lifetime. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md rbd:: { local __rbdMixin(rbd) = {rbd+: rbd}, mixinInstance(rbd):: __rbdMixin(rbd), // Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#rbd fsType(fsType):: __rbdMixin({fsType: fsType}), // The rados image name. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it image(image):: __rbdMixin({image: image}), // Keyring is the path to key ring for RBDUser. Default is /etc/ceph/keyring. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it keyring(keyring):: __rbdMixin({keyring: keyring}), // A collection of Ceph monitors. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it monitors(monitors):: if std.type(monitors) == "array" then __rbdMixin({monitors+: monitors}) else __rbdMixin({monitors+: [monitors]}), // The rados pool name. Default is rbd. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it pool(pool):: __rbdMixin({pool: pool}), // ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it readOnly(readOnly):: __rbdMixin({readOnly: readOnly}), // SecretRef is name of the authentication secret for RBDUser. If provided overrides keyring. Default is nil. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it secretRef:: { local __secretRefMixin(secretRef) = __rbdMixin({secretRef+: secretRef}), mixinInstance(secretRef):: __secretRefMixin(secretRef), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), }, secretRefType:: hidden.core.v1.localObjectReference, // The rados user name. Default is admin. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it user(user):: __rbdMixin({user: user}), }, rbdType:: hidden.core.v1.rbdVolumeSource, // ScaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes. scaleIo:: { local __scaleIoMixin(scaleIo) = {scaleIO+: scaleIo}, mixinInstance(scaleIo):: __scaleIoMixin(scaleIo), // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: __scaleIoMixin({fsType: fsType}), // The host address of the ScaleIO API Gateway. gateway(gateway):: __scaleIoMixin({gateway: gateway}), // The name of the Protection Domain for the configured storage (defaults to "default"). protectionDomain(protectionDomain):: __scaleIoMixin({protectionDomain: protectionDomain}), // Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: __scaleIoMixin({readOnly: readOnly}), // SecretRef references to the secret for ScaleIO user and other sensitive information. If this is not provided, Login operation will fail. secretRef:: { local __secretRefMixin(secretRef) = __scaleIoMixin({secretRef+: secretRef}), mixinInstance(secretRef):: __secretRefMixin(secretRef), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), }, secretRefType:: hidden.core.v1.localObjectReference, // Flag to enable/disable SSL communication with Gateway, default false sslEnabled(sslEnabled):: __scaleIoMixin({sslEnabled: sslEnabled}), // Indicates whether the storage for a volume should be thick or thin (defaults to "thin"). storageMode(storageMode):: __scaleIoMixin({storageMode: storageMode}), // The Storage Pool associated with the protection domain (defaults to "default"). storagePool(storagePool):: __scaleIoMixin({storagePool: storagePool}), // The name of the storage system as configured in ScaleIO. system(system):: __scaleIoMixin({system: system}), // The name of a volume already created in the ScaleIO system that is associated with this volume source. volumeName(volumeName):: __scaleIoMixin({volumeName: volumeName}), }, scaleIoType:: hidden.core.v1.scaleIoVolumeSource, // Secret represents a secret that should populate this volume. More info: https://kubernetes.io/docs/concepts/storage/volumes#secret secret:: { local __secretMixin(secret) = {secret+: secret}, mixinInstance(secret):: __secretMixin(secret), // Optional: mode bits to use on created files by default. Must be a value between 0 and 0777. Defaults to 0644. Directories within the path are not affected by this setting. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set. defaultMode(defaultMode):: __secretMixin({defaultMode: defaultMode}), // If unspecified, each key-value pair in the Data field of the referenced Secret will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the Secret, the volume setup will error unless it is marked optional. Paths must be relative and may not contain the '..' path or start with '..'. items(items):: if std.type(items) == "array" then __secretMixin({items+: items}) else __secretMixin({items+: [items]}), itemsType:: hidden.core.v1.keyToPath, // Specify whether the Secret or it's keys must be defined optional(optional):: __secretMixin({optional: optional}), // Name of the secret in the pod's namespace to use. More info: https://kubernetes.io/docs/concepts/storage/volumes#secret secretName(secretName):: __secretMixin({secretName: secretName}), }, secretType:: hidden.core.v1.secretVolumeSource, // StorageOS represents a StorageOS volume attached and mounted on Kubernetes nodes. storageos:: { local __storageosMixin(storageos) = {storageos+: storageos}, mixinInstance(storageos):: __storageosMixin(storageos), // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: __storageosMixin({fsType: fsType}), // Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. readOnly(readOnly):: __storageosMixin({readOnly: readOnly}), // SecretRef specifies the secret to use for obtaining the StorageOS API credentials. If not specified, default values will be attempted. secretRef:: { local __secretRefMixin(secretRef) = __storageosMixin({secretRef+: secretRef}), mixinInstance(secretRef):: __secretRefMixin(secretRef), // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretRefMixin({name: name}), }, secretRefType:: hidden.core.v1.localObjectReference, // VolumeName is the human-readable name of the StorageOS volume. Volume names are only unique within a namespace. volumeName(volumeName):: __storageosMixin({volumeName: volumeName}), // VolumeNamespace specifies the scope of the volume within StorageOS. If no namespace is specified then the Pod's namespace will be used. This allows the Kubernetes name scoping to be mirrored within StorageOS for tighter integration. Set VolumeName to any name to override the default behaviour. Set to "default" if you are not using namespaces within StorageOS. Namespaces that do not pre-exist within StorageOS will be created. volumeNamespace(volumeNamespace):: __storageosMixin({volumeNamespace: volumeNamespace}), }, storageosType:: hidden.core.v1.storageOSVolumeSource, // VsphereVolume represents a vSphere volume attached and mounted on kubelets host machine vsphereVolume:: { local __vsphereVolumeMixin(vsphereVolume) = {vsphereVolume+: vsphereVolume}, mixinInstance(vsphereVolume):: __vsphereVolumeMixin(vsphereVolume), // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: __vsphereVolumeMixin({fsType: fsType}), // Storage Policy Based Management (SPBM) profile ID associated with the StoragePolicyName. storagePolicyID(storagePolicyID):: __vsphereVolumeMixin({storagePolicyID: storagePolicyID}), // Storage Policy Based Management (SPBM) profile name. storagePolicyName(storagePolicyName):: __vsphereVolumeMixin({storagePolicyName: storagePolicyName}), // Path that identifies vSphere volume vmdk volumePath(volumePath):: __vsphereVolumeMixin({volumePath: volumePath}), }, vsphereVolumeType:: hidden.core.v1.vsphereVirtualDiskVolumeSource, }, }, // VolumeMount describes a mounting of a Volume within a container. volumeMount:: { new(name, mountPath, readOnly=false):: {} + self.name(name) + self.mountPath(mountPath) + self.readOnly(readOnly), // Path within the container at which the volume should be mounted. Must not contain ':'. mountPath(mountPath):: {mountPath: mountPath}, // This must match the Name of a Volume. name(name):: {name: name}, // Mounted read-only if true, read-write otherwise (false or unspecified). Defaults to false. readOnly(readOnly):: {readOnly: readOnly}, // Path within the volume from which the container's volume should be mounted. Defaults to "" (volume's root). subPath(subPath):: {subPath: subPath}, mixin:: { }, }, // Projection that may be projected along with other supported volume types volumeProjection:: { new():: {}, mixin:: { // information about the configMap data to project configMap:: { local __configMapMixin(configMap) = {configMap+: configMap}, mixinInstance(configMap):: __configMapMixin(configMap), // If unspecified, each key-value pair in the Data field of the referenced ConfigMap will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the ConfigMap, the volume setup will error unless it is marked optional. Paths must be relative and may not contain the '..' path or start with '..'. items(items):: if std.type(items) == "array" then __configMapMixin({items+: items}) else __configMapMixin({items+: [items]}), itemsType:: hidden.core.v1.keyToPath, // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __configMapMixin({name: name}), // Specify whether the ConfigMap or it's keys must be defined optional(optional):: __configMapMixin({optional: optional}), }, configMapType:: hidden.core.v1.configMapProjection, // information about the downwardAPI data to project downwardApi:: { local __downwardApiMixin(downwardApi) = {downwardAPI+: downwardApi}, mixinInstance(downwardApi):: __downwardApiMixin(downwardApi), // Items is a list of DownwardAPIVolume file items(items):: if std.type(items) == "array" then __downwardApiMixin({items+: items}) else __downwardApiMixin({items+: [items]}), itemsType:: hidden.core.v1.downwardApiVolumeFile, }, downwardApiType:: hidden.core.v1.downwardApiProjection, // information about the secret data to project secret:: { local __secretMixin(secret) = {secret+: secret}, mixinInstance(secret):: __secretMixin(secret), // If unspecified, each key-value pair in the Data field of the referenced Secret will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the Secret, the volume setup will error unless it is marked optional. Paths must be relative and may not contain the '..' path or start with '..'. items(items):: if std.type(items) == "array" then __secretMixin({items+: items}) else __secretMixin({items+: [items]}), itemsType:: hidden.core.v1.keyToPath, // Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names name(name):: __secretMixin({name: name}), // Specify whether the Secret or its key must be defined optional(optional):: __secretMixin({optional: optional}), }, secretType:: hidden.core.v1.secretProjection, }, }, // Represents a vSphere volume resource. vsphereVirtualDiskVolumeSource:: { new():: {}, // Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. fsType(fsType):: {fsType: fsType}, // Storage Policy Based Management (SPBM) profile ID associated with the StoragePolicyName. storagePolicyID(storagePolicyID):: {storagePolicyID: storagePolicyID}, // Storage Policy Based Management (SPBM) profile name. storagePolicyName(storagePolicyName):: {storagePolicyName: storagePolicyName}, // Path that identifies vSphere volume vmdk volumePath(volumePath):: {volumePath: volumePath}, mixin:: { }, }, // The weights of all of the matched WeightedPodAffinityTerm fields are added per-node to find the most preferred node(s) weightedPodAffinityTerm:: { new():: {}, // weight associated with matching the corresponding podAffinityTerm, in the range 1-100. weight(weight):: {weight: weight}, mixin:: { // Required. A pod affinity term, associated with the corresponding weight. podAffinityTerm:: { local __podAffinityTermMixin(podAffinityTerm) = {podAffinityTerm+: podAffinityTerm}, mixinInstance(podAffinityTerm):: __podAffinityTermMixin(podAffinityTerm), // A label query over a set of resources, in this case pods. labelSelector:: { local __labelSelectorMixin(labelSelector) = __podAffinityTermMixin({labelSelector+: labelSelector}), mixinInstance(labelSelector):: __labelSelectorMixin(labelSelector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __labelSelectorMixin({matchExpressions+: matchExpressions}) else __labelSelectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __labelSelectorMixin({matchLabels+: matchLabels}), }, labelSelectorType:: hidden.meta.v1.labelSelector, // namespaces specifies which namespaces the labelSelector applies to (matches against); null or empty list means "this pod's namespace" namespaces(namespaces):: if std.type(namespaces) == "array" then __podAffinityTermMixin({namespaces+: namespaces}) else __podAffinityTermMixin({namespaces+: [namespaces]}), // This pod should be co-located (affinity) or not co-located (anti-affinity) with the pods matching the labelSelector in the specified namespaces, where co-located is defined as running on a node whose value of the label with key topologyKey matches that of any node on which any of the selected pods is running. For PreferredDuringScheduling pod anti-affinity, empty topologyKey is interpreted as "all topologies" ("all topologies" here means all the topologyKeys indicated by scheduler command-line argument --failure-domains); for affinity and for RequiredDuringScheduling pod anti-affinity, empty topologyKey is not allowed. topologyKey(topologyKey):: __podAffinityTermMixin({topologyKey: topologyKey}), }, podAffinityTermType:: hidden.core.v1.podAffinityTerm, }, }, }, }, extensions:: { v1beta1:: { local apiVersion = {apiVersion: "extensions/v1beta1"}, // An APIVersion represents a single concrete version of an object model. apiVersion:: { new():: {}, // Name of this version (e.g. 'v1'). name(name):: {name: name}, mixin:: { }, }, // DaemonSetSpec is the specification of a daemon set. daemonSetSpec:: { new():: {}, // The minimum number of seconds for which a newly created DaemonSet pod should be ready without any of its container crashing, for it to be considered available. Defaults to 0 (pod will be considered available as soon as it is ready). minReadySeconds(minReadySeconds):: {minReadySeconds: minReadySeconds}, // The number of old history to retain to allow rollback. This is a pointer to distinguish between explicit zero and not specified. Defaults to 10. revisionHistoryLimit(revisionHistoryLimit):: {revisionHistoryLimit: revisionHistoryLimit}, mixin:: { // A label query over pods that are managed by the daemon set. Must match in order to be controlled. If empty, defaulted to labels on Pod template. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors selector:: { local __selectorMixin(selector) = {selector+: selector}, mixinInstance(selector):: __selectorMixin(selector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __selectorMixin({matchExpressions+: matchExpressions}) else __selectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __selectorMixin({matchLabels+: matchLabels}), }, selectorType:: hidden.meta.v1.labelSelector, // An object that describes the pod that will be created. The DaemonSet will create exactly one copy of this pod on every node that matches the template's node selector (or on every node if no node selector is specified). More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#pod-template template:: { local __templateMixin(template) = {template+: template}, mixinInstance(template):: __templateMixin(template), // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = __templateMixin({metadata+: metadata}), mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = __templateMixin({spec+: spec}), mixinInstance(spec):: __specMixin(spec), // Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer. activeDeadlineSeconds(activeDeadlineSeconds):: __specMixin({activeDeadlineSeconds: activeDeadlineSeconds}), // If specified, the pod's scheduling constraints affinity:: { local __affinityMixin(affinity) = __specMixin({affinity+: affinity}), mixinInstance(affinity):: __affinityMixin(affinity), // Describes node affinity scheduling rules for the pod. nodeAffinity:: { local __nodeAffinityMixin(nodeAffinity) = __affinityMixin({nodeAffinity+: nodeAffinity}), mixinInstance(nodeAffinity):: __nodeAffinityMixin(nodeAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.preferredSchedulingTerm, // If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node. requiredDuringSchedulingIgnoredDuringExecution:: { local __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution) = __nodeAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}), mixinInstance(requiredDuringSchedulingIgnoredDuringExecution):: __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution), // Required. A list of node selector terms. The terms are ORed. nodeSelectorTerms(nodeSelectorTerms):: if std.type(nodeSelectorTerms) == "array" then __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: nodeSelectorTerms}) else __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: [nodeSelectorTerms]}), nodeSelectorTermsType:: hidden.core.v1.nodeSelectorTerm, }, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.nodeSelector, }, nodeAffinityType:: hidden.core.v1.nodeAffinity, // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)). podAffinity:: { local __podAffinityMixin(podAffinity) = __affinityMixin({podAffinity+: podAffinity}), mixinInstance(podAffinity):: __podAffinityMixin(podAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAffinityType:: hidden.core.v1.podAffinity, // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)). podAntiAffinity:: { local __podAntiAffinityMixin(podAntiAffinity) = __affinityMixin({podAntiAffinity+: podAntiAffinity}), mixinInstance(podAntiAffinity):: __podAntiAffinityMixin(podAntiAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAntiAffinityType:: hidden.core.v1.podAntiAffinity, }, affinityType:: hidden.core.v1.affinity, // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted. automountServiceAccountToken(automountServiceAccountToken):: __specMixin({automountServiceAccountToken: automountServiceAccountToken}), // List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated. containers(containers):: if std.type(containers) == "array" then __specMixin({containers+: containers}) else __specMixin({containers+: [containers]}), containersType:: hidden.core.v1.container, // Set DNS policy for containers within the pod. One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. Defaults to "ClusterFirst". To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. dnsPolicy(dnsPolicy):: __specMixin({dnsPolicy: dnsPolicy}), // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts file if specified. This is only valid for non-hostNetwork pods. hostAliases(hostAliases):: if std.type(hostAliases) == "array" then __specMixin({hostAliases+: hostAliases}) else __specMixin({hostAliases+: [hostAliases]}), hostAliasesType:: hidden.core.v1.hostAlias, // Use the host's ipc namespace. Optional: Default to false. hostIpc(hostIpc):: __specMixin({hostIPC: hostIpc}), // Host networking requested for this pod. Use the host's network namespace. If this option is set, the ports that will be used must be specified. Default to false. hostNetwork(hostNetwork):: __specMixin({hostNetwork: hostNetwork}), // Use the host's pid namespace. Optional: Default to false. hostPid(hostPid):: __specMixin({hostPID: hostPid}), // Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value. hostname(hostname):: __specMixin({hostname: hostname}), // 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. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod imagePullSecrets(imagePullSecrets):: if std.type(imagePullSecrets) == "array" then __specMixin({imagePullSecrets+: imagePullSecrets}) else __specMixin({imagePullSecrets+: [imagePullSecrets]}), imagePullSecretsType:: hidden.core.v1.localObjectReference, // List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ initContainers(initContainers):: if std.type(initContainers) == "array" then __specMixin({initContainers+: initContainers}) else __specMixin({initContainers+: [initContainers]}), initContainersType:: hidden.core.v1.container, // NodeName is a request to schedule this pod onto a specific node. If it is non-empty, the scheduler simply schedules this pod onto that node, assuming that it fits resource requirements. nodeName(nodeName):: __specMixin({nodeName: nodeName}), // NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ nodeSelector(nodeSelector):: __specMixin({nodeSelector+: nodeSelector}), // Restart policy for all containers within the pod. One of Always, OnFailure, Never. Default to Always. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy restartPolicy(restartPolicy):: __specMixin({restartPolicy: restartPolicy}), // If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler. schedulerName(schedulerName):: __specMixin({schedulerName: schedulerName}), // SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field. securityContext:: { local __securityContextMixin(securityContext) = __specMixin({securityContext+: securityContext}), mixinInstance(securityContext):: __securityContextMixin(securityContext), // A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod: // // 1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw---- // // If unset, the Kubelet will not modify the ownership and permissions of any volume. fsGroup(fsGroup):: __securityContextMixin({fsGroup: fsGroup}), // Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsNonRoot(runAsNonRoot):: __securityContextMixin({runAsNonRoot: runAsNonRoot}), // The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. runAsUser(runAsUser):: __securityContextMixin({runAsUser: runAsUser}), // The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = __securityContextMixin({seLinuxOptions+: seLinuxOptions}), mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, // A list of groups applied to the first process run in each container, in addition to the container's primary GID. If unspecified, no groups will be added to any container. supplementalGroups(supplementalGroups):: if std.type(supplementalGroups) == "array" then __securityContextMixin({supplementalGroups+: supplementalGroups}) else __securityContextMixin({supplementalGroups+: [supplementalGroups]}), }, securityContextType:: hidden.core.v1.podSecurityContext, // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead. serviceAccount(serviceAccount):: __specMixin({serviceAccount: serviceAccount}), // ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ serviceAccountName(serviceAccountName):: __specMixin({serviceAccountName: serviceAccountName}), // If specified, the fully qualified Pod hostname will be "...svc.". If not specified, the pod will not have a domainname at all. subdomain(subdomain):: __specMixin({subdomain: subdomain}), // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds. terminationGracePeriodSeconds(terminationGracePeriodSeconds):: __specMixin({terminationGracePeriodSeconds: terminationGracePeriodSeconds}), // If specified, the pod's tolerations. tolerations(tolerations):: if std.type(tolerations) == "array" then __specMixin({tolerations+: tolerations}) else __specMixin({tolerations+: [tolerations]}), tolerationsType:: hidden.core.v1.toleration, // List of volumes that can be mounted by containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes volumes(volumes):: if std.type(volumes) == "array" then __specMixin({volumes+: volumes}) else __specMixin({volumes+: [volumes]}), volumesType:: hidden.core.v1.volume, }, specType:: hidden.core.v1.podSpec, }, templateType:: hidden.core.v1.podTemplateSpec, // An update strategy to replace existing DaemonSet pods with new pods. updateStrategy:: { local __updateStrategyMixin(updateStrategy) = {updateStrategy+: updateStrategy}, mixinInstance(updateStrategy):: __updateStrategyMixin(updateStrategy), // Rolling update config params. Present only if type = "RollingUpdate". rollingUpdate:: { local __rollingUpdateMixin(rollingUpdate) = __updateStrategyMixin({rollingUpdate+: rollingUpdate}), mixinInstance(rollingUpdate):: __rollingUpdateMixin(rollingUpdate), // The maximum number of DaemonSet pods that can be unavailable during the update. Value can be an absolute number (ex: 5) or a percentage of total number of DaemonSet pods at the start of the update (ex: 10%). Absolute number is calculated from percentage by rounding up. This cannot be 0. Default value is 1. Example: when this is set to 30%, at most 30% of the total number of nodes that should be running the daemon pod (i.e. status.desiredNumberScheduled) can have their pods stopped for an update at any given time. The update starts by stopping at most 30% of those DaemonSet pods and then brings up new DaemonSet pods in their place. Once the new pods are available, it then proceeds onto other DaemonSet pods, thus ensuring that at least 70% of original number of DaemonSet pods are available at all times during the update. maxUnavailable(maxUnavailable):: __rollingUpdateMixin({maxUnavailable: maxUnavailable}), }, rollingUpdateType:: hidden.extensions.v1beta1.rollingUpdateDaemonSet, // Type of daemon set update. Can be "RollingUpdate" or "OnDelete". Default is OnDelete. type(type):: __updateStrategyMixin({type: type}), }, updateStrategyType:: hidden.extensions.v1beta1.daemonSetUpdateStrategy, }, }, // DaemonSetStatus represents the current status of a daemon set. daemonSetStatus:: { new():: {}, // Count of hash collisions for the DaemonSet. The DaemonSet controller uses this field as a collision avoidance mechanism when it needs to create the name for the newest ControllerRevision. collisionCount(collisionCount):: {collisionCount: collisionCount}, // The number of nodes that are running at least 1 daemon pod and are supposed to run the daemon pod. More info: https://kubernetes.io/docs/concepts/workloads/controllers/daemonset/ currentNumberScheduled(currentNumberScheduled):: {currentNumberScheduled: currentNumberScheduled}, // The total number of nodes that should be running the daemon pod (including nodes correctly running the daemon pod). More info: https://kubernetes.io/docs/concepts/workloads/controllers/daemonset/ desiredNumberScheduled(desiredNumberScheduled):: {desiredNumberScheduled: desiredNumberScheduled}, // The number of nodes that should be running the daemon pod and have one or more of the daemon pod running and available (ready for at least spec.minReadySeconds) numberAvailable(numberAvailable):: {numberAvailable: numberAvailable}, // The number of nodes that are running the daemon pod, but are not supposed to run the daemon pod. More info: https://kubernetes.io/docs/concepts/workloads/controllers/daemonset/ numberMisscheduled(numberMisscheduled):: {numberMisscheduled: numberMisscheduled}, // The number of nodes that should be running the daemon pod and have one or more of the daemon pod running and ready. numberReady(numberReady):: {numberReady: numberReady}, // The number of nodes that should be running the daemon pod and have none of the daemon pod running and available (ready for at least spec.minReadySeconds) numberUnavailable(numberUnavailable):: {numberUnavailable: numberUnavailable}, // The most recent generation observed by the daemon set controller. observedGeneration(observedGeneration):: {observedGeneration: observedGeneration}, // The total number of nodes that are running updated daemon pod updatedNumberScheduled(updatedNumberScheduled):: {updatedNumberScheduled: updatedNumberScheduled}, mixin:: { }, }, // daemonSetUpdateStrategy:: { new():: {}, // Type of daemon set update. Can be "RollingUpdate" or "OnDelete". Default is OnDelete. type(type):: {type: type}, mixin:: { // Rolling update config params. Present only if type = "RollingUpdate". rollingUpdate:: { local __rollingUpdateMixin(rollingUpdate) = {rollingUpdate+: rollingUpdate}, mixinInstance(rollingUpdate):: __rollingUpdateMixin(rollingUpdate), // The maximum number of DaemonSet pods that can be unavailable during the update. Value can be an absolute number (ex: 5) or a percentage of total number of DaemonSet pods at the start of the update (ex: 10%). Absolute number is calculated from percentage by rounding up. This cannot be 0. Default value is 1. Example: when this is set to 30%, at most 30% of the total number of nodes that should be running the daemon pod (i.e. status.desiredNumberScheduled) can have their pods stopped for an update at any given time. The update starts by stopping at most 30% of those DaemonSet pods and then brings up new DaemonSet pods in their place. Once the new pods are available, it then proceeds onto other DaemonSet pods, thus ensuring that at least 70% of original number of DaemonSet pods are available at all times during the update. maxUnavailable(maxUnavailable):: __rollingUpdateMixin({maxUnavailable: maxUnavailable}), }, rollingUpdateType:: hidden.extensions.v1beta1.rollingUpdateDaemonSet, }, }, // DeploymentCondition describes the state of a deployment at a certain point. deploymentCondition:: { new():: {}, // A human readable message indicating details about the transition. message(message):: {message: message}, // The reason for the condition's last transition. reason(reason):: {reason: reason}, // Type of deployment condition. type(type):: {type: type}, mixin:: { // Last time the condition transitioned from one status to another. lastTransitionTime:: { local __lastTransitionTimeMixin(lastTransitionTime) = {lastTransitionTime+: lastTransitionTime}, mixinInstance(lastTransitionTime):: __lastTransitionTimeMixin(lastTransitionTime), }, lastTransitionTimeType:: hidden.meta.v1.time, // The last time this condition was updated. lastUpdateTime:: { local __lastUpdateTimeMixin(lastUpdateTime) = {lastUpdateTime+: lastUpdateTime}, mixinInstance(lastUpdateTime):: __lastUpdateTimeMixin(lastUpdateTime), }, lastUpdateTimeType:: hidden.meta.v1.time, }, }, // DeploymentSpec is the specification of the desired behavior of the Deployment. deploymentSpec:: { new():: {}, // Minimum number of seconds for which a newly created pod should be ready without any of its container crashing, for it to be considered available. Defaults to 0 (pod will be considered available as soon as it is ready) minReadySeconds(minReadySeconds):: {minReadySeconds: minReadySeconds}, // Indicates that the deployment is paused and will not be processed by the deployment controller. paused(paused):: {paused: paused}, // The maximum time in seconds for a deployment to make progress before it is considered to be failed. The deployment controller will continue to process failed deployments and a condition with a ProgressDeadlineExceeded reason will be surfaced in the deployment status. Once autoRollback is implemented, the deployment controller will automatically rollback failed deployments. Note that progress will not be estimated during the time a deployment is paused. This is not set by default. progressDeadlineSeconds(progressDeadlineSeconds):: {progressDeadlineSeconds: progressDeadlineSeconds}, // Number of desired pods. This is a pointer to distinguish between explicit zero and not specified. Defaults to 1. replicas(replicas):: {replicas: replicas}, // The number of old ReplicaSets to retain to allow rollback. This is a pointer to distinguish between explicit zero and not specified. revisionHistoryLimit(revisionHistoryLimit):: {revisionHistoryLimit: revisionHistoryLimit}, mixin:: { // The config this deployment is rolling back to. Will be cleared after rollback is done. rollbackTo:: { local __rollbackToMixin(rollbackTo) = {rollbackTo+: rollbackTo}, mixinInstance(rollbackTo):: __rollbackToMixin(rollbackTo), // The revision to rollback to. If set to 0, rollback to the last revision. revision(revision):: __rollbackToMixin({revision: revision}), }, rollbackToType:: hidden.extensions.v1beta1.rollbackConfig, // Label selector for pods. Existing ReplicaSets whose pods are selected by this will be the ones affected by this deployment. selector:: { local __selectorMixin(selector) = {selector+: selector}, mixinInstance(selector):: __selectorMixin(selector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __selectorMixin({matchExpressions+: matchExpressions}) else __selectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __selectorMixin({matchLabels+: matchLabels}), }, selectorType:: hidden.meta.v1.labelSelector, // The deployment strategy to use to replace existing pods with new ones. strategy:: { local __strategyMixin(strategy) = {strategy+: strategy}, mixinInstance(strategy):: __strategyMixin(strategy), // Rolling update config params. Present only if DeploymentStrategyType = RollingUpdate. rollingUpdate:: { local __rollingUpdateMixin(rollingUpdate) = __strategyMixin({rollingUpdate+: rollingUpdate}), mixinInstance(rollingUpdate):: __rollingUpdateMixin(rollingUpdate), // The maximum number of pods that can be scheduled above the desired number of pods. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). This can not be 0 if MaxUnavailable is 0. Absolute number is calculated from percentage by rounding up. By default, a value of 1 is used. Example: when this is set to 30%, the new RC can be scaled up immediately when the rolling update starts, such that the total number of old and new pods do not exceed 130% of desired pods. Once old pods have been killed, new RC can be scaled up further, ensuring that total number of pods running at any time during the update is atmost 130% of desired pods. maxSurge(maxSurge):: __rollingUpdateMixin({maxSurge: maxSurge}), // The maximum number of pods that can be unavailable during the update. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). Absolute number is calculated from percentage by rounding down. This can not be 0 if MaxSurge is 0. By default, a fixed value of 1 is used. Example: when this is set to 30%, the old RC can be scaled down to 70% of desired pods immediately when the rolling update starts. Once new pods are ready, old RC can be scaled down further, followed by scaling up the new RC, ensuring that the total number of pods available at all times during the update is at least 70% of desired pods. maxUnavailable(maxUnavailable):: __rollingUpdateMixin({maxUnavailable: maxUnavailable}), }, rollingUpdateType:: hidden.extensions.v1beta1.rollingUpdateDeployment, // Type of deployment. Can be "Recreate" or "RollingUpdate". Default is RollingUpdate. type(type):: __strategyMixin({type: type}), }, strategyType:: hidden.extensions.v1beta1.deploymentStrategy, // Template describes the pods that will be created. template:: { local __templateMixin(template) = {template+: template}, mixinInstance(template):: __templateMixin(template), // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = __templateMixin({metadata+: metadata}), mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = __templateMixin({spec+: spec}), mixinInstance(spec):: __specMixin(spec), // Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer. activeDeadlineSeconds(activeDeadlineSeconds):: __specMixin({activeDeadlineSeconds: activeDeadlineSeconds}), // If specified, the pod's scheduling constraints affinity:: { local __affinityMixin(affinity) = __specMixin({affinity+: affinity}), mixinInstance(affinity):: __affinityMixin(affinity), // Describes node affinity scheduling rules for the pod. nodeAffinity:: { local __nodeAffinityMixin(nodeAffinity) = __affinityMixin({nodeAffinity+: nodeAffinity}), mixinInstance(nodeAffinity):: __nodeAffinityMixin(nodeAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.preferredSchedulingTerm, // If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node. requiredDuringSchedulingIgnoredDuringExecution:: { local __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution) = __nodeAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}), mixinInstance(requiredDuringSchedulingIgnoredDuringExecution):: __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution), // Required. A list of node selector terms. The terms are ORed. nodeSelectorTerms(nodeSelectorTerms):: if std.type(nodeSelectorTerms) == "array" then __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: nodeSelectorTerms}) else __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: [nodeSelectorTerms]}), nodeSelectorTermsType:: hidden.core.v1.nodeSelectorTerm, }, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.nodeSelector, }, nodeAffinityType:: hidden.core.v1.nodeAffinity, // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)). podAffinity:: { local __podAffinityMixin(podAffinity) = __affinityMixin({podAffinity+: podAffinity}), mixinInstance(podAffinity):: __podAffinityMixin(podAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAffinityType:: hidden.core.v1.podAffinity, // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)). podAntiAffinity:: { local __podAntiAffinityMixin(podAntiAffinity) = __affinityMixin({podAntiAffinity+: podAntiAffinity}), mixinInstance(podAntiAffinity):: __podAntiAffinityMixin(podAntiAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAntiAffinityType:: hidden.core.v1.podAntiAffinity, }, affinityType:: hidden.core.v1.affinity, // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted. automountServiceAccountToken(automountServiceAccountToken):: __specMixin({automountServiceAccountToken: automountServiceAccountToken}), // List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated. containers(containers):: if std.type(containers) == "array" then __specMixin({containers+: containers}) else __specMixin({containers+: [containers]}), containersType:: hidden.core.v1.container, // Set DNS policy for containers within the pod. One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. Defaults to "ClusterFirst". To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. dnsPolicy(dnsPolicy):: __specMixin({dnsPolicy: dnsPolicy}), // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts file if specified. This is only valid for non-hostNetwork pods. hostAliases(hostAliases):: if std.type(hostAliases) == "array" then __specMixin({hostAliases+: hostAliases}) else __specMixin({hostAliases+: [hostAliases]}), hostAliasesType:: hidden.core.v1.hostAlias, // Use the host's ipc namespace. Optional: Default to false. hostIpc(hostIpc):: __specMixin({hostIPC: hostIpc}), // Host networking requested for this pod. Use the host's network namespace. If this option is set, the ports that will be used must be specified. Default to false. hostNetwork(hostNetwork):: __specMixin({hostNetwork: hostNetwork}), // Use the host's pid namespace. Optional: Default to false. hostPid(hostPid):: __specMixin({hostPID: hostPid}), // Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value. hostname(hostname):: __specMixin({hostname: hostname}), // 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. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod imagePullSecrets(imagePullSecrets):: if std.type(imagePullSecrets) == "array" then __specMixin({imagePullSecrets+: imagePullSecrets}) else __specMixin({imagePullSecrets+: [imagePullSecrets]}), imagePullSecretsType:: hidden.core.v1.localObjectReference, // List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ initContainers(initContainers):: if std.type(initContainers) == "array" then __specMixin({initContainers+: initContainers}) else __specMixin({initContainers+: [initContainers]}), initContainersType:: hidden.core.v1.container, // NodeName is a request to schedule this pod onto a specific node. If it is non-empty, the scheduler simply schedules this pod onto that node, assuming that it fits resource requirements. nodeName(nodeName):: __specMixin({nodeName: nodeName}), // NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ nodeSelector(nodeSelector):: __specMixin({nodeSelector+: nodeSelector}), // Restart policy for all containers within the pod. One of Always, OnFailure, Never. Default to Always. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy restartPolicy(restartPolicy):: __specMixin({restartPolicy: restartPolicy}), // If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler. schedulerName(schedulerName):: __specMixin({schedulerName: schedulerName}), // SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field. securityContext:: { local __securityContextMixin(securityContext) = __specMixin({securityContext+: securityContext}), mixinInstance(securityContext):: __securityContextMixin(securityContext), // A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod: // // 1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw---- // // If unset, the Kubelet will not modify the ownership and permissions of any volume. fsGroup(fsGroup):: __securityContextMixin({fsGroup: fsGroup}), // Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsNonRoot(runAsNonRoot):: __securityContextMixin({runAsNonRoot: runAsNonRoot}), // The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. runAsUser(runAsUser):: __securityContextMixin({runAsUser: runAsUser}), // The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = __securityContextMixin({seLinuxOptions+: seLinuxOptions}), mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, // A list of groups applied to the first process run in each container, in addition to the container's primary GID. If unspecified, no groups will be added to any container. supplementalGroups(supplementalGroups):: if std.type(supplementalGroups) == "array" then __securityContextMixin({supplementalGroups+: supplementalGroups}) else __securityContextMixin({supplementalGroups+: [supplementalGroups]}), }, securityContextType:: hidden.core.v1.podSecurityContext, // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead. serviceAccount(serviceAccount):: __specMixin({serviceAccount: serviceAccount}), // ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ serviceAccountName(serviceAccountName):: __specMixin({serviceAccountName: serviceAccountName}), // If specified, the fully qualified Pod hostname will be "...svc.". If not specified, the pod will not have a domainname at all. subdomain(subdomain):: __specMixin({subdomain: subdomain}), // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds. terminationGracePeriodSeconds(terminationGracePeriodSeconds):: __specMixin({terminationGracePeriodSeconds: terminationGracePeriodSeconds}), // If specified, the pod's tolerations. tolerations(tolerations):: if std.type(tolerations) == "array" then __specMixin({tolerations+: tolerations}) else __specMixin({tolerations+: [tolerations]}), tolerationsType:: hidden.core.v1.toleration, // List of volumes that can be mounted by containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes volumes(volumes):: if std.type(volumes) == "array" then __specMixin({volumes+: volumes}) else __specMixin({volumes+: [volumes]}), volumesType:: hidden.core.v1.volume, }, specType:: hidden.core.v1.podSpec, }, templateType:: hidden.core.v1.podTemplateSpec, }, }, // DeploymentStatus is the most recently observed status of the Deployment. deploymentStatus:: { new():: {}, // Total number of available pods (ready for at least minReadySeconds) targeted by this deployment. availableReplicas(availableReplicas):: {availableReplicas: availableReplicas}, // Count of hash collisions for the Deployment. The Deployment controller uses this field as a collision avoidance mechanism when it needs to create the name for the newest ReplicaSet. collisionCount(collisionCount):: {collisionCount: collisionCount}, // Represents the latest available observations of a deployment's current state. conditions(conditions):: if std.type(conditions) == "array" then {conditions+: conditions} else {conditions+: [conditions]}, conditionsType:: hidden.extensions.v1beta1.deploymentCondition, // The generation observed by the deployment controller. observedGeneration(observedGeneration):: {observedGeneration: observedGeneration}, // Total number of ready pods targeted by this deployment. readyReplicas(readyReplicas):: {readyReplicas: readyReplicas}, // Total number of non-terminated pods targeted by this deployment (their labels match the selector). replicas(replicas):: {replicas: replicas}, // Total number of unavailable pods targeted by this deployment. unavailableReplicas(unavailableReplicas):: {unavailableReplicas: unavailableReplicas}, // Total number of non-terminated pods targeted by this deployment that have the desired template spec. updatedReplicas(updatedReplicas):: {updatedReplicas: updatedReplicas}, mixin:: { }, }, // DeploymentStrategy describes how to replace existing pods with new ones. deploymentStrategy:: { new():: {}, // Type of deployment. Can be "Recreate" or "RollingUpdate". Default is RollingUpdate. type(type):: {type: type}, mixin:: { // Rolling update config params. Present only if DeploymentStrategyType = RollingUpdate. rollingUpdate:: { local __rollingUpdateMixin(rollingUpdate) = {rollingUpdate+: rollingUpdate}, mixinInstance(rollingUpdate):: __rollingUpdateMixin(rollingUpdate), // The maximum number of pods that can be scheduled above the desired number of pods. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). This can not be 0 if MaxUnavailable is 0. Absolute number is calculated from percentage by rounding up. By default, a value of 1 is used. Example: when this is set to 30%, the new RC can be scaled up immediately when the rolling update starts, such that the total number of old and new pods do not exceed 130% of desired pods. Once old pods have been killed, new RC can be scaled up further, ensuring that total number of pods running at any time during the update is atmost 130% of desired pods. maxSurge(maxSurge):: __rollingUpdateMixin({maxSurge: maxSurge}), // The maximum number of pods that can be unavailable during the update. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). Absolute number is calculated from percentage by rounding down. This can not be 0 if MaxSurge is 0. By default, a fixed value of 1 is used. Example: when this is set to 30%, the old RC can be scaled down to 70% of desired pods immediately when the rolling update starts. Once new pods are ready, old RC can be scaled down further, followed by scaling up the new RC, ensuring that the total number of pods available at all times during the update is at least 70% of desired pods. maxUnavailable(maxUnavailable):: __rollingUpdateMixin({maxUnavailable: maxUnavailable}), }, rollingUpdateType:: hidden.extensions.v1beta1.rollingUpdateDeployment, }, }, // FSGroupStrategyOptions defines the strategy type and options used to create the strategy. fsGroupStrategyOptions:: { new():: {}, // Ranges are the allowed ranges of fs groups. If you would like to force a single fs group then supply a single range with the same start and end. ranges(ranges):: if std.type(ranges) == "array" then {ranges+: ranges} else {ranges+: [ranges]}, rangesType:: hidden.extensions.v1beta1.idRange, // Rule is the strategy that will dictate what FSGroup is used in the SecurityContext. rule(rule):: {rule: rule}, mixin:: { }, }, // HTTPIngressPath associates a path regex with a backend. Incoming urls matching the path are forwarded to the backend. httpIngressPath:: { new():: {}, // Path is an extended POSIX regex as defined by IEEE Std 1003.1, (i.e this follows the egrep/unix syntax, not the perl syntax) matched against the path of an incoming request. Currently it can contain characters disallowed from the conventional "path" part of a URL as defined by RFC 3986. Paths must begin with a '/'. If unspecified, the path defaults to a catch all sending traffic to the backend. path(path):: {path: path}, mixin:: { // Backend defines the referenced service endpoint to which the traffic will be forwarded to. backend:: { local __backendMixin(backend) = {backend+: backend}, mixinInstance(backend):: __backendMixin(backend), // Specifies the name of the referenced service. serviceName(serviceName):: __backendMixin({serviceName: serviceName}), // Specifies the port of the referenced service. servicePort(servicePort):: __backendMixin({servicePort: servicePort}), }, backendType:: hidden.extensions.v1beta1.ingressBackend, }, }, // HTTPIngressRuleValue is a list of http selectors pointing to backends. In the example: http:///? -> backend where where parts of the url correspond to RFC 3986, this resource will be used to match against everything after the last '/' and before the first '?' or '#'. httpIngressRuleValue:: { new():: {}, // A collection of paths that map requests to backends. paths(paths):: if std.type(paths) == "array" then {paths+: paths} else {paths+: [paths]}, pathsType:: hidden.extensions.v1beta1.httpIngressPath, mixin:: { }, }, // Host Port Range defines a range of host ports that will be enabled by a policy for pods to use. It requires both the start and end to be defined. hostPortRange:: { new():: {}, // max is the end of the range, inclusive. max(max):: {max: max}, // min is the start of the range, inclusive. min(min):: {min: min}, mixin:: { }, }, // ID Range provides a min/max of an allowed range of IDs. idRange:: { new():: {}, // Max is the end of the range, inclusive. max(max):: {max: max}, // Min is the start of the range, inclusive. min(min):: {min: min}, mixin:: { }, }, // IngressBackend describes all endpoints for a given service and port. ingressBackend:: { new():: {}, // Specifies the name of the referenced service. serviceName(serviceName):: {serviceName: serviceName}, // Specifies the port of the referenced service. servicePort(servicePort):: {servicePort: servicePort}, mixin:: { }, }, // IngressRule represents the rules mapping the paths under a specified host to the related backend services. Incoming requests are first evaluated for a host match, then routed to the backend associated with the matching IngressRuleValue. ingressRule:: { new():: {}, // Host is the fully qualified domain name of a network host, as defined by RFC 3986. Note the following deviations from the "host" part of the URI as defined in the RFC: 1. IPs are not allowed. Currently an IngressRuleValue can only apply to the // IP in the Spec of the parent Ingress. // 2. The `:` delimiter is not respected because ports are not allowed. // Currently the port of an Ingress is implicitly :80 for http and // :443 for https. // Both these may change in the future. Incoming requests are matched against the host before the IngressRuleValue. If the host is unspecified, the Ingress routes all traffic based on the specified IngressRuleValue. host(host):: {host: host}, mixin:: { // http:: { local __httpMixin(http) = {http+: http}, mixinInstance(http):: __httpMixin(http), // A collection of paths that map requests to backends. paths(paths):: if std.type(paths) == "array" then __httpMixin({paths+: paths}) else __httpMixin({paths+: [paths]}), pathsType:: hidden.extensions.v1beta1.httpIngressPath, }, httpType:: hidden.extensions.v1beta1.httpIngressRuleValue, }, }, // IngressSpec describes the Ingress the user wishes to exist. ingressSpec:: { new():: {}, // A list of host rules used to configure the Ingress. If unspecified, or no rule matches, all traffic is sent to the default backend. rules(rules):: if std.type(rules) == "array" then {rules+: rules} else {rules+: [rules]}, rulesType:: hidden.extensions.v1beta1.ingressRule, // TLS configuration. Currently the Ingress only supports a single TLS port, 443. If multiple members of this list specify different hosts, they will be multiplexed on the same port according to the hostname specified through the SNI TLS extension, if the ingress controller fulfilling the ingress supports SNI. tls(tls):: if std.type(tls) == "array" then {tls+: tls} else {tls+: [tls]}, tlsType:: hidden.extensions.v1beta1.ingressTls, mixin:: { // A default backend capable of servicing requests that don't match any rule. At least one of 'backend' or 'rules' must be specified. This field is optional to allow the loadbalancer controller or defaulting logic to specify a global default. backend:: { local __backendMixin(backend) = {backend+: backend}, mixinInstance(backend):: __backendMixin(backend), // Specifies the name of the referenced service. serviceName(serviceName):: __backendMixin({serviceName: serviceName}), // Specifies the port of the referenced service. servicePort(servicePort):: __backendMixin({servicePort: servicePort}), }, backendType:: hidden.extensions.v1beta1.ingressBackend, }, }, // IngressStatus describe the current state of the Ingress. ingressStatus:: { new():: {}, mixin:: { // LoadBalancer contains the current status of the load-balancer. loadBalancer:: { local __loadBalancerMixin(loadBalancer) = {loadBalancer+: loadBalancer}, mixinInstance(loadBalancer):: __loadBalancerMixin(loadBalancer), // Ingress is a list containing ingress points for the load-balancer. Traffic intended for the service should be sent to these ingress points. ingress(ingress):: if std.type(ingress) == "array" then __loadBalancerMixin({ingress+: ingress}) else __loadBalancerMixin({ingress+: [ingress]}), ingressType:: hidden.core.v1.loadBalancerIngress, }, loadBalancerType:: hidden.core.v1.loadBalancerStatus, }, }, // IngressTLS describes the transport layer security associated with an Ingress. ingressTls:: { new():: {}, // Hosts are a list of hosts included in the TLS certificate. The values in this list must match the name/s used in the tlsSecret. Defaults to the wildcard host setting for the loadbalancer controller fulfilling this Ingress, if left unspecified. hosts(hosts):: if std.type(hosts) == "array" then {hosts+: hosts} else {hosts+: [hosts]}, // SecretName is the name of the secret used to terminate SSL traffic on 443. Field is left optional to allow SSL routing based on SNI hostname alone. If the SNI host in a listener conflicts with the "Host" header field used by an IngressRule, the SNI host is used for termination and value of the Host header is used for routing. secretName(secretName):: {secretName: secretName}, mixin:: { }, }, // This NetworkPolicyIngressRule matches traffic if and only if the traffic matches both ports AND from. networkPolicyIngressRule:: { new():: {}, // List of sources which should be able to access the pods selected for this rule. Items in this list are combined using a logical OR operation. If this field is empty or missing, this rule matches all sources (traffic not restricted by source). If this field is present and contains at least on item, this rule allows traffic only if the traffic matches at least one item in the from list. from(from):: if std.type(from) == "array" then {from+: from} else {from+: [from]}, fromType:: hidden.extensions.v1beta1.networkPolicyPeer, // List of ports which should be made accessible on the pods selected for this rule. Each item in this list is combined using a logical OR. If this field is empty or missing, this rule matches all ports (traffic not restricted by port). If this field is present and contains at least one item, then this rule allows traffic only if the traffic matches at least one port in the list. ports(ports):: if std.type(ports) == "array" then {ports+: ports} else {ports+: [ports]}, portsType:: hidden.extensions.v1beta1.networkPolicyPort, mixin:: { }, }, // networkPolicyPeer:: { new():: {}, mixin:: { // Selects Namespaces using cluster scoped-labels. This matches all pods in all namespaces selected by this label selector. This field follows standard label selector semantics. If present but empty, this selector selects all namespaces. namespaceSelector:: { local __namespaceSelectorMixin(namespaceSelector) = {namespaceSelector+: namespaceSelector}, mixinInstance(namespaceSelector):: __namespaceSelectorMixin(namespaceSelector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __namespaceSelectorMixin({matchExpressions+: matchExpressions}) else __namespaceSelectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __namespaceSelectorMixin({matchLabels+: matchLabels}), }, namespaceSelectorType:: hidden.meta.v1.labelSelector, // This is a label selector which selects Pods in this namespace. This field follows standard label selector semantics. If present but empty, this selector selects all pods in this namespace. podSelector:: { local __podSelectorMixin(podSelector) = {podSelector+: podSelector}, mixinInstance(podSelector):: __podSelectorMixin(podSelector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __podSelectorMixin({matchExpressions+: matchExpressions}) else __podSelectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __podSelectorMixin({matchLabels+: matchLabels}), }, podSelectorType:: hidden.meta.v1.labelSelector, }, }, // networkPolicyPort:: { new():: {}, // If specified, the port on the given protocol. This can either be a numerical or named port on a pod. If this field is not provided, this matches all port names and numbers. If present, only traffic on the specified protocol AND port will be matched. port(port):: {port: port}, // Optional. The protocol (TCP or UDP) which traffic must match. If not specified, this field defaults to TCP. protocol(protocol):: {protocol: protocol}, mixin:: { }, }, // networkPolicySpec:: { new():: {}, // List of ingress rules to be applied to the selected pods. Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod OR if the traffic source is the pod's local node, OR if the traffic matches at least one ingress rule across all of the NetworkPolicy objects whose podSelector matches the pod. If this field is empty then this NetworkPolicy does not allow any traffic (and serves solely to ensure that the pods it selects are isolated by default). ingress(ingress):: if std.type(ingress) == "array" then {ingress+: ingress} else {ingress+: [ingress]}, ingressType:: hidden.extensions.v1beta1.networkPolicyIngressRule, mixin:: { // Selects the pods to which this NetworkPolicy object applies. The array of ingress rules is applied to any pods selected by this field. Multiple network policies can select the same set of pods. In this case, the ingress rules for each are combined additively. This field is NOT optional and follows standard label selector semantics. An empty podSelector matches all pods in this namespace. podSelector:: { local __podSelectorMixin(podSelector) = {podSelector+: podSelector}, mixinInstance(podSelector):: __podSelectorMixin(podSelector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __podSelectorMixin({matchExpressions+: matchExpressions}) else __podSelectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __podSelectorMixin({matchLabels+: matchLabels}), }, podSelectorType:: hidden.meta.v1.labelSelector, }, }, // Pod Security Policy Spec defines the policy enforced. podSecurityPolicySpec:: { new():: {}, // AllowedCapabilities is a list of capabilities that can be requested to add to the container. Capabilities in this field may be added at the pod author's discretion. You must not list a capability in both AllowedCapabilities and RequiredDropCapabilities. allowedCapabilities(allowedCapabilities):: if std.type(allowedCapabilities) == "array" then {allowedCapabilities+: allowedCapabilities} else {allowedCapabilities+: [allowedCapabilities]}, // DefaultAddCapabilities is the default set of capabilities that will be added to the container unless the pod spec specifically drops the capability. You may not list a capabiility in both DefaultAddCapabilities and RequiredDropCapabilities. defaultAddCapabilities(defaultAddCapabilities):: if std.type(defaultAddCapabilities) == "array" then {defaultAddCapabilities+: defaultAddCapabilities} else {defaultAddCapabilities+: [defaultAddCapabilities]}, // hostIPC determines if the policy allows the use of HostIPC in the pod spec. hostIpc(hostIpc):: {hostIPC: hostIpc}, // hostNetwork determines if the policy allows the use of HostNetwork in the pod spec. hostNetwork(hostNetwork):: {hostNetwork: hostNetwork}, // hostPID determines if the policy allows the use of HostPID in the pod spec. hostPid(hostPid):: {hostPID: hostPid}, // hostPorts determines which host port ranges are allowed to be exposed. hostPorts(hostPorts):: if std.type(hostPorts) == "array" then {hostPorts+: hostPorts} else {hostPorts+: [hostPorts]}, hostPortsType:: hidden.extensions.v1beta1.hostPortRange, // privileged determines if a pod can request to be run as privileged. privileged(privileged):: {privileged: privileged}, // ReadOnlyRootFilesystem when set to true will force containers to run with a read only root file system. If the container specifically requests to run with a non-read only root file system the PSP should deny the pod. If set to false the container may run with a read only root file system if it wishes but it will not be forced to. readOnlyRootFilesystem(readOnlyRootFilesystem):: {readOnlyRootFilesystem: readOnlyRootFilesystem}, // RequiredDropCapabilities are the capabilities that will be dropped from the container. These are required to be dropped and cannot be added. requiredDropCapabilities(requiredDropCapabilities):: if std.type(requiredDropCapabilities) == "array" then {requiredDropCapabilities+: requiredDropCapabilities} else {requiredDropCapabilities+: [requiredDropCapabilities]}, // volumes is a white list of allowed volume plugins. Empty indicates that all plugins may be used. volumes(volumes):: if std.type(volumes) == "array" then {volumes+: volumes} else {volumes+: [volumes]}, mixin:: { // FSGroup is the strategy that will dictate what fs group is used by the SecurityContext. fsGroup:: { local __fsGroupMixin(fsGroup) = {fsGroup+: fsGroup}, mixinInstance(fsGroup):: __fsGroupMixin(fsGroup), // Ranges are the allowed ranges of fs groups. If you would like to force a single fs group then supply a single range with the same start and end. ranges(ranges):: if std.type(ranges) == "array" then __fsGroupMixin({ranges+: ranges}) else __fsGroupMixin({ranges+: [ranges]}), rangesType:: hidden.extensions.v1beta1.idRange, // Rule is the strategy that will dictate what FSGroup is used in the SecurityContext. rule(rule):: __fsGroupMixin({rule: rule}), }, fsGroupType:: hidden.extensions.v1beta1.fsGroupStrategyOptions, // runAsUser is the strategy that will dictate the allowable RunAsUser values that may be set. runAsUser:: { local __runAsUserMixin(runAsUser) = {runAsUser+: runAsUser}, mixinInstance(runAsUser):: __runAsUserMixin(runAsUser), // Ranges are the allowed ranges of uids that may be used. ranges(ranges):: if std.type(ranges) == "array" then __runAsUserMixin({ranges+: ranges}) else __runAsUserMixin({ranges+: [ranges]}), rangesType:: hidden.extensions.v1beta1.idRange, // Rule is the strategy that will dictate the allowable RunAsUser values that may be set. rule(rule):: __runAsUserMixin({rule: rule}), }, runAsUserType:: hidden.extensions.v1beta1.runAsUserStrategyOptions, // seLinux is the strategy that will dictate the allowable labels that may be set. seLinux:: { local __seLinuxMixin(seLinux) = {seLinux+: seLinux}, mixinInstance(seLinux):: __seLinuxMixin(seLinux), // type is the strategy that will dictate the allowable labels that may be set. rule(rule):: __seLinuxMixin({rule: rule}), // seLinuxOptions required to run as; required for MustRunAs More info: https://git.k8s.io/community/contributors/design-proposals/security_context.md seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = __seLinuxMixin({seLinuxOptions+: seLinuxOptions}), mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, }, seLinuxType:: hidden.extensions.v1beta1.seLinuxStrategyOptions, // SupplementalGroups is the strategy that will dictate what supplemental groups are used by the SecurityContext. supplementalGroups:: { local __supplementalGroupsMixin(supplementalGroups) = {supplementalGroups+: supplementalGroups}, mixinInstance(supplementalGroups):: __supplementalGroupsMixin(supplementalGroups), // Ranges are the allowed ranges of supplemental groups. If you would like to force a single supplemental group then supply a single range with the same start and end. ranges(ranges):: if std.type(ranges) == "array" then __supplementalGroupsMixin({ranges+: ranges}) else __supplementalGroupsMixin({ranges+: [ranges]}), rangesType:: hidden.extensions.v1beta1.idRange, // Rule is the strategy that will dictate what supplemental groups is used in the SecurityContext. rule(rule):: __supplementalGroupsMixin({rule: rule}), }, supplementalGroupsType:: hidden.extensions.v1beta1.supplementalGroupsStrategyOptions, }, }, // ReplicaSetCondition describes the state of a replica set at a certain point. replicaSetCondition:: { new():: {}, // A human readable message indicating details about the transition. message(message):: {message: message}, // The reason for the condition's last transition. reason(reason):: {reason: reason}, // Type of replica set condition. type(type):: {type: type}, mixin:: { // The last time the condition transitioned from one status to another. lastTransitionTime:: { local __lastTransitionTimeMixin(lastTransitionTime) = {lastTransitionTime+: lastTransitionTime}, mixinInstance(lastTransitionTime):: __lastTransitionTimeMixin(lastTransitionTime), }, lastTransitionTimeType:: hidden.meta.v1.time, }, }, // ReplicaSetSpec is the specification of a ReplicaSet. replicaSetSpec:: { new():: {}, // Minimum number of seconds for which a newly created pod should be ready without any of its container crashing, for it to be considered available. Defaults to 0 (pod will be considered available as soon as it is ready) minReadySeconds(minReadySeconds):: {minReadySeconds: minReadySeconds}, // Replicas is the number of desired replicas. This is a pointer to distinguish between explicit zero and unspecified. Defaults to 1. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller/#what-is-a-replicationcontroller replicas(replicas):: {replicas: replicas}, mixin:: { // Selector is a label query over pods that should match the replica count. If the selector is empty, it is defaulted to the labels present on the pod template. Label keys and values that must match in order to be controlled by this replica set. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors selector:: { local __selectorMixin(selector) = {selector+: selector}, mixinInstance(selector):: __selectorMixin(selector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __selectorMixin({matchExpressions+: matchExpressions}) else __selectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __selectorMixin({matchLabels+: matchLabels}), }, selectorType:: hidden.meta.v1.labelSelector, // Template is the object that describes the pod that will be created if insufficient replicas are detected. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#pod-template template:: { local __templateMixin(template) = {template+: template}, mixinInstance(template):: __templateMixin(template), // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata metadata:: { local __metadataMixin(metadata) = __templateMixin({metadata+: metadata}), mixinInstance(metadata):: __metadataMixin(metadata), // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: __metadataMixin({annotations+: annotations}), // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: __metadataMixin({clusterName: clusterName}), // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: __metadataMixin({deletionGracePeriodSeconds: deletionGracePeriodSeconds}), // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then __metadataMixin({finalizers+: finalizers}) else __metadataMixin({finalizers+: [finalizers]}), // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: __metadataMixin({generateName: generateName}), // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = __metadataMixin({initializers+: initializers}), mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: __metadataMixin({labels+: labels}), // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: __metadataMixin({name: name}), // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: __metadataMixin({namespace: namespace}), }, metadataType:: hidden.meta.v1.objectMeta, // Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status spec:: { local __specMixin(spec) = __templateMixin({spec+: spec}), mixinInstance(spec):: __specMixin(spec), // Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer. activeDeadlineSeconds(activeDeadlineSeconds):: __specMixin({activeDeadlineSeconds: activeDeadlineSeconds}), // If specified, the pod's scheduling constraints affinity:: { local __affinityMixin(affinity) = __specMixin({affinity+: affinity}), mixinInstance(affinity):: __affinityMixin(affinity), // Describes node affinity scheduling rules for the pod. nodeAffinity:: { local __nodeAffinityMixin(nodeAffinity) = __affinityMixin({nodeAffinity+: nodeAffinity}), mixinInstance(nodeAffinity):: __nodeAffinityMixin(nodeAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __nodeAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.preferredSchedulingTerm, // If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node. requiredDuringSchedulingIgnoredDuringExecution:: { local __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution) = __nodeAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}), mixinInstance(requiredDuringSchedulingIgnoredDuringExecution):: __requiredDuringSchedulingIgnoredDuringExecutionMixin(requiredDuringSchedulingIgnoredDuringExecution), // Required. A list of node selector terms. The terms are ORed. nodeSelectorTerms(nodeSelectorTerms):: if std.type(nodeSelectorTerms) == "array" then __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: nodeSelectorTerms}) else __requiredDuringSchedulingIgnoredDuringExecutionMixin({nodeSelectorTerms+: [nodeSelectorTerms]}), nodeSelectorTermsType:: hidden.core.v1.nodeSelectorTerm, }, requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.nodeSelector, }, nodeAffinityType:: hidden.core.v1.nodeAffinity, // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)). podAffinity:: { local __podAffinityMixin(podAffinity) = __affinityMixin({podAffinity+: podAffinity}), mixinInstance(podAffinity):: __podAffinityMixin(podAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAffinityType:: hidden.core.v1.podAffinity, // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)). podAntiAffinity:: { local __podAntiAffinityMixin(podAntiAffinity) = __affinityMixin({podAntiAffinity+: podAntiAffinity}), mixinInstance(podAntiAffinity):: __podAntiAffinityMixin(podAntiAffinity), // The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred. preferredDuringSchedulingIgnoredDuringExecution(preferredDuringSchedulingIgnoredDuringExecution):: if std.type(preferredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: preferredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({preferredDuringSchedulingIgnoredDuringExecution+: [preferredDuringSchedulingIgnoredDuringExecution]}), preferredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.weightedPodAffinityTerm, // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system will try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied. requiredDuringSchedulingIgnoredDuringExecution(requiredDuringSchedulingIgnoredDuringExecution):: if std.type(requiredDuringSchedulingIgnoredDuringExecution) == "array" then __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: requiredDuringSchedulingIgnoredDuringExecution}) else __podAntiAffinityMixin({requiredDuringSchedulingIgnoredDuringExecution+: [requiredDuringSchedulingIgnoredDuringExecution]}), requiredDuringSchedulingIgnoredDuringExecutionType:: hidden.core.v1.podAffinityTerm, }, podAntiAffinityType:: hidden.core.v1.podAntiAffinity, }, affinityType:: hidden.core.v1.affinity, // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted. automountServiceAccountToken(automountServiceAccountToken):: __specMixin({automountServiceAccountToken: automountServiceAccountToken}), // List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated. containers(containers):: if std.type(containers) == "array" then __specMixin({containers+: containers}) else __specMixin({containers+: [containers]}), containersType:: hidden.core.v1.container, // Set DNS policy for containers within the pod. One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. Defaults to "ClusterFirst". To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. dnsPolicy(dnsPolicy):: __specMixin({dnsPolicy: dnsPolicy}), // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts file if specified. This is only valid for non-hostNetwork pods. hostAliases(hostAliases):: if std.type(hostAliases) == "array" then __specMixin({hostAliases+: hostAliases}) else __specMixin({hostAliases+: [hostAliases]}), hostAliasesType:: hidden.core.v1.hostAlias, // Use the host's ipc namespace. Optional: Default to false. hostIpc(hostIpc):: __specMixin({hostIPC: hostIpc}), // Host networking requested for this pod. Use the host's network namespace. If this option is set, the ports that will be used must be specified. Default to false. hostNetwork(hostNetwork):: __specMixin({hostNetwork: hostNetwork}), // Use the host's pid namespace. Optional: Default to false. hostPid(hostPid):: __specMixin({hostPID: hostPid}), // Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value. hostname(hostname):: __specMixin({hostname: hostname}), // 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. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod imagePullSecrets(imagePullSecrets):: if std.type(imagePullSecrets) == "array" then __specMixin({imagePullSecrets+: imagePullSecrets}) else __specMixin({imagePullSecrets+: [imagePullSecrets]}), imagePullSecretsType:: hidden.core.v1.localObjectReference, // List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ initContainers(initContainers):: if std.type(initContainers) == "array" then __specMixin({initContainers+: initContainers}) else __specMixin({initContainers+: [initContainers]}), initContainersType:: hidden.core.v1.container, // NodeName is a request to schedule this pod onto a specific node. If it is non-empty, the scheduler simply schedules this pod onto that node, assuming that it fits resource requirements. nodeName(nodeName):: __specMixin({nodeName: nodeName}), // NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ nodeSelector(nodeSelector):: __specMixin({nodeSelector+: nodeSelector}), // Restart policy for all containers within the pod. One of Always, OnFailure, Never. Default to Always. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy restartPolicy(restartPolicy):: __specMixin({restartPolicy: restartPolicy}), // If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler. schedulerName(schedulerName):: __specMixin({schedulerName: schedulerName}), // SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field. securityContext:: { local __securityContextMixin(securityContext) = __specMixin({securityContext+: securityContext}), mixinInstance(securityContext):: __securityContextMixin(securityContext), // A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod: // // 1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw---- // // If unset, the Kubelet will not modify the ownership and permissions of any volume. fsGroup(fsGroup):: __securityContextMixin({fsGroup: fsGroup}), // Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. runAsNonRoot(runAsNonRoot):: __securityContextMixin({runAsNonRoot: runAsNonRoot}), // The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. runAsUser(runAsUser):: __securityContextMixin({runAsUser: runAsUser}), // The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = __securityContextMixin({seLinuxOptions+: seLinuxOptions}), mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, // A list of groups applied to the first process run in each container, in addition to the container's primary GID. If unspecified, no groups will be added to any container. supplementalGroups(supplementalGroups):: if std.type(supplementalGroups) == "array" then __securityContextMixin({supplementalGroups+: supplementalGroups}) else __securityContextMixin({supplementalGroups+: [supplementalGroups]}), }, securityContextType:: hidden.core.v1.podSecurityContext, // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead. serviceAccount(serviceAccount):: __specMixin({serviceAccount: serviceAccount}), // ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ serviceAccountName(serviceAccountName):: __specMixin({serviceAccountName: serviceAccountName}), // If specified, the fully qualified Pod hostname will be "...svc.". If not specified, the pod will not have a domainname at all. subdomain(subdomain):: __specMixin({subdomain: subdomain}), // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds. terminationGracePeriodSeconds(terminationGracePeriodSeconds):: __specMixin({terminationGracePeriodSeconds: terminationGracePeriodSeconds}), // If specified, the pod's tolerations. tolerations(tolerations):: if std.type(tolerations) == "array" then __specMixin({tolerations+: tolerations}) else __specMixin({tolerations+: [tolerations]}), tolerationsType:: hidden.core.v1.toleration, // List of volumes that can be mounted by containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes volumes(volumes):: if std.type(volumes) == "array" then __specMixin({volumes+: volumes}) else __specMixin({volumes+: [volumes]}), volumesType:: hidden.core.v1.volume, }, specType:: hidden.core.v1.podSpec, }, templateType:: hidden.core.v1.podTemplateSpec, }, }, // ReplicaSetStatus represents the current status of a ReplicaSet. replicaSetStatus:: { new():: {}, // The number of available replicas (ready for at least minReadySeconds) for this replica set. availableReplicas(availableReplicas):: {availableReplicas: availableReplicas}, // Represents the latest available observations of a replica set's current state. conditions(conditions):: if std.type(conditions) == "array" then {conditions+: conditions} else {conditions+: [conditions]}, conditionsType:: hidden.extensions.v1beta1.replicaSetCondition, // The number of pods that have labels matching the labels of the pod template of the replicaset. fullyLabeledReplicas(fullyLabeledReplicas):: {fullyLabeledReplicas: fullyLabeledReplicas}, // ObservedGeneration reflects the generation of the most recently observed ReplicaSet. observedGeneration(observedGeneration):: {observedGeneration: observedGeneration}, // The number of ready replicas for this replica set. readyReplicas(readyReplicas):: {readyReplicas: readyReplicas}, // Replicas is the most recently oberved number of replicas. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller/#what-is-a-replicationcontroller replicas(replicas):: {replicas: replicas}, mixin:: { }, }, // rollbackConfig:: { new():: {}, // The revision to rollback to. If set to 0, rollback to the last revision. revision(revision):: {revision: revision}, mixin:: { }, }, // Spec to control the desired behavior of daemon set rolling update. rollingUpdateDaemonSet:: { new():: {}, // The maximum number of DaemonSet pods that can be unavailable during the update. Value can be an absolute number (ex: 5) or a percentage of total number of DaemonSet pods at the start of the update (ex: 10%). Absolute number is calculated from percentage by rounding up. This cannot be 0. Default value is 1. Example: when this is set to 30%, at most 30% of the total number of nodes that should be running the daemon pod (i.e. status.desiredNumberScheduled) can have their pods stopped for an update at any given time. The update starts by stopping at most 30% of those DaemonSet pods and then brings up new DaemonSet pods in their place. Once the new pods are available, it then proceeds onto other DaemonSet pods, thus ensuring that at least 70% of original number of DaemonSet pods are available at all times during the update. maxUnavailable(maxUnavailable):: {maxUnavailable: maxUnavailable}, mixin:: { }, }, // Spec to control the desired behavior of rolling update. rollingUpdateDeployment:: { new():: {}, // The maximum number of pods that can be scheduled above the desired number of pods. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). This can not be 0 if MaxUnavailable is 0. Absolute number is calculated from percentage by rounding up. By default, a value of 1 is used. Example: when this is set to 30%, the new RC can be scaled up immediately when the rolling update starts, such that the total number of old and new pods do not exceed 130% of desired pods. Once old pods have been killed, new RC can be scaled up further, ensuring that total number of pods running at any time during the update is atmost 130% of desired pods. maxSurge(maxSurge):: {maxSurge: maxSurge}, // The maximum number of pods that can be unavailable during the update. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). Absolute number is calculated from percentage by rounding down. This can not be 0 if MaxSurge is 0. By default, a fixed value of 1 is used. Example: when this is set to 30%, the old RC can be scaled down to 70% of desired pods immediately when the rolling update starts. Once new pods are ready, old RC can be scaled down further, followed by scaling up the new RC, ensuring that the total number of pods available at all times during the update is at least 70% of desired pods. maxUnavailable(maxUnavailable):: {maxUnavailable: maxUnavailable}, mixin:: { }, }, // Run A sUser Strategy Options defines the strategy type and any options used to create the strategy. runAsUserStrategyOptions:: { new():: {}, // Ranges are the allowed ranges of uids that may be used. ranges(ranges):: if std.type(ranges) == "array" then {ranges+: ranges} else {ranges+: [ranges]}, rangesType:: hidden.extensions.v1beta1.idRange, // Rule is the strategy that will dictate the allowable RunAsUser values that may be set. rule(rule):: {rule: rule}, mixin:: { }, }, // SELinux Strategy Options defines the strategy type and any options used to create the strategy. seLinuxStrategyOptions:: { new():: {}, // type is the strategy that will dictate the allowable labels that may be set. rule(rule):: {rule: rule}, mixin:: { // seLinuxOptions required to run as; required for MustRunAs More info: https://git.k8s.io/community/contributors/design-proposals/security_context.md seLinuxOptions:: { local __seLinuxOptionsMixin(seLinuxOptions) = {seLinuxOptions+: seLinuxOptions}, mixinInstance(seLinuxOptions):: __seLinuxOptionsMixin(seLinuxOptions), // Level is SELinux level label that applies to the container. level(level):: __seLinuxOptionsMixin({level: level}), // Role is a SELinux role label that applies to the container. role(role):: __seLinuxOptionsMixin({role: role}), // Type is a SELinux type label that applies to the container. type(type):: __seLinuxOptionsMixin({type: type}), // User is a SELinux user label that applies to the container. user(user):: __seLinuxOptionsMixin({user: user}), }, seLinuxOptionsType:: hidden.core.v1.seLinuxOptions, }, }, // describes the attributes of a scale subresource scaleSpec:: { new():: {}, // desired number of instances for the scaled object. replicas(replicas):: {replicas: replicas}, mixin:: { }, }, // represents the current status of a scale subresource. scaleStatus:: { new():: {}, // actual number of observed instances of the scaled object. replicas(replicas):: {replicas: replicas}, // label query over pods that should match the replicas count. More info: http://kubernetes.io/docs/user-guide/labels#label-selectors selector(selector):: {selector+: selector}, // label selector for pods that should match the replicas count. This is a serializated version of both map-based and more expressive set-based selectors. This is done to avoid introspection in the clients. The string will be in the same format as the query-param syntax. If the target type only supports map-based selectors, both this field and map-based selector field are populated. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors targetSelector(targetSelector):: {targetSelector: targetSelector}, mixin:: { }, }, // SupplementalGroupsStrategyOptions defines the strategy type and options used to create the strategy. supplementalGroupsStrategyOptions:: { new():: {}, // Ranges are the allowed ranges of supplemental groups. If you would like to force a single supplemental group then supply a single range with the same start and end. ranges(ranges):: if std.type(ranges) == "array" then {ranges+: ranges} else {ranges+: [ranges]}, rangesType:: hidden.extensions.v1beta1.idRange, // Rule is the strategy that will dictate what supplemental groups is used in the SecurityContext. rule(rule):: {rule: rule}, mixin:: { }, }, }, }, meta:: { v1:: { local apiVersion = {apiVersion: "meta/v1"}, // APIGroup contains the name, the supported versions, and the preferred version of a group. apiGroup:: { new():: {}, // name is the name of the group. name(name):: {name: name}, // a map of client CIDR to server address that is serving this group. This is to help clients reach servers in the most network-efficient way possible. Clients can use the appropriate server address as per the CIDR that they match. In case of multiple matches, clients should use the longest matching CIDR. The server returns only those CIDRs that it thinks that the client can match. For example: the master will return an internal IP CIDR only, if the client reaches the server using an internal IP. Server looks at X-Forwarded-For header or X-Real-Ip header or request.RemoteAddr (in that order) to get the client IP. serverAddressByClientCidrs(serverAddressByClientCidrs):: if std.type(serverAddressByClientCidrs) == "array" then {serverAddressByClientCIDRs+: serverAddressByClientCidrs} else {serverAddressByClientCIDRs+: [serverAddressByClientCidrs]}, serverAddressByClientCidrsType:: hidden.meta.v1.serverAddressByClientCidr, // versions are the versions supported in this group. versions(versions):: if std.type(versions) == "array" then {versions+: versions} else {versions+: [versions]}, versionsType:: hidden.meta.v1.groupVersionForDiscovery, mixin:: { // preferredVersion is the version preferred by the API server, which probably is the storage version. preferredVersion:: { local __preferredVersionMixin(preferredVersion) = {preferredVersion+: preferredVersion}, mixinInstance(preferredVersion):: __preferredVersionMixin(preferredVersion), // groupVersion specifies the API group and version in the form "group/version" groupVersion(groupVersion):: __preferredVersionMixin({groupVersion: groupVersion}), // version specifies the version in the form of "version". This is to save the clients the trouble of splitting the GroupVersion. version(version):: __preferredVersionMixin({version: version}), }, preferredVersionType:: hidden.meta.v1.groupVersionForDiscovery, }, }, // APIGroupList is a list of APIGroup, to allow clients to discover the API at /apis. apiGroupList:: { new():: {}, // groups is a list of APIGroup. groups(groups):: if std.type(groups) == "array" then {groups+: groups} else {groups+: [groups]}, groupsType:: hidden.meta.v1.apiGroup, mixin:: { }, }, // APIResource specifies the name of a resource and whether it is namespaced. apiResource:: { new():: {}, // categories is a list of the grouped resources this resource belongs to (e.g. 'all') categories(categories):: if std.type(categories) == "array" then {categories+: categories} else {categories+: [categories]}, // name is the plural name of the resource. name(name):: {name: name}, // namespaced indicates if a resource is namespaced or not. namespaced(namespaced):: {namespaced: namespaced}, // shortNames is a list of suggested short names of the resource. shortNames(shortNames):: if std.type(shortNames) == "array" then {shortNames+: shortNames} else {shortNames+: [shortNames]}, // singularName is the singular name of the resource. This allows clients to handle plural and singular opaquely. The singularName is more correct for reporting status on a single item and both singular and plural are allowed from the kubectl CLI interface. singularName(singularName):: {singularName: singularName}, // verbs is a list of supported kube verbs (this includes get, list, watch, create, update, patch, delete, deletecollection, and proxy) verbs(verbs):: if std.type(verbs) == "array" then {verbs+: verbs} else {verbs+: [verbs]}, mixin:: { }, }, // APIResourceList is a list of APIResource, it is used to expose the name of the resources supported in a specific group and version, and if the resource is namespaced. apiResourceList:: { new():: {}, // groupVersion is the group and version this APIResourceList is for. groupVersion(groupVersion):: {groupVersion: groupVersion}, // resources contains the name of the resources and if they are namespaced. resources(resources):: if std.type(resources) == "array" then {resources+: resources} else {resources+: [resources]}, resourcesType:: hidden.meta.v1.apiResource, mixin:: { }, }, // APIVersions lists the versions that are available, to allow clients to discover the API at /api, which is the root path of the legacy v1 API. apiVersions:: { new():: {}, // a map of client CIDR to server address that is serving this group. This is to help clients reach servers in the most network-efficient way possible. Clients can use the appropriate server address as per the CIDR that they match. In case of multiple matches, clients should use the longest matching CIDR. The server returns only those CIDRs that it thinks that the client can match. For example: the master will return an internal IP CIDR only, if the client reaches the server using an internal IP. Server looks at X-Forwarded-For header or X-Real-Ip header or request.RemoteAddr (in that order) to get the client IP. serverAddressByClientCidrs(serverAddressByClientCidrs):: if std.type(serverAddressByClientCidrs) == "array" then {serverAddressByClientCIDRs+: serverAddressByClientCidrs} else {serverAddressByClientCIDRs+: [serverAddressByClientCidrs]}, serverAddressByClientCidrsType:: hidden.meta.v1.serverAddressByClientCidr, // versions are the api versions that are available. versions(versions):: if std.type(versions) == "array" then {versions+: versions} else {versions+: [versions]}, mixin:: { }, }, // DeleteOptions may be provided when deleting an API object. deleteOptions:: { new():: {}, // The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. gracePeriodSeconds(gracePeriodSeconds):: {gracePeriodSeconds: gracePeriodSeconds}, // Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the "orphan" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. orphanDependents(orphanDependents):: {orphanDependents: orphanDependents}, // Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. propagationPolicy(propagationPolicy):: {propagationPolicy: propagationPolicy}, mixin:: { // Must be fulfilled before a deletion is carried out. If not possible, a 409 Conflict status will be returned. preconditions:: { local __preconditionsMixin(preconditions) = {preconditions+: preconditions}, mixinInstance(preconditions):: __preconditionsMixin(preconditions), // Specifies the target UID. uid(uid):: __preconditionsMixin({uid: uid}), }, preconditionsType:: hidden.meta.v1.preconditions, }, }, // GroupVersion contains the "group/version" and "version" string of a version. It is made a struct to keep extensibility. groupVersionForDiscovery:: { new():: {}, // groupVersion specifies the API group and version in the form "group/version" groupVersion(groupVersion):: {groupVersion: groupVersion}, // version specifies the version in the form of "version". This is to save the clients the trouble of splitting the GroupVersion. version(version):: {version: version}, mixin:: { }, }, // Initializer is information about an initializer that has not yet completed. initializer:: { new():: {}, // name of the process that is responsible for initializing this object. name(name):: {name: name}, mixin:: { }, }, // Initializers tracks the progress of initialization. initializers:: { new():: {}, // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then {pending+: pending} else {pending+: [pending]}, pendingType:: hidden.meta.v1.initializer, mixin:: { // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = {result+: result}, mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, }, // A label selector is a label query over a set of resources. The result of matchLabels and matchExpressions are ANDed. An empty label selector matches all objects. A null label selector matches no objects. labelSelector:: { new():: {}, // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then {matchExpressions+: matchExpressions} else {matchExpressions+: [matchExpressions]}, matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: {matchLabels+: matchLabels}, mixin:: { }, }, // A label selector requirement is a selector that contains values, a key, and an operator that relates the key and values. labelSelectorRequirement:: { new():: {}, // key is the label key that the selector applies to. key(key):: {key: key}, // operator represents a key's relationship to a set of values. Valid operators ard In, NotIn, Exists and DoesNotExist. operator(operator):: {operator: operator}, // values is an array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. This array is replaced during a strategic merge patch. values(values):: if std.type(values) == "array" then {values+: values} else {values+: [values]}, mixin:: { }, }, // ListMeta describes metadata that synthetic resources must have, including lists and various status objects. A resource may have only one of {ObjectMeta, ListMeta}. listMeta:: { new():: {}, // String that identifies the server's internal version of this object that can be used by clients to determine when objects have changed. Value must be treated as opaque by clients and passed unmodified back to the server. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency resourceVersion(resourceVersion):: {resourceVersion: resourceVersion}, // SelfLink is a URL representing this object. Populated by the system. Read-only. selfLink(selfLink):: {selfLink: selfLink}, mixin:: { }, }, // ObjectMeta is metadata that all persisted resources must have, which includes all objects users must create. objectMeta:: { new():: {}, // Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations annotations(annotations):: {annotations+: annotations}, // The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. clusterName(clusterName):: {clusterName: clusterName}, // Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. deletionGracePeriodSeconds(deletionGracePeriodSeconds):: {deletionGracePeriodSeconds: deletionGracePeriodSeconds}, // Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. finalizers(finalizers):: if std.type(finalizers) == "array" then {finalizers+: finalizers} else {finalizers+: [finalizers]}, // GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. // // If this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency generateName(generateName):: {generateName: generateName}, // Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels labels(labels):: {labels+: labels}, // Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: {name: name}, // Namespace defines the space within each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. // // Must be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces namespace(namespace):: {namespace: namespace}, mixin:: { // An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects. // // When an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user. initializers:: { local __initializersMixin(initializers) = {initializers+: initializers}, mixinInstance(initializers):: __initializersMixin(initializers), // Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients. pending(pending):: if std.type(pending) == "array" then __initializersMixin({pending+: pending}) else __initializersMixin({pending+: [pending]}), pendingType:: hidden.meta.v1.initializer, // If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion. result:: { local __resultMixin(result) = __initializersMixin({result+: result}), mixinInstance(result):: __resultMixin(result), // Suggested HTTP return code for this status, 0 if not set. code(code):: __resultMixin({code: code}), // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = __resultMixin({details+: details}), mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, // A human-readable description of the status of this operation. message(message):: __resultMixin({message: message}), // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: __resultMixin({reason: reason}), }, resultType:: hidden.meta.v1.status, }, initializersType:: hidden.meta.v1.initializers, }, }, // OwnerReference contains enough information to let you identify an owning object. Currently, an owning object must be in the same namespace, so there is no namespace field. ownerReference:: { new():: {}, // If true, AND if the owner has the "foregroundDeletion" finalizer, then the owner cannot be deleted from the key-value store until this reference is removed. Defaults to false. To set this field, a user needs "delete" permission of the owner, otherwise 422 (Unprocessable Entity) will be returned. blockOwnerDeletion(blockOwnerDeletion):: {blockOwnerDeletion: blockOwnerDeletion}, // If true, this reference points to the managing controller. controller(controller):: {controller: controller}, // Name of the referent. More info: http://kubernetes.io/docs/user-guide/identifiers#names name(name):: {name: name}, // UID of the referent. More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: {uid: uid}, mixin:: { }, }, // Patch is provided to give a concrete name and type to the Kubernetes PATCH request body. patch:: { new():: {}, mixin:: { }, }, // Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out. preconditions:: { new():: {}, // Specifies the target UID. uid(uid):: {uid: uid}, mixin:: { }, }, // ServerAddressByClientCIDR helps the client to determine the server address that they should use, depending on the clientCIDR that they match. serverAddressByClientCidr:: { new():: {}, // The CIDR with which clients can match their IP to figure out the server address that they should use. clientCidr(clientCidr):: {clientCIDR: clientCidr}, // Address of this server, suitable for a client that matches the above CIDR. This can be a hostname, hostname:port, IP or IP:port. serverAddress(serverAddress):: {serverAddress: serverAddress}, mixin:: { }, }, // Status is a return value for calls that don't return other objects. status:: { new():: {}, // Suggested HTTP return code for this status, 0 if not set. code(code):: {code: code}, // A human-readable description of the status of this operation. message(message):: {message: message}, // A machine-readable description of why this operation is in the "Failure" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. reason(reason):: {reason: reason}, mixin:: { // Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type. details:: { local __detailsMixin(details) = {details+: details}, mixinInstance(details):: __detailsMixin(details), // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then __detailsMixin({causes+: causes}) else __detailsMixin({causes+: [causes]}), causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: __detailsMixin({group: group}), // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: __detailsMixin({name: name}), // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: __detailsMixin({retryAfterSeconds: retryAfterSeconds}), // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: __detailsMixin({uid: uid}), }, detailsType:: hidden.meta.v1.statusDetails, }, }, // StatusCause provides more information about an api.Status failure, including cases when multiple errors are encountered. statusCause:: { new():: {}, // The field of the resource that has caused this error, as named by its JSON serialization. May include dot and postfix notation for nested attributes. Arrays are zero-indexed. Fields may appear more than once in an array of causes due to fields having multiple errors. Optional. // // Examples: // "name" - the field "name" on the current resource // "items[0].name" - the field "name" on the first array entry in "items" field(field):: {field: field}, // A human-readable description of the cause of the error. This field may be presented as-is to a reader. message(message):: {message: message}, // A machine-readable description of the cause of the error. If this value is empty there is no information available. reason(reason):: {reason: reason}, mixin:: { }, }, // StatusDetails is a set of additional properties that MAY be set by the server to provide additional information about a response. The Reason field of a Status object defines what attributes will be set. Clients must ignore fields that do not match the defined type of each attribute, and should assume that any attribute may be empty, invalid, or under defined. statusDetails:: { new():: {}, // The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. causes(causes):: if std.type(causes) == "array" then {causes+: causes} else {causes+: [causes]}, causesType:: hidden.meta.v1.statusCause, // The group attribute of the resource associated with the status StatusReason. group(group):: {group: group}, // The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). name(name):: {name: name}, // If specified, the time in seconds before the operation should be retried. retryAfterSeconds(retryAfterSeconds):: {retryAfterSeconds: retryAfterSeconds}, // UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids uid(uid):: {uid: uid}, mixin:: { }, }, // time:: { new():: {}, mixin:: { }, }, // Event represents a single event to a watched resource. watchEvent:: { new():: {}, // type(type):: {type: type}, mixin:: { }, }, }, }, networking:: { v1:: { local apiVersion = {apiVersion: "networking/v1"}, // NetworkPolicyIngressRule describes a particular set of traffic that is allowed to the pods matched by a NetworkPolicySpec's podSelector. The traffic must match both ports and from. networkPolicyIngressRule:: { new():: {}, // List of sources which should be able to access the pods selected for this rule. Items in this list are combined using a logical OR operation. If this field is empty or missing, this rule matches all sources (traffic not restricted by source). If this field is present and contains at least on item, this rule allows traffic only if the traffic matches at least one item in the from list. from(from):: if std.type(from) == "array" then {from+: from} else {from+: [from]}, fromType:: hidden.networking.v1.networkPolicyPeer, // List of ports which should be made accessible on the pods selected for this rule. Each item in this list is combined using a logical OR. If this field is empty or missing, this rule matches all ports (traffic not restricted by port). If this field is present and contains at least one item, then this rule allows traffic only if the traffic matches at least one port in the list. ports(ports):: if std.type(ports) == "array" then {ports+: ports} else {ports+: [ports]}, portsType:: hidden.networking.v1.networkPolicyPort, mixin:: { }, }, // NetworkPolicyPeer describes a peer to allow traffic from. Exactly one of its fields must be specified. networkPolicyPeer:: { new():: {}, mixin:: { // Selects Namespaces using cluster scoped-labels. This matches all pods in all namespaces selected by this label selector. This field follows standard label selector semantics. If present but empty, this selector selects all namespaces. namespaceSelector:: { local __namespaceSelectorMixin(namespaceSelector) = {namespaceSelector+: namespaceSelector}, mixinInstance(namespaceSelector):: __namespaceSelectorMixin(namespaceSelector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __namespaceSelectorMixin({matchExpressions+: matchExpressions}) else __namespaceSelectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __namespaceSelectorMixin({matchLabels+: matchLabels}), }, namespaceSelectorType:: hidden.meta.v1.labelSelector, // This is a label selector which selects Pods in this namespace. This field follows standard label selector semantics. If present but empty, this selector selects all pods in this namespace. podSelector:: { local __podSelectorMixin(podSelector) = {podSelector+: podSelector}, mixinInstance(podSelector):: __podSelectorMixin(podSelector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __podSelectorMixin({matchExpressions+: matchExpressions}) else __podSelectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __podSelectorMixin({matchLabels+: matchLabels}), }, podSelectorType:: hidden.meta.v1.labelSelector, }, }, // NetworkPolicyPort describes a port to allow traffic on networkPolicyPort:: { new():: {}, // The port on the given protocol. This can either be a numerical or named port on a pod. If this field is not provided, this matches all port names and numbers. port(port):: {port: port}, // The protocol (TCP or UDP) which traffic must match. If not specified, this field defaults to TCP. protocol(protocol):: {protocol: protocol}, mixin:: { }, }, // NetworkPolicySpec provides the specification of a NetworkPolicy networkPolicySpec:: { new():: {}, // List of ingress rules to be applied to the selected pods. Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod (and cluster policy otherwise allows the traffic), OR if the traffic source is the pod's local node, OR if the traffic matches at least one ingress rule across all of the NetworkPolicy objects whose podSelector matches the pod. If this field is empty then this NetworkPolicy does not allow any traffic (and serves solely to ensure that the pods it selects are isolated by default) ingress(ingress):: if std.type(ingress) == "array" then {ingress+: ingress} else {ingress+: [ingress]}, ingressType:: hidden.networking.v1.networkPolicyIngressRule, mixin:: { // Selects the pods to which this NetworkPolicy object applies. The array of ingress rules is applied to any pods selected by this field. Multiple network policies can select the same set of pods. In this case, the ingress rules for each are combined additively. This field is NOT optional and follows standard label selector semantics. An empty podSelector matches all pods in this namespace. podSelector:: { local __podSelectorMixin(podSelector) = {podSelector+: podSelector}, mixinInstance(podSelector):: __podSelectorMixin(podSelector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __podSelectorMixin({matchExpressions+: matchExpressions}) else __podSelectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __podSelectorMixin({matchLabels+: matchLabels}), }, podSelectorType:: hidden.meta.v1.labelSelector, }, }, }, }, policy:: { v1beta1:: { local apiVersion = {apiVersion: "policy/v1beta1"}, // PodDisruptionBudgetSpec is a description of a PodDisruptionBudget. podDisruptionBudgetSpec:: { new():: {}, // An eviction is allowed if at most "maxUnavailable" pods selected by "selector" are unavailable after the eviction, i.e. even in absence of the evicted pod. For example, one can prevent all voluntary evictions by specifying 0. This is a mutually exclusive setting with "minAvailable". maxUnavailable(maxUnavailable):: {maxUnavailable: maxUnavailable}, // An eviction is allowed if at least "minAvailable" pods selected by "selector" will still be available after the eviction, i.e. even in the absence of the evicted pod. So for example you can prevent all voluntary evictions by specifying "100%". minAvailable(minAvailable):: {minAvailable: minAvailable}, mixin:: { // Label query over pods whose evictions are managed by the disruption budget. selector:: { local __selectorMixin(selector) = {selector+: selector}, mixinInstance(selector):: __selectorMixin(selector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __selectorMixin({matchExpressions+: matchExpressions}) else __selectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __selectorMixin({matchLabels+: matchLabels}), }, selectorType:: hidden.meta.v1.labelSelector, }, }, // PodDisruptionBudgetStatus represents information about the status of a PodDisruptionBudget. Status may trail the actual state of a system. podDisruptionBudgetStatus:: { new():: {}, // current number of healthy pods currentHealthy(currentHealthy):: {currentHealthy: currentHealthy}, // minimum desired number of healthy pods desiredHealthy(desiredHealthy):: {desiredHealthy: desiredHealthy}, // DisruptedPods contains information about pods whose eviction was processed by the API server eviction subresource handler but has not yet been observed by the PodDisruptionBudget controller. A pod will be in this map from the time when the API server processed the eviction request to the time when the pod is seen by PDB controller as having been marked for deletion (or after a timeout). The key in the map is the name of the pod and the value is the time when the API server processed the eviction request. If the deletion didn't occur and a pod is still there it will be removed from the list automatically by PodDisruptionBudget controller after some time. If everything goes smooth this map should be empty for the most of the time. Large number of entries in the map may indicate problems with pod deletions. disruptedPods(disruptedPods):: {disruptedPods+: disruptedPods}, // Number of pod disruptions that are currently allowed. disruptionsAllowed(disruptionsAllowed):: {disruptionsAllowed: disruptionsAllowed}, // total number of pods counted by this disruption budget expectedPods(expectedPods):: {expectedPods: expectedPods}, // Most recent generation observed when updating this PDB status. PodDisruptionsAllowed and other status informatio is valid only if observedGeneration equals to PDB's object generation. observedGeneration(observedGeneration):: {observedGeneration: observedGeneration}, mixin:: { }, }, }, }, rbac:: { v1alpha1:: { local apiVersion = {apiVersion: "rbac/v1alpha1"}, // PolicyRule holds information that describes a policy rule, but does not contain information about who the rule applies to or which namespace the rule applies to. policyRule:: { new():: {}, // APIGroups is the name of the APIGroup that contains the resources. If multiple API groups are specified, any action requested against one of the enumerated resources in any API group will be allowed. apiGroups(apiGroups):: if std.type(apiGroups) == "array" then {apiGroups+: apiGroups} else {apiGroups+: [apiGroups]}, // NonResourceURLs is a set of partial urls that a user should have access to. *s are allowed, but only as the full, final step in the path This name is intentionally different than the internal type so that the DefaultConvert works nicely and because the ordering may be different. Since non-resource URLs are not namespaced, this field is only applicable for ClusterRoles referenced from a ClusterRoleBinding. Rules can either apply to API resources (such as "pods" or "secrets") or non-resource URL paths (such as "/api"), but not both. nonResourceUrls(nonResourceUrls):: if std.type(nonResourceUrls) == "array" then {nonResourceURLs+: nonResourceUrls} else {nonResourceURLs+: [nonResourceUrls]}, // ResourceNames is an optional white list of names that the rule applies to. An empty set means that everything is allowed. resourceNames(resourceNames):: if std.type(resourceNames) == "array" then {resourceNames+: resourceNames} else {resourceNames+: [resourceNames]}, // Resources is a list of resources this rule applies to. ResourceAll represents all resources. resources(resources):: if std.type(resources) == "array" then {resources+: resources} else {resources+: [resources]}, // Verbs is a list of Verbs that apply to ALL the ResourceKinds and AttributeRestrictions contained in this rule. VerbAll represents all kinds. verbs(verbs):: if std.type(verbs) == "array" then {verbs+: verbs} else {verbs+: [verbs]}, mixin:: { }, }, // RoleRef contains information that points to the role being used roleRef:: { new():: {}, // APIGroup is the group for the resource being referenced apiGroup(apiGroup):: {apiGroup: apiGroup}, // Name is the name of resource being referenced name(name):: {name: name}, mixin:: { }, }, // Subject contains a reference to the object or user identities a role binding applies to. This can either hold a direct API object reference, or a value for non-objects such as user and group names. subject:: { new():: {}, // Name of the object being referenced. name(name):: {name: name}, // Namespace of the referenced object. If the object kind is non-namespace, such as "User" or "Group", and this value is not empty the Authorizer should report an error. namespace(namespace):: {namespace: namespace}, mixin:: { }, }, }, v1beta1:: { local apiVersion = {apiVersion: "rbac/v1beta1"}, // PolicyRule holds information that describes a policy rule, but does not contain information about who the rule applies to or which namespace the rule applies to. policyRule:: { new():: {}, // APIGroups is the name of the APIGroup that contains the resources. If multiple API groups are specified, any action requested against one of the enumerated resources in any API group will be allowed. apiGroups(apiGroups):: if std.type(apiGroups) == "array" then {apiGroups+: apiGroups} else {apiGroups+: [apiGroups]}, // NonResourceURLs is a set of partial urls that a user should have access to. *s are allowed, but only as the full, final step in the path Since non-resource URLs are not namespaced, this field is only applicable for ClusterRoles referenced from a ClusterRoleBinding. Rules can either apply to API resources (such as "pods" or "secrets") or non-resource URL paths (such as "/api"), but not both. nonResourceUrls(nonResourceUrls):: if std.type(nonResourceUrls) == "array" then {nonResourceURLs+: nonResourceUrls} else {nonResourceURLs+: [nonResourceUrls]}, // ResourceNames is an optional white list of names that the rule applies to. An empty set means that everything is allowed. resourceNames(resourceNames):: if std.type(resourceNames) == "array" then {resourceNames+: resourceNames} else {resourceNames+: [resourceNames]}, // Resources is a list of resources this rule applies to. ResourceAll represents all resources. resources(resources):: if std.type(resources) == "array" then {resources+: resources} else {resources+: [resources]}, // Verbs is a list of Verbs that apply to ALL the ResourceKinds and AttributeRestrictions contained in this rule. VerbAll represents all kinds. verbs(verbs):: if std.type(verbs) == "array" then {verbs+: verbs} else {verbs+: [verbs]}, mixin:: { }, }, // RoleRef contains information that points to the role being used roleRef:: { new():: {}, // APIGroup is the group for the resource being referenced apiGroup(apiGroup):: {apiGroup: apiGroup}, // Name is the name of resource being referenced name(name):: {name: name}, mixin:: { }, }, // Subject contains a reference to the object or user identities a role binding applies to. This can either hold a direct API object reference, or a value for non-objects such as user and group names. subject:: { new():: {}, // APIGroup holds the API group of the referenced subject. Defaults to "" for ServiceAccount subjects. Defaults to "rbac.authorization.k8s.io" for User and Group subjects. apiGroup(apiGroup):: {apiGroup: apiGroup}, // Name of the object being referenced. name(name):: {name: name}, // Namespace of the referenced object. If the object kind is non-namespace, such as "User" or "Group", and this value is not empty the Authorizer should report an error. namespace(namespace):: {namespace: namespace}, mixin:: { }, }, }, }, settings:: { v1alpha1:: { local apiVersion = {apiVersion: "settings/v1alpha1"}, // PodPresetSpec is a description of a pod preset. podPresetSpec:: { new():: {}, // Env defines the collection of EnvVar to inject into containers. env(env):: if std.type(env) == "array" then {env+: env} else {env+: [env]}, // EnvFrom defines the collection of EnvFromSource to inject into containers. envFrom(envFrom):: if std.type(envFrom) == "array" then {envFrom+: envFrom} else {envFrom+: [envFrom]}, envFromType:: hidden.core.v1.envFromSource, envType:: hidden.core.v1.envVar, // VolumeMounts defines the collection of VolumeMount to inject into containers. volumeMounts(volumeMounts):: if std.type(volumeMounts) == "array" then {volumeMounts+: volumeMounts} else {volumeMounts+: [volumeMounts]}, volumeMountsType:: hidden.core.v1.volumeMount, // Volumes defines the collection of Volume to inject into the pod. volumes(volumes):: if std.type(volumes) == "array" then {volumes+: volumes} else {volumes+: [volumes]}, volumesType:: hidden.core.v1.volume, mixin:: { // Selector is a label query over a set of resources, in this case pods. Required. selector:: { local __selectorMixin(selector) = {selector+: selector}, mixinInstance(selector):: __selectorMixin(selector), // matchExpressions is a list of label selector requirements. The requirements are ANDed. matchExpressions(matchExpressions):: if std.type(matchExpressions) == "array" then __selectorMixin({matchExpressions+: matchExpressions}) else __selectorMixin({matchExpressions+: [matchExpressions]}), matchExpressionsType:: hidden.meta.v1.labelSelectorRequirement, // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. matchLabels(matchLabels):: __selectorMixin({matchLabels+: matchLabels}), }, selectorType:: hidden.meta.v1.labelSelector, }, }, }, }, }, }