Volume represents a named volume in a pod that may be accessed by any container in the pod.
fromConfigMap(name='', configMapName='', configMapItems='')
fromEmptyDir(name='', emptyDir={})
fromHostPath(name='', hostPath='')
fromPersistentVolumeClaim(name='', emptyDir='')
fromSecret(name='', secretName='')
withName(name)
Volume’s name. Must be a DNS_LABEL and unique within the pod. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
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
mixinInstance(awsElasticBlockStore)
withFsType(fsType)
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
withPartition(partition)
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).
withReadOnly(readOnly)
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
withVolumeId(volumeId)
Unique ID of the persistent disk resource in AWS (Amazon EBS volume). More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore
AzureDisk represents an Azure Data Disk mount on the host and bind mount to the pod.
mixinInstance(azureDisk)
withCachingMode(cachingMode)
Host Caching mode: None, Read Only, Read Write.
withDiskName(diskName)
The Name of the data disk in the blob storage
withDiskUri(diskUri)
The URI the data disk in the blob storage
withFsType(fsType)
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.
withReadOnly(readOnly)
Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.
AzureFile represents an Azure File Service mount on the host and bind mount to the pod.
mixinInstance(azureFile)
withReadOnly(readOnly)
Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.
withSecretName(secretName)
the name of secret that contains Azure Storage Account Name and Key
CephFS represents a Ceph FS mount on the host that shares a pod's lifetime
mixinInstance(cephfs)
withMonitors(monitors)
Required: Monitors is a collection of Ceph monitors More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it
withMonitorsMixin(monitors)
Required: Monitors is a collection of Ceph monitors More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it
withPath(path)
Optional: Used as the mounted root, rather than the full Ceph tree, default is /
withReadOnly(readOnly)
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
withSecretFile(secretFile)
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
withUser(user)
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
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
mixinInstance(secretRef)
withName(name)
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
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
mixinInstance(cinder)
withFsType(fsType)
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
withReadOnly(readOnly)
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
withVolumeId(volumeId)
volume id used to identify the volume in cinder More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md
Optional: points to a secret object containing parameters used to connect to OpenStack.
mixinInstance(secretRef)
withName(name)
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
ConfigMap represents a configMap that should populate this volume
mixinInstance(configMap)
withDefaultMode(defaultMode)
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.
withItems(items)
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 ‘..’.
withItems
takes an array of type itemsType
. You can create
an instance of itemsType
with hidden.core.v1.keyToPath.new()
.
withItemsMixin(items)
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 ‘..’.
withItemsMixin
takes an array of type itemsType
. You can create
an instance of itemsType
with hidden.core.v1.keyToPath.new()
.
withName(name)
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
withOptional(optional)
Specify whether the ConfigMap or its keys must be defined
CSI (Container Storage Interface) represents storage that is handled by an external CSI driver (Alpha feature).
mixinInstance(csi)
withDriver(driver)
Driver is the name of the CSI driver that handles this volume. Consult with your admin for the correct name as registered in the cluster.
withFsType(fsType)
Filesystem type to mount. Ex. “ext4”, “xfs”, “ntfs”. If not provided, the empty value is passed to the associated CSI driver which will determine the default filesystem to apply.
withReadOnly(readOnly)
Specifies a read-only configuration for the volume. Defaults to false (read/write).
withVolumeAttributes(volumeAttributes)
VolumeAttributes stores driver-specific properties that are passed to the CSI driver. Consult your driver’s documentation for supported values.
withVolumeAttributesMixin(volumeAttributes)
VolumeAttributes stores driver-specific properties that are passed to the CSI driver. Consult your driver’s documentation for supported values.
NodePublishSecretRef is a reference to the secret object containing sensitive information to pass to the CSI driver to complete the CSI NodePublishVolume and NodeUnpublishVolume calls. This field is optional, and may be empty if no secret is required. If the secret object contains more than one secret, all secret references are passed.
mixinInstance(nodePublishSecretRef)
withName(name)
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
DownwardAPI represents downward API about the pod that should populate this volume
mixinInstance(downwardApi)
withDefaultMode(defaultMode)
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.
withItems(items)
Items is a list of downward API volume file
withItems
takes an array of type itemsType
. You can create
an instance of itemsType
with hidden.core.v1.downwardApiVolumeFile.new()
.
see hidden.core.v1.downwardApiVolumeFile
withItemsMixin(items)
Items is a list of downward API volume file
withItemsMixin
takes an array of type itemsType
. You can create
an instance of itemsType
with hidden.core.v1.downwardApiVolumeFile.new()
.
see hidden.core.v1.downwardApiVolumeFile
EmptyDir represents a temporary directory that shares a pod's lifetime. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir
mixinInstance(emptyDir)
withMedium(medium)
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
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
mixinInstance(sizeLimit)
FC represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod.
mixinInstance(fc)
withFsType(fsType)
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.
withLun(lun)
Optional: FC target lun number
withReadOnly(readOnly)
Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.
withTargetWwns(targetWwns)
Optional: FC target worldwide names (WWNs)
withTargetWwnsMixin(targetWwns)
Optional: FC target worldwide names (WWNs)
withWwids(wwids)
Optional: FC volume world wide identifiers (wwids) Either wwids or combination of targetWWNs and lun must be set, but not both simultaneously.
withWwidsMixin(wwids)
Optional: FC volume world wide identifiers (wwids) Either wwids or combination of targetWWNs and lun must be set, but not both simultaneously.
FlexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin.
mixinInstance(flexVolume)
withDriver(driver)
Driver is the name of the driver to use for this volume.
withFsType(fsType)
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.
withOptions(options)
Optional: Extra command options if any.
withOptionsMixin(options)
Optional: Extra command options if any.
withReadOnly(readOnly)
Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.
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.
mixinInstance(secretRef)
withName(name)
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
Flocker represents a Flocker volume attached to a kubelet's host machine. This depends on the Flocker control service being running
mixinInstance(flocker)
withDatasetName(datasetName)
Name of the dataset stored as metadata -> name on the dataset for Flocker should be considered as deprecated
withDatasetUuid(datasetUuid)
UUID of the dataset. This is unique identifier of a Flocker dataset
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
mixinInstance(gcePersistentDisk)
withFsType(fsType)
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
withPartition(partition)
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
withPdName(pdName)
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
withReadOnly(readOnly)
ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk
GitRepo represents a git repository at a particular revision. DEPRECATED: GitRepo is deprecated. To provision a container with a git repo, mount an EmptyDir into an InitContainer that clones the repo using git, then mount the EmptyDir into the Pod's container.
mixinInstance(gitRepo)
withDirectory(directory)
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.
withRepository(repository)
Repository URL
withRevision(revision)
Commit hash for the specified revision.
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
mixinInstance(glusterfs)
withEndpoints(endpoints)
EndpointsName is the endpoint name that details Glusterfs topology. More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod
withPath(path)
Path is the Glusterfs volume path. More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod
withReadOnly(readOnly)
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
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
mixinInstance(hostPath)
withPath(path)
Path of the directory on the host. If the path is a symlink, it will follow the link to the real path. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath
withType(type)
Type for HostPath Volume Defaults to “” More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath
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
mixinInstance(iscsi)
withChapAuthDiscovery(chapAuthDiscovery)
whether support iSCSI Discovery CHAP authentication
withChapAuthSession(chapAuthSession)
whether support iSCSI Session CHAP authentication
withFsType(fsType)
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
withInitiatorName(initiatorName)
Custom iSCSI Initiator Name. If initiatorName is specified with iscsiInterface simultaneously, new iSCSI interface
withIqn(iqn)
Target iSCSI Qualified Name.
withIscsiInterface(iscsiInterface)
iSCSI Interface Name that uses an iSCSI transport. Defaults to ‘default’ (tcp).
withLun(lun)
iSCSI Target Lun number.
withPortals(portals)
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).
withPortalsMixin(portals)
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).
withReadOnly(readOnly)
ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false.
withTargetPortal(targetPortal)
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).
CHAP Secret for iSCSI target and initiator authentication
mixinInstance(secretRef)
withName(name)
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
NFS represents an NFS mount on the host that shares a pod's lifetime More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs
mixinInstance(nfs)
withPath(path)
Path that is exported by the NFS server. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs
withReadOnly(readOnly)
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
withServer(server)
Server is the hostname or IP address of the NFS server. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs
PersistentVolumeClaimVolumeSource represents a reference to a PersistentVolumeClaim in the same namespace. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims
mixinInstance(persistentVolumeClaim)
withClaimName(claimName)
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
withReadOnly(readOnly)
Will force the ReadOnly setting in VolumeMounts. Default false.
PhotonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine
mixinInstance(photonPersistentDisk)
withFsType(fsType)
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.
withPdId(pdId)
ID that identifies Photon Controller persistent disk
PortworxVolume represents a portworx volume attached and mounted on kubelets host machine
mixinInstance(portworxVolume)
withFsType(fsType)
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.
withReadOnly(readOnly)
Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.
withVolumeId(volumeId)
VolumeID uniquely identifies a Portworx volume
Items for all in one resources secrets, configmaps, and downward API
mixinInstance(projected)
withDefaultMode(defaultMode)
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.
withSources(sources)
list of volume projections
withSources
takes an array of type sourcesType
. You can create
an instance of sourcesType
with hidden.core.v1.volumeProjection.new()
.
see hidden.core.v1.volumeProjection
withSourcesMixin(sources)
list of volume projections
withSourcesMixin
takes an array of type sourcesType
. You can create
an instance of sourcesType
with hidden.core.v1.volumeProjection.new()
.
see hidden.core.v1.volumeProjection
Quobyte represents a Quobyte mount on the host that shares a pod's lifetime
mixinInstance(quobyte)
withGroup(group)
Group to map volume access to Default is no group
withReadOnly(readOnly)
ReadOnly here will force the Quobyte volume to be mounted with read-only permissions. Defaults to false.
withRegistry(registry)
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
withTenant(tenant)
Tenant owning the given Quobyte volume in the Backend Used with dynamically provisioned Quobyte volumes, value is set by the plugin
withUser(user)
User to map volume access to Defaults to serivceaccount user
withVolume(volume)
Volume is a string that references an already created Quobyte volume by name.
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
mixinInstance(rbd)
withFsType(fsType)
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
withImage(image)
The rados image name. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
withKeyring(keyring)
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
withMonitors(monitors)
A collection of Ceph monitors. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
withMonitorsMixin(monitors)
A collection of Ceph monitors. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
withPool(pool)
The rados pool name. Default is rbd. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
withReadOnly(readOnly)
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
withUser(user)
The rados user name. Default is admin. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it
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
mixinInstance(secretRef)
withName(name)
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
ScaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes.
mixinInstance(scaleIo)
withFsType(fsType)
Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. “ext4”, “xfs”, “ntfs”. Default is “xfs”.
withGateway(gateway)
The host address of the ScaleIO API Gateway.
withProtectionDomain(protectionDomain)
The name of the ScaleIO Protection Domain for the configured storage.
withReadOnly(readOnly)
Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.
withSslEnabled(sslEnabled)
Flag to enable/disable SSL communication with Gateway, default false
withStorageMode(storageMode)
Indicates whether the storage for a volume should be ThickProvisioned or ThinProvisioned. Default is ThinProvisioned.
withStoragePool(storagePool)
The ScaleIO Storage Pool associated with the protection domain.
withSystem(system)
The name of the storage system as configured in ScaleIO.
withVolumeName(volumeName)
The name of a volume already created in the ScaleIO system that is associated with this volume source.
SecretRef references to the secret for ScaleIO user and other sensitive information. If this is not provided, Login operation will fail.
mixinInstance(secretRef)
withName(name)
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
Secret represents a secret that should populate this volume. More info: https://kubernetes.io/docs/concepts/storage/volumes#secret
mixinInstance(secret)
withDefaultMode(defaultMode)
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.
withItems(items)
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 ‘..’.
withItems
takes an array of type itemsType
. You can create
an instance of itemsType
with hidden.core.v1.keyToPath.new()
.
withItemsMixin(items)
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 ‘..’.
withItemsMixin
takes an array of type itemsType
. You can create
an instance of itemsType
with hidden.core.v1.keyToPath.new()
.
withOptional(optional)
Specify whether the Secret or its keys must be defined
withSecretName(secretName)
Name of the secret in the pod’s namespace to use. More info: https://kubernetes.io/docs/concepts/storage/volumes#secret
StorageOS represents a StorageOS volume attached and mounted on Kubernetes nodes.
mixinInstance(storageos)
withFsType(fsType)
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.
withReadOnly(readOnly)
Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.
withVolumeName(volumeName)
VolumeName is the human-readable name of the StorageOS volume. Volume names are only unique within a namespace.
withVolumeNamespace(volumeNamespace)
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.
SecretRef specifies the secret to use for obtaining the StorageOS API credentials. If not specified, default values will be attempted.
mixinInstance(secretRef)
withName(name)
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
VsphereVolume represents a vSphere volume attached and mounted on kubelets host machine
mixinInstance(vsphereVolume)
withFsType(fsType)
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.
withStoragePolicyId(storagePolicyId)
Storage Policy Based Management (SPBM) profile ID associated with the StoragePolicyName.
withStoragePolicyName(storagePolicyName)
Storage Policy Based Management (SPBM) profile name.
withVolumePath(volumePath)
Path that identifies vSphere volume vmdk