dsccommunity / HyperVDsc

This module contains DSC resources for deployment and configuration of Microsoft Hyper-V.
MIT License
111 stars 65 forks source link

VMNetworkAdapter: `SwitchName` should not be a mandatory property #171

Open sergey-s-betke opened 5 years ago

sergey-s-betke commented 5 years ago

Details of the scenario you tried and the problem that is occurring

Why I must set SwitchName property, when I need to remove default Network adapter from VM?

The DSC configuration that is used to reproduce the issue (as detailed as possible)

            xVMNetworkAdapter "RemoveDefaultNIC${RouterOSVM}"
            {
                Id = "${RouterOSVM} default NIC"
                Name = '*'
                SwitchName = '*'
                VMName = $RouterOSVM
                Ensure = 'Absent'
                DependsOn = "[xVMHyperV]${RouterOSVM}"
            }

Version of the DSC module that was used ('dev' if using current dev branch)

dev