Mapping multiple KubeVirt CSI volume snapshot classes
You can map multiple volume snapshot classes to the hosted cluster by assigning them to a specific group. The infrastructure storage class and the volume snapshot class are compatible with each other only if they belong to a same group.
-
To map multiple volume snapshot classes to the hosted cluster, use the
groupoption when creating a hosted cluster, as shown in the following example:$ hcp create cluster kubevirt \ --name my-hosted-cluster \ --node-pool-replicas 2 \ --pull-secret /user/name/pullsecret \ --memory 8Gi \ --cores 2 \ --infra-storage-class-mapping=<infrastructure_storage_class>/<hosted_storage_class>,group=<group_name> \ --infra-storage-class-mapping=<infrastructure_storage_class>/<hosted_storage_class>,group=<group_name> \ --infra-storage-class-mapping=<infrastructure_storage_class>/<hosted_storage_class>,group=<group_name> \ --infra-volumesnapshot-class-mapping=<infrastructure_volume_snapshot_class>/<hosted_volume_snapshot_class>,group=<group_name> \ --infra-volumesnapshot-class-mapping=<infrastructure_volume_snapshot_class>/<hosted_volume_snapshot_class>,group=<group_name>-
--namespecifies the name of your hosted cluster. -
--node-pool-replicasspecifies the worker count. -
--pull-secretspecifies the path to your pull secret. -
--memoryspecifies a value for memory. -
--coresspecifies a value for CPU. -
--infra-storage-class-mappingspecifies the storage classes. Replace<infrastructure_storage_class>with the storage class in the infrastructure cluster,<hosted_storage_class>with the storage class in the hosted cluster, and<group_name>with the group name. For example,infra-storage-class-mygroup/hosted-storage-class-mygroup,group=mygroupandinfra-storage-class-mymap/hosted-storage-class-mymap,group=mymap. -
--infra-volumesnapshot-class-mappingspecifies the volume snapshot classes. Replace<infrastructure_volume_snapshot_class>with the volume snapshot class in the infrastructure cluster and<hosted_volume_snapshot_class>with the volume snapshot class in the hosted cluster. For example,infra-vol-snap-mygroup/hosted-vol-snap-mygroup,group=mygroupandinfra-vol-snap-mymap/hosted-vol-snap-mymap,group=mymap.
-