VMware vSphere Kubernetes Service
A tag-based Storage policy needs to be created to expose an NFS datastore as a StorageClass for vSphere Kubernetes Guest Cluster.
Create and Assign a Tag
Log in to the vSphere Client.
Navigate to Tags & Custom Attributes.
Create a new Category (e.g., k8s-storage) ensuring it is assignable to Datastore.
Create a new Tag (e.g., nfs-rwx) inside that category.
Navigate to the Storage view, right-click the target NFS Datastore, and select Tags & Custom Attributes > Assign Tag.
Select the nfs-rwx tag and confirm.
Create the VM Storage Policy
Navigate to Policies and Profiles > VM Storage Policies.
Click Create.
Enter a name (e.g., nfs-rwx-policy).
On the Policy structure page, under "Datastore specific rules", select Enable tag-based placement rules.
On the Tag based placement page:
Tag category: Select k8s-storage.
Usage: Select Use storage tagged with.
Tags: Browse and select nfs-rwx.
On the Storage compatibility page, verify that the NFS datastore is listed as Compatible.
Finish the wizard.
Assign Policy to Namespace
Navigate to Workload Management > Namespaces.
Select the target Namespace.
Under Storage, click Add Storage.
Select the nfs-rwx-policy created above.
(Optional) Set a storage limit for this policy.