Microsoft.Compute virtualMachineScaleSets/virtualMachines/extensions 2021-11-01

Bicep resource definition

The virtualMachineScaleSets/virtualMachines/extensions resource type can be deployed with operations that target:

For a list of changed properties in each API version, see change log.

Resource format

To create a Microsoft.Compute/virtualMachineScaleSets/virtualMachines/extensions resource, add the following Bicep to your template.

resource symbolicname 'Microsoft.Compute/virtualMachineScaleSets/virtualMachines/extensions@2021-11-01' = {
  name: 'string'
  parent: resourceSymbolicName
  properties: {
    autoUpgradeMinorVersion: bool
    enableAutomaticUpgrade: bool
    forceUpdateTag: 'string'
    instanceView: {
      name: 'string'
      statuses: [
        {
          code: 'string'
          displayStatus: 'string'
          level: 'string'
          message: 'string'
          time: 'string'
        }
      ]
      substatuses: [
        {
          code: 'string'
          displayStatus: 'string'
          level: 'string'
          message: 'string'
          time: 'string'
        }
      ]
      type: 'string'
      typeHandlerVersion: 'string'
    }
    protectedSettings: any()
    protectedSettingsFromKeyVault: any()
    publisher: 'string'
    settings: any()
    suppressFailures: bool
    type: 'string'
    typeHandlerVersion: 'string'
  }
}

Property values

virtualMachineScaleSets/virtualMachines/extensions

Name Description Value
name The resource name

See how to set names and types for child resources in Bicep.
string (required)
parent In Bicep, you can specify the parent resource for a child resource. You only need to add this property when the child resource is declared outside of the parent resource.

For more information, see Child resource outside parent resource.
Symbolic name for resource of type: virtualMachines
properties Describes the properties of a Virtual Machine Extension. VirtualMachineExtensionProperties

VirtualMachineExtensionProperties

Name Description Value
autoUpgradeMinorVersion Indicates whether the extension should use a newer minor version if one is available at deployment time. Once deployed, however, the extension will not upgrade minor versions unless redeployed, even with this property set to true. bool
enableAutomaticUpgrade Indicates whether the extension should be automatically upgraded by the platform if there is a newer version of the extension available. bool
forceUpdateTag How the extension handler should be forced to update even if the extension configuration has not changed. string
instanceView The virtual machine extension instance view. VirtualMachineExtensionInstanceView
protectedSettings The extension can contain either protectedSettings or protectedSettingsFromKeyVault or no protected settings at all. For Bicep, you can use the any() function.
protectedSettingsFromKeyVault The extensions protected settings that are passed by reference, and consumed from key vault For Bicep, you can use the any() function.
publisher The name of the extension handler publisher. string
settings Json formatted public settings for the extension. For Bicep, you can use the any() function.
suppressFailures Indicates whether failures stemming from the extension will be suppressed (Operational failures such as not connecting to the VM will not be suppressed regardless of this value). The default is false. bool
type Specifies the type of the extension; an example is "CustomScriptExtension". string
typeHandlerVersion Specifies the version of the script handler. string

VirtualMachineExtensionInstanceView

Name Description Value
name The virtual machine extension name. string
statuses The resource status information. InstanceViewStatus[]
substatuses The resource status information. InstanceViewStatus[]
type Specifies the type of the extension; an example is "CustomScriptExtension". string
typeHandlerVersion Specifies the version of the script handler. string

InstanceViewStatus

Name Description Value
code The status code. string
displayStatus The short localizable label for the status. string
level The level code. 'Error'
'Info'
'Warning'
message The detailed status message, including for alerts and error messages. string
time The time of the status. string

ARM template resource definition

The virtualMachineScaleSets/virtualMachines/extensions resource type can be deployed with operations that target:

For a list of changed properties in each API version, see change log.

Resource format

To create a Microsoft.Compute/virtualMachineScaleSets/virtualMachines/extensions resource, add the following JSON to your template.

{
  "type": "Microsoft.Compute/virtualMachineScaleSets/virtualMachines/extensions",
  "apiVersion": "2021-11-01",
  "name": "string",
  "properties": {
    "autoUpgradeMinorVersion": "bool",
    "enableAutomaticUpgrade": "bool",
    "forceUpdateTag": "string",
    "instanceView": {
      "name": "string",
      "statuses": [
        {
          "code": "string",
          "displayStatus": "string",
          "level": "string",
          "message": "string",
          "time": "string"
        }
      ],
      "substatuses": [
        {
          "code": "string",
          "displayStatus": "string",
          "level": "string",
          "message": "string",
          "time": "string"
        }
      ],
      "type": "string",
      "typeHandlerVersion": "string"
    },
    "protectedSettings": {},
    "protectedSettingsFromKeyVault": {},
    "publisher": "string",
    "settings": {},
    "suppressFailures": "bool",
    "type": "string",
    "typeHandlerVersion": "string"
  }
}

Property values

virtualMachineScaleSets/virtualMachines/extensions

Name Description Value
type The resource type 'Microsoft.Compute/virtualMachineScaleSets/virtualMachines/extensions'
apiVersion The resource api version '2021-11-01'
name The resource name

See how to set names and types for child resources in JSON ARM templates.
string (required)
properties Describes the properties of a Virtual Machine Extension. VirtualMachineExtensionProperties

VirtualMachineExtensionProperties

Name Description Value
autoUpgradeMinorVersion Indicates whether the extension should use a newer minor version if one is available at deployment time. Once deployed, however, the extension will not upgrade minor versions unless redeployed, even with this property set to true. bool
enableAutomaticUpgrade Indicates whether the extension should be automatically upgraded by the platform if there is a newer version of the extension available. bool
forceUpdateTag How the extension handler should be forced to update even if the extension configuration has not changed. string
instanceView The virtual machine extension instance view. VirtualMachineExtensionInstanceView
protectedSettings The extension can contain either protectedSettings or protectedSettingsFromKeyVault or no protected settings at all.
protectedSettingsFromKeyVault The extensions protected settings that are passed by reference, and consumed from key vault
publisher The name of the extension handler publisher. string
settings Json formatted public settings for the extension.
suppressFailures Indicates whether failures stemming from the extension will be suppressed (Operational failures such as not connecting to the VM will not be suppressed regardless of this value). The default is false. bool
type Specifies the type of the extension; an example is "CustomScriptExtension". string
typeHandlerVersion Specifies the version of the script handler. string

VirtualMachineExtensionInstanceView

Name Description Value
name The virtual machine extension name. string
statuses The resource status information. InstanceViewStatus[]
substatuses The resource status information. InstanceViewStatus[]
type Specifies the type of the extension; an example is "CustomScriptExtension". string
typeHandlerVersion Specifies the version of the script handler. string

InstanceViewStatus

Name Description Value
code The status code. string
displayStatus The short localizable label for the status. string
level The level code. 'Error'
'Info'
'Warning'
message The detailed status message, including for alerts and error messages. string
time The time of the status. string

Terraform (AzAPI provider) resource definition

The virtualMachineScaleSets/virtualMachines/extensions resource type can be deployed with operations that target:

  • Resource groups

For a list of changed properties in each API version, see change log.

Resource format

To create a Microsoft.Compute/virtualMachineScaleSets/virtualMachines/extensions resource, add the following Terraform to your template.

resource "azapi_resource" "symbolicname" {
  type = "Microsoft.Compute/virtualMachineScaleSets/virtualMachines/extensions@2021-11-01"
  name = "string"
  parent_id = "string"
  body = jsonencode({
    properties = {
      autoUpgradeMinorVersion = bool
      enableAutomaticUpgrade = bool
      forceUpdateTag = "string"
      instanceView = {
        name = "string"
        statuses = [
          {
            code = "string"
            displayStatus = "string"
            level = "string"
            message = "string"
            time = "string"
          }
        ]
        substatuses = [
          {
            code = "string"
            displayStatus = "string"
            level = "string"
            message = "string"
            time = "string"
          }
        ]
        type = "string"
        typeHandlerVersion = "string"
      }
      publisher = "string"
      suppressFailures = bool
      type = "string"
      typeHandlerVersion = "string"
    }
  })
}

Property values

virtualMachineScaleSets/virtualMachines/extensions

Name Description Value
type The resource type "Microsoft.Compute/virtualMachineScaleSets/virtualMachines/extensions@2021-11-01"
name The resource name string (required)
parent_id The ID of the resource that is the parent for this resource. ID for resource of type: virtualMachines
properties Describes the properties of a Virtual Machine Extension. VirtualMachineExtensionProperties

VirtualMachineExtensionProperties

Name Description Value
autoUpgradeMinorVersion Indicates whether the extension should use a newer minor version if one is available at deployment time. Once deployed, however, the extension will not upgrade minor versions unless redeployed, even with this property set to true. bool
enableAutomaticUpgrade Indicates whether the extension should be automatically upgraded by the platform if there is a newer version of the extension available. bool
forceUpdateTag How the extension handler should be forced to update even if the extension configuration has not changed. string
instanceView The virtual machine extension instance view. VirtualMachineExtensionInstanceView
protectedSettings The extension can contain either protectedSettings or protectedSettingsFromKeyVault or no protected settings at all.
protectedSettingsFromKeyVault The extensions protected settings that are passed by reference, and consumed from key vault
publisher The name of the extension handler publisher. string
settings Json formatted public settings for the extension.
suppressFailures Indicates whether failures stemming from the extension will be suppressed (Operational failures such as not connecting to the VM will not be suppressed regardless of this value). The default is false. bool
type Specifies the type of the extension; an example is "CustomScriptExtension". string
typeHandlerVersion Specifies the version of the script handler. string

VirtualMachineExtensionInstanceView

Name Description Value
name The virtual machine extension name. string
statuses The resource status information. InstanceViewStatus[]
substatuses The resource status information. InstanceViewStatus[]
type Specifies the type of the extension; an example is "CustomScriptExtension". string
typeHandlerVersion Specifies the version of the script handler. string

InstanceViewStatus

Name Description Value
code The status code. string
displayStatus The short localizable label for the status. string
level The level code. "Error"
"Info"
"Warning"
message The detailed status message, including for alerts and error messages. string
time The time of the status. string