Retrieve the current list:
$curValue = (get-item wsman:\localhost\Client\TrustedHosts).value
Set the new list, appending the new host onto the old list:
set-item wsman:\localhost\Client\TrustedHosts -value "$curValue, Server01.Domain01.Fabrikam.com"
No comments:
Post a Comment