The first command assigns a user name to the $User variable.
The second command converts a plain text password into a secure string by using the ConvertTo-SecureString cmdlet.
The command stores that object in the $Password variable.
The third command creates a credential based on $User and $Password, and then stores it in the $Credential variable.
The final command modifies the Automation credential named ContosoCredential to use the credential in $Credential.
Parameters
-AutomationAccountName
Specifies the name of the Automation account for which this cmdlet modifies a credential.
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable,
-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable,
-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see
about_CommonParameters.
L'origine di questo contenuto è disponibile in GitHub, in cui è anche possibile creare ed esaminare i problemi e le richieste pull. Per ulteriori informazioni, vedere la guida per i collaboratori.