This page documents the language specification for the azure package. If you're looking for help working with the inputs, outputs, or functions of azure resources in a Pulumi program, please see the resource documentation for examples and API reference.
maintenance¶
This provider is a derived work of the Terraform Provider distributed under MPL 2.0. If you encounter a bug or missing feature, first check the pulumi/pulumi-azure repo; however, if that doesn’t turn up anything, please consult the source terraform-providers/terraform-provider-azurerm repo.
- class
pulumi_azure.maintenance.AssignmentDedicatedHost(resource_name, opts=None, dedicated_host_id=None, location=None, maintenance_configuration_id=None, __props__=None, __name__=None, __opts__=None)¶ Manages a maintenance assignment to Dedicated Host.
import pulumi import pulumi_azure as azure example_resource_group = azure.core.ResourceGroup("exampleResourceGroup", location="West Europe") example_dedicated_host_group = azure.compute.DedicatedHostGroup("exampleDedicatedHostGroup", resource_group_name=example_resource_group.name, location=example_resource_group.location, platform_fault_domain_count=2) example_dedicated_host = azure.compute.DedicatedHost("exampleDedicatedHost", location=example_resource_group.location, dedicated_host_group_id=example_dedicated_host_group.id, sku_name="DSv3-Type1", platform_fault_domain=1) example_configuration = azure.maintenance.Configuration("exampleConfiguration", resource_group_name=example_resource_group.name, location=example_resource_group.location, scope="All") example_assignment_dedicated_host = azure.maintenance.AssignmentDedicatedHost("exampleAssignmentDedicatedHost", location=example_resource_group.location, maintenance_configuration_id=example_configuration.id, dedicated_host_id=example_dedicated_host.id)
- Parameters
resource_name (str) – The name of the resource.
opts (pulumi.ResourceOptions) – Options for the resource.
dedicated_host_id (pulumi.Input[str]) – Specifies the Dedicated Host ID to which the Maintenance Configuration will be assigned. Changing this forces a new resource to be created.
location (pulumi.Input[str]) – Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
maintenance_configuration_id (pulumi.Input[str]) – Specifies the ID of the Maintenance Configuration Resource. Changing this forces a new resource to be created.
dedicated_host_id: pulumi.Output[str] = None¶Specifies the Dedicated Host ID to which the Maintenance Configuration will be assigned. Changing this forces a new resource to be created.
location: pulumi.Output[str] = None¶Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
maintenance_configuration_id: pulumi.Output[str] = None¶Specifies the ID of the Maintenance Configuration Resource. Changing this forces a new resource to be created.
- static
get(resource_name, id, opts=None, dedicated_host_id=None, location=None, maintenance_configuration_id=None)¶ Get an existing AssignmentDedicatedHost resource’s state with the given name, id, and optional extra properties used to qualify the lookup.
- Parameters
resource_name (str) – The unique name of the resulting resource.
id (str) – The unique provider ID of the resource to lookup.
opts (pulumi.ResourceOptions) – Options for the resource.
dedicated_host_id (pulumi.Input[str]) – Specifies the Dedicated Host ID to which the Maintenance Configuration will be assigned. Changing this forces a new resource to be created.
location (pulumi.Input[str]) – Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
maintenance_configuration_id (pulumi.Input[str]) – Specifies the ID of the Maintenance Configuration Resource. Changing this forces a new resource to be created.
translate_output_property(prop)¶Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
translate_input_property(prop)¶Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
- class
pulumi_azure.maintenance.AssignmentVirtualMachine(resource_name, opts=None, location=None, maintenance_configuration_id=None, virtual_machine_id=None, __props__=None, __name__=None, __opts__=None)¶ Manages a maintenance assignment to virtual machine.
import pulumi import pulumi_azure as azure example_resource_group = azure.core.ResourceGroup("exampleResourceGroup", location="West Europe") example_virtual_network = azure.network.VirtualNetwork("exampleVirtualNetwork", address_spaces=["10.0.0.0/16"], location=example_resource_group.location, resource_group_name=example_resource_group.name) example_subnet = azure.network.Subnet("exampleSubnet", resource_group_name=example_resource_group.name, virtual_network_name=example_virtual_network.name, address_prefix="10.0.2.0/24") example_network_interface = azure.network.NetworkInterface("exampleNetworkInterface", location=example_resource_group.location, resource_group_name=example_resource_group.name, ip_configuration=[{ "name": "internal", "subnet_id": example_subnet.id, "privateIpAddressAllocation": "Dynamic", }]) example_linux_virtual_machine = azure.compute.LinuxVirtualMachine("exampleLinuxVirtualMachine", resource_group_name=example_resource_group.name, location=example_resource_group.location, size="Standard_F2", admin_username="adminuser", network_interface_ids=[example_network_interface.id], admin_ssh_key=[{ "username": "adminuser", "publicKey": (lambda path: open(path).read())("~/.ssh/id_rsa.pub"), }], os_disk={ "caching": "ReadWrite", "storage_account_type": "Standard_LRS", }, source_image_reference={ "publisher": "Canonical", "offer": "UbuntuServer", "sku": "16.04-LTS", "version": "latest", }) example_configuration = azure.maintenance.Configuration("exampleConfiguration", resource_group_name=example_resource_group.name, location=example_resource_group.location, scope="All") example_assignment_virtual_machine = azure.maintenance.AssignmentVirtualMachine("exampleAssignmentVirtualMachine", location=example_resource_group.location, maintenance_configuration_id=example_configuration.id, virtual_machine_id=example_linux_virtual_machine.id)
- Parameters
resource_name (str) – The name of the resource.
opts (pulumi.ResourceOptions) – Options for the resource.
location (pulumi.Input[str]) – Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
maintenance_configuration_id (pulumi.Input[str]) – Specifies the ID of the Maintenance Configuration Resource. Changing this forces a new resource to be created.
virtual_machine_id (pulumi.Input[str]) – Specifies the Virtual Machine ID to which the Maintenance Configuration will be assigned. Changing this forces a new resource to be created.
location: pulumi.Output[str] = None¶Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
maintenance_configuration_id: pulumi.Output[str] = None¶Specifies the ID of the Maintenance Configuration Resource. Changing this forces a new resource to be created.
virtual_machine_id: pulumi.Output[str] = None¶Specifies the Virtual Machine ID to which the Maintenance Configuration will be assigned. Changing this forces a new resource to be created.
- static
get(resource_name, id, opts=None, location=None, maintenance_configuration_id=None, virtual_machine_id=None)¶ Get an existing AssignmentVirtualMachine resource’s state with the given name, id, and optional extra properties used to qualify the lookup.
- Parameters
resource_name (str) – The unique name of the resulting resource.
id (str) – The unique provider ID of the resource to lookup.
opts (pulumi.ResourceOptions) – Options for the resource.
location (pulumi.Input[str]) – Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
maintenance_configuration_id (pulumi.Input[str]) – Specifies the ID of the Maintenance Configuration Resource. Changing this forces a new resource to be created.
virtual_machine_id (pulumi.Input[str]) – Specifies the Virtual Machine ID to which the Maintenance Configuration will be assigned. Changing this forces a new resource to be created.
translate_output_property(prop)¶Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
translate_input_property(prop)¶Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
- class
pulumi_azure.maintenance.AwaitableGetConfigurationResult(id=None, location=None, name=None, resource_group_name=None, scope=None, tags=None)¶
- class
pulumi_azure.maintenance.Configuration(resource_name, opts=None, location=None, name=None, resource_group_name=None, scope=None, tags=None, __props__=None, __name__=None, __opts__=None)¶ Manages a maintenance configuration.
import pulumi import pulumi_azure as azure example_resource_group = azure.core.ResourceGroup("exampleResourceGroup", location="West Europe") example_configuration = azure.maintenance.Configuration("exampleConfiguration", resource_group_name=example_resource_group.name, location=example_resource_group.location, scope="All", tags={ "Env": "prod", })
- Parameters
resource_name (str) – The name of the resource.
opts (pulumi.ResourceOptions) – Options for the resource.
location (pulumi.Input[str]) – Specified the supported Azure location where the resource exists. Changing this forces a new resource to be created.
name (pulumi.Input[str]) – Specifies the name of the Maintenance Configuration. Changing this forces a new resource to be created.
resource_group_name (pulumi.Input[str]) – The name of the Resource Group where the Maintenance Configuration should exist. Changing this forces a new resource to be created.
scope (pulumi.Input[str]) – The scope of the Maintenance Configuration. Possible values are
All,Host,ResourceorInResource. Default toAll.tags (pulumi.Input[dict]) – A mapping of tags to assign to the resource. The key could not contain upper case letter.
location: pulumi.Output[str] = None¶Specified the supported Azure location where the resource exists. Changing this forces a new resource to be created.
name: pulumi.Output[str] = None¶Specifies the name of the Maintenance Configuration. Changing this forces a new resource to be created.
resource_group_name: pulumi.Output[str] = None¶The name of the Resource Group where the Maintenance Configuration should exist. Changing this forces a new resource to be created.
scope: pulumi.Output[str] = None¶The scope of the Maintenance Configuration. Possible values are
All,Host,ResourceorInResource. Default toAll.
A mapping of tags to assign to the resource. The key could not contain upper case letter.
- static
get(resource_name, id, opts=None, location=None, name=None, resource_group_name=None, scope=None, tags=None)¶ Get an existing Configuration resource’s state with the given name, id, and optional extra properties used to qualify the lookup.
- Parameters
resource_name (str) – The unique name of the resulting resource.
id (str) – The unique provider ID of the resource to lookup.
opts (pulumi.ResourceOptions) – Options for the resource.
location (pulumi.Input[str]) – Specified the supported Azure location where the resource exists. Changing this forces a new resource to be created.
name (pulumi.Input[str]) – Specifies the name of the Maintenance Configuration. Changing this forces a new resource to be created.
resource_group_name (pulumi.Input[str]) – The name of the Resource Group where the Maintenance Configuration should exist. Changing this forces a new resource to be created.
scope (pulumi.Input[str]) – The scope of the Maintenance Configuration. Possible values are
All,Host,ResourceorInResource. Default toAll.tags (pulumi.Input[dict]) – A mapping of tags to assign to the resource. The key could not contain upper case letter.
translate_output_property(prop)¶Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
translate_input_property(prop)¶Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.
- Parameters
prop (str) – A property name.
- Returns
A potentially transformed property name.
- Return type
str
- class
pulumi_azure.maintenance.GetConfigurationResult(id=None, location=None, name=None, resource_group_name=None, scope=None, tags=None)¶ A collection of values returned by getConfiguration.
id= None¶The provider-assigned unique ID for this managed resource.
location= None¶The Azure location where the resource exists.
scope= None¶The scope of the Maintenance Configuration.
A mapping of tags assigned to the resource.
pulumi_azure.maintenance.get_configuration(name=None, resource_group_name=None, opts=None)¶Use this data source to access information about an existing Maintenance Configuration.
import pulumi import pulumi_azure as azure existing = azure.maintenance.get_configuration(name="example-mc", resource_group_name="example-resources") pulumi.export("id", azurerm_maintenance_configuration["existing"]["id"])
- Parameters
name (str) – Specifies the name of the Maintenance Configuration.
resource_group_name (str) – Specifies the name of the Resource Group where this Maintenance Configuration exists.