Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
Configuration TestPendingReboot{
Import-DSCResource -ModuleName xPendingReboot
Node $ComputerName{
xPendingReboot PreTest{
Name = "Check for a pending reboot before changing anything"
RebootNodeIfNeeded = $True
TestPendingReboot -OutputPath C:\Scripts\TestPendingReboot
Set-DscLocalConfigurationManager -Path C:\Scripts\TestPendingReboot
Start-DscConfiguration -wait -force -verbose -path C:\Scripts\TestPendingReboot
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment