Skip to content
Install the CLI

Reference Package catalog

persistent-volume-claim

These docs describe Kix's main branch, which can include changes not yet released. Read the docs for the latest release.

A PersistentVolumeClaim as its own cluster instance, with its StorageClass set explicitly or taken from the storageClasses dependency

This page is generated from kix/packages/stable/persistent-volume-claim.

StabilityStable
package valuepackages.persistent-volume-claim
Default aliasesstorage

Kix matches each dependency below to another package instance by instance name, alias, or role. To bind a specific instance, set deps.<name> in your cluster definition. See Declaring dependencies for how required and optional dependencies work.

DependencyRequirement
storageClassesOptional

Access modes of the claim. ReadWriteMany and ReadOnlyMany need a provisioner that supports shared mounts; the claim stays Pending otherwise. ReadWriteOncePod cannot be combined with another mode.

  • Type: non-empty (list of (one of "ReadWriteOnce", "ReadOnlyMany", "ReadWriteMany", "ReadWriteOncePod"))

  • Default:

    [
    "ReadWriteOnce"
    ]

Merged into the claim’s spec, for fields without an option of their own: volumeMode, dataSource, dataSourceRef, selector, volumeName, and volumeAttributesClassName. storageClassName, accessModes, and resources.requests.storage are set by their options and refused here.

  • Type: attribute set of anything
  • Default: { }
  • Example: { volumeMode = "Block"; }

Requested capacity, as a Kubernetes quantity such as “20Gi”; an integer is a number of bytes. Must be at least one byte. Required: a generic claim cannot know how much its consumer stores. Rendered as spec.resources.requests.storage and published as out.size, both as strings. The apiserver accepts an increase only when the class allows volume expansion, and refuses a decrease.

  • Type: Kubernetes quantity, such as "500m" or "1Gi" (a non-negative decimal or integer with an optional suffix m, k, M, G, T, P, E, Ki, Mi, Gi, Ti, Pi or Ei)
  • Example: "20Gi"

StorageClass of the claim. Null takes out.storageClassName from the storageClasses dependency. "" requests no class, for binding to a pre-provisioned PersistentVolume named in extraSpec.volumeName. The apiserver refuses a change once the claim exists.

  • Type: null or string
  • Default: null
  • Example: "local-path-retain"