Create a harvester-specific StorageClass for Longhorn

Ref: https://github.com/harvester/harvester/issues/2692

image

Verify Steps:

  1. Install Harvester with 2+ nodes
  2. Login to Dashboard and create an image for VM creation
  3. Navigate to Advanced/Storage Classes, harvester-longhorn and longhorn should be available, and harvester-longhorn should be settled as Default
  4. Navigate to Volumes and create vol-old where Storage Class is longhorn and vol-new where Storage Class is harvester-longhorn
  5. Create VM vm1 attaching vol-old and vol-new
  6. Login to vm1 and use fdisk format volumes and mount to folders: old and new
  7. Create file and move into both volumes as following commands:
dd if=/dev/zero of=file1 bs=10485760 count=10
cp file1 old && cp file1 new
  1. Migrate vm1 to another host, migration should success
  2. Login to vm1, volumes should still attaching to folders old and new
  3. Execute command sha256sum on old/file1 and new/file1 should show the same value.