I'm trying to share a directory on my Mac with a virtual machine I created using the Virtualization framework. The virtual machine is running Fedora. I configure the share like this:
NSError *error = nil;
if ([VZVirtioFileSystemDeviceConfiguration validateTag:tag error:&error])
{
//Tag validates...
VZSharedDirectory *sharedDirectiory = [[VZSharedDirectory alloc]initWithURL:theURL readOnly:NO];
VZSingleDirectoryShare *singleDirectoryShare = [[VZSingleDirectoryShare alloc]initWithDirectory:sharedDirectiory];
VZVirtioFileSystemDeviceConfiguration *shareConfig = [[VZVirtioFileSystemDeviceConfiguration alloc]initWithTag:tag];
shareConfig.share = singleDirectoryShare;
virtualMachineConfiguration.directorySharingDevices = @[shareConfig];
}
The virtual machine starts up without any errors but the shared directory is nowhere to be found. Anyone know where am I'm going wrong?
Thanks in advance.