SALES: 1-800-867-1380

New-AzureCertificateSetting

[This topic is pre-release documentation and is subject to change in future releases. Blank topics are included as placeholders.]

New-AzureCertificateSetting

Creates a setting object to insert an existing certificate into new Windows Azure virtual machines.

 

Parameter Set: Default
New-AzureCertificateSetting [[-StoreName] <String> ] [-Thumbprint] <String> [ <CommonParameters>]




 

This topic describes the cmdlet in the .6.19 version of the Windows Azure PowerShell module. To find out the version of the module you're using, from the Windows Azure PowerShell console, type (get-module azure).version.

The New-AzureCertificateSetting cmdlet creates a certificate setting object for a certificate that has already been added to Windows Azure. This certificate setting object can be used by the Add-AzureProvisioningConfig cmdlet when creating the configuration object for a new virtual machine using the New-AzureVM or New-AzureQuickVM cmdlet. When included as part of a script to create a virtual machine, this cmdlet adds the specified certificate to the new virtual machine.

 

-StoreName<String>

Specifies the certificate store to place the certificate in.


Aliases

none

Required?

false

Position?

1

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Thumbprint<String>

Specifies the thumbprint of the certificate.


Aliases

none

Required?

true

Position?

2

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

<CommonParameters>

This cmdlet supports the common parameters: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer, and -OutVariable. For more information, see  about_CommonParameters (http://go.microsoft.com/fwlink/p/?LinkID=113216).

Inputs

The input type is the type of the objects that you can pipe to the cmdlet.

Outputs

The output type is the type of the objects that the cmdlet emits.

 

Example 1

This command creates a certificate setting object for an existing certificate and then stores the object in a variable for later use.


C:\PS> $myWinCert = New-AzureCertificateSetting –Thumbprint "D7BECD4D63EBAF86023BB4F1A5FBF5C2C924902A" –StoreName "My" 

Example 2

This command adds a certificate to the Windows Azure service, and then creates a new Windows virtual machine that uses the certificate.


C:\PS> Add-AzureCertificate –ServiceName "MySvc" –CertToDeploy "C:\temp\MyWinCert.cer"
C:\PS> $myWinCert = New-AzureCertificateSetting –Thumbprint "D7BECD4D63EBAF86023BB4F1A5FBF5C2C924902A" –StoreName "My" 
C:\PC> New-AzureVMConfig -Name "MyVM2" -InstanceSize Small -ImageName $winImage `
 | Add-AzureProvisioningConfig -Windows -Certificates $myWinCert -Password 'pass@word1' ` | New-AzureVM -ServiceName "MySvc"

Related topics

Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft