AZVMExtension Error

Umesh Vangapalli 1 Reputation point
2023-01-06T07:47:23.07+00:00

Hi,

I'm trying to import a certificate which is stored in Key Vault. I'm using below Script and receiving error

$fileUri = @("https://name.blob.core.windows.net/wildcardcert/Certificate.PS1")

$settings = @{"fileUris" = $fileUri};

$storageAcctName = "name"
$storageKey = "/key"
$protectedSettings = @{"storageAccountName" = $storageAcctName; "storageAccountKey" = $storageKey; "commandToExecute" = "powershell -ExecutionPolicy Unrestricted -File Certificate.ps1"};

run command

Set-AzVMExtension -ResourceGroupName ResourceName
-Location "Australia East"
-VMName "name"
-Name "IIS"
-Publisher "Microsoft.Compute"
-ExtensionType "CustomScriptExtension"
-TypeHandlerVersion "1.10"
-Settings $settings
-ProtectedSettings $protectedSettings;

Error:

276795-image.png

Internet Information Services
Azure Virtual Machines
Azure Virtual Machines
An Azure service that is used to provision Windows and Linux virtual machines.
7,086 questions
{count} votes