Previous Topic: xo-credential - Convert a String to a PSCredential ObjectNext Topic: Set-HostUserCredential - Set the User Credentials Property  for a Host


Add-Credential - Add Credentials to a Host

The Add-Credential command lets you add credentials to host.

Syntax

Add-Credential [-Credentials] <PSCredential> [-Host] <String> [[-Port] <UInt32>]]
Parameters
Credentials

The PowerShell credential object of the host. You can create this credential object using xo-credential cmdlet.

Host

The host name or IP address of the host on which you want to apply the credentials to.

Port

The port number of the host.

Default: 25000.

Example:

$c = xo-credential "administrator" "Password";
Add-Credential $c "9.182.102.229" 25000