To automatically create a Hyper-V compute cluster you could use DSC. This recipe shows you how to create a two-node and domain-joined cluster. Please note that DSC is a feature of Windows PowerShell. This recipe cannot be completed using only PowerShell Core.
Creating a compute cluster with DSC
Getting ready
We will be using the lab VMs, PACKT-HV1 and PACKT-HV2.
How to do it...
Let's perform the following steps:
- We start the configuration data, so create a hashtable for DSC:
$confData = @{
# Reserved Key first
AllNodes = @( )
}
- Inside the AllNodes key, add...