Expand description
Manages a Linux Virtual Machine Scale Set.
§Disclaimers
Note: As of the v2.86.0 (November 19, 2021) release of the provider this resource will only create Virtual Machine Scale Sets with the Uniform Orchestration Mode. For Virtual Machine Scale Sets with Flexible orchestration mode, use
azure.compute.OrchestratedVirtualMachineScaleSet
. Flexible orchestration mode is recommended for workloads on Azure. rraform will automatically update & reimage the nodes in the Scale Set (if Required) during an Update - this behaviour can be configured using thefeatures
setting within the Provider block.
§Example Usage
This example provisions a basic Linux Virtual Machine Scale Set on an internal network.
resources:
example:
type: azure:core:ResourceGroup
properties:
name: example-resources
location: West Europe
exampleVirtualNetwork:
type: azure:network:VirtualNetwork
name: example
properties:
name: example-network
resourceGroupName: ${example.name}
location: ${example.location}
addressSpaces:
- 10.0.0.0/16
internal:
type: azure:network:Subnet
properties:
name: internal
resourceGroupName: ${example.name}
virtualNetworkName: ${exampleVirtualNetwork.name}
addressPrefixes:
- 10.0.2.0/24
exampleLinuxVirtualMachineScaleSet:
type: azure:compute:LinuxVirtualMachineScaleSet
name: example
properties:
name: example-vmss
resourceGroupName: ${example.name}
location: ${example.location}
sku: Standard_F2
instances: 1
adminUsername: adminuser
adminSshKeys:
- username: adminuser
publicKey: ${firstPublicKey}
sourceImageReference:
publisher: Canonical
offer: 0001-com-ubuntu-server-jammy
sku: 22_04-lts
version: latest
osDisk:
storageAccountType: Standard_LRS
caching: ReadWrite
networkInterfaces:
- name: example
primary: true
ipConfigurations:
- name: internal
primary: true
subnetId: ${internal.id}
variables:
firstPublicKey: ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC+wWK73dCr+jgQOAxNsHAnNNNMEMWOHYEccp6wJm2gotpr9katuF/ZAdou5AaW1C61slRkHRkpRRX9FA9CYBiitZgvCCz+3nWNN7l/Up54Zps/pHWGZLHNJZRYyAB6j5yVLMVHIHriY49d/GZTZVNB8GoJv9Gakwc/fuEZYYl4YDFiGMBP///TzlI4jhiJzjKnEvqPFki5p2ZRJqcbCiF4pJrxUQR/RXqVFQdbRLZgYfJ8xGB878RENq3yQ39d8dVOkq4edbkzwcUmwwwkYVPIoDGsYLaRHnG+To7FvMeyO7xDVQkMKzopTQV8AuKpyvpqu0a9pWOMaiCyDytO7GGN you@me.com
§Import
Linux Virtual Machine Scale Sets can be imported using the resource id
, e.g.
$ pulumi import azure:compute/linuxVirtualMachineScaleSet:LinuxVirtualMachineScaleSet example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/mygroup1/providers/Microsoft.Compute/virtualMachineScaleSets/scaleset1
Structs§
- Use builder syntax to set the inputs and finish with
build_struct()
.
Functions§
- Registers a new resource with the given unique name and arguments