Box 1: WindowsFeatureThe WindowsFeature resource in Windows PowerShell Desired State Configuration (DSC) provides a mechanism to ensure that roles and features are added or removed on a target node. Box 2: PresentThe Ensure Property indicates if the role or feature is added. To ensure that the role or feature is added, set this property to "Present" To ensure that the role or feature is removed, set the property to "Absent". Example:WindowsFeature RoleExample { Ensure = "Present" # Alternatively, to ensure the role is uninstalled, set Ensure to "Absent" Name = "Web-Server"# Use the Name property from Get-WindowsFeature } Box 3: ServiceThe Service resource in Windows PowerShell Desired State Configuration (DSC) provides a mechanism to manage services on the target node. Box 4: RunningThe State property indicates the state, either Running or Stopped, you want to ensure for the service. References:https://msdn.microsoft.com/en-us/powershell/dsc/windowsfeatureresourcehttps://msdn.microsoft.com/en-us/powershell/dsc/serviceresource
Box 1: WindowsFeature
The WindowsFeature resource in Windows PowerShell Desired State Configuration (DSC) provides a mechanism to ensure that roles and features are added or removed on a target node.
Box 2: Present
The Ensure Property indicates if the role or feature is added. To ensure that the role or feature is added, set this property to "Present" To ensure that the role or feature is removed, set the property to "Absent".
Example:
WindowsFeature RoleExample
{
Ensure = "Present"
# Alternatively, to ensure the role is uninstalled, set Ensure to "Absent"
Name = "Web-Server"# Use the Name property from Get-WindowsFeature
}
Box 3: Service
The Service resource in Windows PowerShell Desired State Configuration (DSC) provides a mechanism to manage services on the target node.
Box 4: Running
The State property indicates the state, either Running or Stopped, you want to ensure for the service.
References:
https://msdn.microsoft.com/en-us/powershell/dsc/windowsfeatureresource
https://msdn.microsoft.com/en-us/powershell/dsc/serviceresource