Scenarios - RemoteDesktopServices

This small lab deploys Remote Desktop Services and a session collection called AutomatedLab. After the deployment, the environment can be accessed through the modern RDWeb client.

    # Select platform, defaults to HyperV
    $Hypervisor = 'HyperV'

New-LabDefinition -Name RDS -DefaultVirtualizationEngine $Hypervisor

Add-LabDomainDefinition -Name -AdminUser Install -AdminPassword Somepass1
Set-LabInstallationCredential -Username Install -Password Somepass1

$PSDefaultParameterValues = @{
    'Add-LabMachineDefinition:ToolsPath'       = "$labSources\Tools"
    'Add-LabMachineDefinition:DomainName'      = ''
    'Add-LabMachineDefinition:OperatingSystem' = 'Windows Server 2019 Datacenter (Desktop Experience)'
    'Add-LabMachineDefinition:Memory'          = 4gb

# Base infra: Domain and Certificate Authority
Add-LabMachineDefinition -Name RDSDC01 -Role RootDc -Domain -OperatingSystem 'Windows Server 2019 Datacenter'
Add-LabMachineDefinition -Name RDSCA01 -Role CaRoot -Domain -OperatingSystem 'Windows Server 2019 Datacenter'

# Gateway and Web
Add-LabMachineDefinition -Name RDSGW01 -Role RemoteDesktopGateway, RemoteDesktopWebAccess

# Connection Broker and Licensing
Add-LabMachineDefinition -Name RDSCB01 -Role RemoteDesktopConnectionBroker, RemoteDesktopLicensing

# Session Host Pool, automatically assigned to collection AutomatedLab
foreach ($count in 1..2)
    Add-LabMachineDefinition -Name RDSSH0$count -Roles RemoteDesktopSessionHost