Skip to main content
Version: v0.38 Stable

CSI storage capacities

Supported Configurations
Running the control plane as a container with:

Sync CSIStorageCapacity resources from the control plane cluster to the cluster if the .nodeTopology matches a synced node. Use this in conjunction with the virtual scheduler inside of vCluster for more advanced scheduling needs. Syncing the CSIStorageCapacity resources from the control plane cluster helps the virtual scheduler make decisions about which node to schedule pods to.

CSIStorageCapacity is a namespaced resource. When synchronizing from the control plane cluster to the cluster, all CSIStorageCapacity objects are synced into the kube-system namespace of the cluster. During this process, the object name is transformed to the format <objname>-x-<namespace>, where <objname> is the original object name in the control plane cluster and <namespace> is the namespace in which the object originally existed in the control plane cluster.

When synchronizing from the cluster back to the control plane cluster, a CSIStorageCapacity object is created in the control plane cluster only if it includes the physical location annotations normally added by the syncer. Specifically:

  • vcluster.loft.sh/object-name specifies the object name in the control plane cluster.
  • vcluster.loft.sh/object-namespace specifies the control plane cluster namespace. If these annotations are not present, the CSIStorageCapacity object will not be created or updated in the control plane cluster.
Physical annotations of CSIStorageCapacity
apiVersion: storage.k8s.io/v1
kind: CSIStorageCapacity
metadata:
name: fast-ssd-x-storage-v
namespace: kube-system
annotations:
vcluster.loft.sh/object-name: fast-ssd
vcluster.loft.sh/object-namespace: storage-v
# optional bookkeeping:
# vcluster.loft.sh/object-uid: "c1a2b3c4-..."
# vcluster.loft.sh/object-kind: "storage.k8s.io/v1, Kind=CSIStorageCapacity"

Default value​

Default: enabled: auto.

Sync CSIStorageCapacities from the control plane cluster to the cluster​

Configure enabled: true if you aren't using the virtual scheduler but want to sync CSIStorageCapacity resources.

sync:
fromHost:
csiStorageCapacities:
enabled: true

Config reference​

For every field under sync.fromHost.csiStorageCapacities, see the sync reference.