schtritoff / hyperv-vm-provisioning

Quick provisioning of Linux VM using Hyper-V on Windows
77 stars 29 forks source link

replace oscdimg with New-ISOFile #39

Closed samstagern closed 1 week ago

samstagern commented 1 week ago

fixes #5

Note: this is a draft. I would like to have feedback from multiple users before I make it a real PR. It works really well on my machines (Windows 10) with both Windows Powershell 5 and Powershell 7.

samstagern commented 1 week ago

Example Verbose output:

Creating metadata iso for VM provisioning... VERBOSE: Filename: C:\ProgramData\Microsoft\Windows\Virtual Hard Disks\Pester-20.04-metadata.iso VERBOSE: Function start. VERBOSE: Processing nested system Pester-20.04 VERBOSE: Adding ISOFile type. VERBOSE: Selected media type is CDR with value 2 VERBOSE: Initialising image object. VERBOSE: initialised. VERBOSE: Fetching items from source directory. VERBOSE: Got source items. VERBOSE: Adding items to image. VERBOSE: Writing out ISO file to C:\ProgramData\Microsoft\Windows\Virtual Hard Disks\Pester-20.04-metadata.iso VERBOSE: File complete. VERBOSE: Function complete. VERBOSE: Metadata iso written in C:\ProgramData\Microsoft\Windows\Virtual Hard Disks\Pester-20.04-metadata.iso Done.

samstagern commented 1 week ago

This needs more testing