Some servers need to shutdown to conserve power - its our only planet!
#create a scheduled taks that will shutdown the VM after 5 mins, at 7pm
$action = New-ScheduledTaskAction -Execute 'C:\Windows\System32\shutdown.exe' -Argument ' /s /t 1 /f /c "shutting down for the day..."'
$trigger = New-ScheduledTaskTrigger -Daily -At 7pm
Register-ScheduledTask -Action $action -Trigger $trigger -TaskName "Automated Shutdown" -Description "Business policy is to shutdown VMs at 7pm daily" -User "$env:USERDOMAIN\$env:USERNAME" -Password 'DWProduct@1'