1. Packages
  2. Azure Native
  3. API Docs
  4. maintenance
  5. ConfigurationAssignmentsForResourceGroup
This is the latest version of Azure Native. Use the Azure Native v1 docs if using the v1 version of this package.
Azure Native v2.9.0 published on Wednesday, Sep 27, 2023 by Pulumi

azure-native.maintenance.ConfigurationAssignmentsForResourceGroup

Explore with Pulumi AI

azure-native logo
This is the latest version of Azure Native. Use the Azure Native v1 docs if using the v1 version of this package.
Azure Native v2.9.0 published on Wednesday, Sep 27, 2023 by Pulumi

    Configuration Assignment Azure REST API version: 2023-04-01.

    Example Usage

    ConfigurationAssignmentsForResourceGroup_CreateOrUpdate

    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using AzureNative = Pulumi.AzureNative;
    
    return await Deployment.RunAsync(() => 
    {
        var configurationAssignmentsForResourceGroup = new AzureNative.Maintenance.ConfigurationAssignmentsForResourceGroup("configurationAssignmentsForResourceGroup", new()
        {
            ConfigurationAssignmentName = "workervmConfiguration",
            Filter = new AzureNative.Maintenance.Inputs.ConfigurationAssignmentFilterPropertiesArgs
            {
                Locations = new[]
                {
                    "Japan East",
                    "UK South",
                },
                ResourceTypes = new[]
                {
                    "Microsoft.HybridCompute/machines",
                    "Microsoft.Compute/virtualMachines",
                },
                TagSettings = new AzureNative.Maintenance.Inputs.TagSettingsPropertiesArgs
                {
                    FilterOperator = AzureNative.Maintenance.TagOperators.Any,
                    Tags = 
                    {
                        { "tag1", new[]
                        {
                            "tag1Value1",
                            "tag1Value2",
                            "tag1Value3",
                        } },
                        { "tag2", new[]
                        {
                            "tag2Value1",
                            "tag2Value2",
                            "tag2Value3",
                        } },
                    },
                },
            },
            MaintenanceConfigurationId = "/subscriptions/5b4b650e-28b9-4790-b3ab-ddbd88d727c4/resourcegroups/examplerg/providers/Microsoft.Maintenance/maintenanceConfigurations/configuration1",
            ResourceGroupName = "examplerg",
        });
    
    });
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-azure-native-sdk/maintenance/v2"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := maintenance.NewConfigurationAssignmentsForResourceGroup(ctx, "configurationAssignmentsForResourceGroup", &maintenance.ConfigurationAssignmentsForResourceGroupArgs{
    			ConfigurationAssignmentName: pulumi.String("workervmConfiguration"),
    			Filter: maintenance.ConfigurationAssignmentFilterPropertiesResponse{
    				Locations: pulumi.StringArray{
    					pulumi.String("Japan East"),
    					pulumi.String("UK South"),
    				},
    				ResourceTypes: pulumi.StringArray{
    					pulumi.String("Microsoft.HybridCompute/machines"),
    					pulumi.String("Microsoft.Compute/virtualMachines"),
    				},
    				TagSettings: &maintenance.TagSettingsPropertiesArgs{
    					FilterOperator: maintenance.TagOperatorsAny,
    					Tags: pulumi.StringArrayMap{
    						"tag1": pulumi.StringArray{
    							pulumi.String("tag1Value1"),
    							pulumi.String("tag1Value2"),
    							pulumi.String("tag1Value3"),
    						},
    						"tag2": pulumi.StringArray{
    							pulumi.String("tag2Value1"),
    							pulumi.String("tag2Value2"),
    							pulumi.String("tag2Value3"),
    						},
    					},
    				},
    			},
    			MaintenanceConfigurationId: pulumi.String("/subscriptions/5b4b650e-28b9-4790-b3ab-ddbd88d727c4/resourcegroups/examplerg/providers/Microsoft.Maintenance/maintenanceConfigurations/configuration1"),
    			ResourceGroupName:          pulumi.String("examplerg"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.azurenative.maintenance.ConfigurationAssignmentsForResourceGroup;
    import com.pulumi.azurenative.maintenance.ConfigurationAssignmentsForResourceGroupArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var configurationAssignmentsForResourceGroup = new ConfigurationAssignmentsForResourceGroup("configurationAssignmentsForResourceGroup", ConfigurationAssignmentsForResourceGroupArgs.builder()        
                .configurationAssignmentName("workervmConfiguration")
                .filter(Map.ofEntries(
                    Map.entry("locations",                 
                        "Japan East",
                        "UK South"),
                    Map.entry("resourceTypes",                 
                        "Microsoft.HybridCompute/machines",
                        "Microsoft.Compute/virtualMachines"),
                    Map.entry("tagSettings", Map.ofEntries(
                        Map.entry("filterOperator", "Any"),
                        Map.entry("tags", Map.ofEntries(
                            Map.entry("tag1",                         
                                "tag1Value1",
                                "tag1Value2",
                                "tag1Value3"),
                            Map.entry("tag2",                         
                                "tag2Value1",
                                "tag2Value2",
                                "tag2Value3")
                        ))
                    ))
                ))
                .maintenanceConfigurationId("/subscriptions/5b4b650e-28b9-4790-b3ab-ddbd88d727c4/resourcegroups/examplerg/providers/Microsoft.Maintenance/maintenanceConfigurations/configuration1")
                .resourceGroupName("examplerg")
                .build());
    
        }
    }
    
    import pulumi
    import pulumi_azure_native as azure_native
    
    configuration_assignments_for_resource_group = azure_native.maintenance.ConfigurationAssignmentsForResourceGroup("configurationAssignmentsForResourceGroup",
        configuration_assignment_name="workervmConfiguration",
        filter=azure_native.maintenance.ConfigurationAssignmentFilterPropertiesResponseArgs(
            locations=[
                "Japan East",
                "UK South",
            ],
            resource_types=[
                "Microsoft.HybridCompute/machines",
                "Microsoft.Compute/virtualMachines",
            ],
            tag_settings=azure_native.maintenance.TagSettingsPropertiesArgs(
                filter_operator=azure_native.maintenance.TagOperators.ANY,
                tags={
                    "tag1": [
                        "tag1Value1",
                        "tag1Value2",
                        "tag1Value3",
                    ],
                    "tag2": [
                        "tag2Value1",
                        "tag2Value2",
                        "tag2Value3",
                    ],
                },
            ),
        ),
        maintenance_configuration_id="/subscriptions/5b4b650e-28b9-4790-b3ab-ddbd88d727c4/resourcegroups/examplerg/providers/Microsoft.Maintenance/maintenanceConfigurations/configuration1",
        resource_group_name="examplerg")
    
    import * as pulumi from "@pulumi/pulumi";
    import * as azure_native from "@pulumi/azure-native";
    
    const configurationAssignmentsForResourceGroup = new azure_native.maintenance.ConfigurationAssignmentsForResourceGroup("configurationAssignmentsForResourceGroup", {
        configurationAssignmentName: "workervmConfiguration",
        filter: {
            locations: [
                "Japan East",
                "UK South",
            ],
            resourceTypes: [
                "Microsoft.HybridCompute/machines",
                "Microsoft.Compute/virtualMachines",
            ],
            tagSettings: {
                filterOperator: azure_native.maintenance.TagOperators.Any,
                tags: {
                    tag1: [
                        "tag1Value1",
                        "tag1Value2",
                        "tag1Value3",
                    ],
                    tag2: [
                        "tag2Value1",
                        "tag2Value2",
                        "tag2Value3",
                    ],
                },
            },
        },
        maintenanceConfigurationId: "/subscriptions/5b4b650e-28b9-4790-b3ab-ddbd88d727c4/resourcegroups/examplerg/providers/Microsoft.Maintenance/maintenanceConfigurations/configuration1",
        resourceGroupName: "examplerg",
    });
    
    resources:
      configurationAssignmentsForResourceGroup:
        type: azure-native:maintenance:ConfigurationAssignmentsForResourceGroup
        properties:
          configurationAssignmentName: workervmConfiguration
          filter:
            locations:
              - Japan East
              - UK South
            resourceTypes:
              - Microsoft.HybridCompute/machines
              - Microsoft.Compute/virtualMachines
            tagSettings:
              filterOperator: Any
              tags:
                tag1:
                  - tag1Value1
                  - tag1Value2
                  - tag1Value3
                tag2:
                  - tag2Value1
                  - tag2Value2
                  - tag2Value3
          maintenanceConfigurationId: /subscriptions/5b4b650e-28b9-4790-b3ab-ddbd88d727c4/resourcegroups/examplerg/providers/Microsoft.Maintenance/maintenanceConfigurations/configuration1
          resourceGroupName: examplerg
    

    Create ConfigurationAssignmentsForResourceGroup Resource

    new ConfigurationAssignmentsForResourceGroup(name: string, args: ConfigurationAssignmentsForResourceGroupArgs, opts?: CustomResourceOptions);
    @overload
    def ConfigurationAssignmentsForResourceGroup(resource_name: str,
                                                 opts: Optional[ResourceOptions] = None,
                                                 configuration_assignment_name: Optional[str] = None,
                                                 filter: Optional[ConfigurationAssignmentFilterPropertiesArgs] = None,
                                                 location: Optional[str] = None,
                                                 maintenance_configuration_id: Optional[str] = None,
                                                 resource_group_name: Optional[str] = None,
                                                 resource_id: Optional[str] = None)
    @overload
    def ConfigurationAssignmentsForResourceGroup(resource_name: str,
                                                 args: ConfigurationAssignmentsForResourceGroupArgs,
                                                 opts: Optional[ResourceOptions] = None)
    func NewConfigurationAssignmentsForResourceGroup(ctx *Context, name string, args ConfigurationAssignmentsForResourceGroupArgs, opts ...ResourceOption) (*ConfigurationAssignmentsForResourceGroup, error)
    public ConfigurationAssignmentsForResourceGroup(string name, ConfigurationAssignmentsForResourceGroupArgs args, CustomResourceOptions? opts = null)
    public ConfigurationAssignmentsForResourceGroup(String name, ConfigurationAssignmentsForResourceGroupArgs args)
    public ConfigurationAssignmentsForResourceGroup(String name, ConfigurationAssignmentsForResourceGroupArgs args, CustomResourceOptions options)
    
    type: azure-native:maintenance:ConfigurationAssignmentsForResourceGroup
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    
    name string
    The unique name of the resource.
    args ConfigurationAssignmentsForResourceGroupArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args ConfigurationAssignmentsForResourceGroupArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args ConfigurationAssignmentsForResourceGroupArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args ConfigurationAssignmentsForResourceGroupArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args ConfigurationAssignmentsForResourceGroupArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    ConfigurationAssignmentsForResourceGroup Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    The ConfigurationAssignmentsForResourceGroup resource accepts the following input properties:

    ResourceGroupName string

    Resource group name

    ConfigurationAssignmentName string

    Configuration assignment name

    Filter Pulumi.AzureNative.Maintenance.Inputs.ConfigurationAssignmentFilterProperties

    Properties of the configuration assignment

    Location string

    Location of the resource

    MaintenanceConfigurationId string

    The maintenance configuration Id

    ResourceId string

    The unique resourceId

    ResourceGroupName string

    Resource group name

    ConfigurationAssignmentName string

    Configuration assignment name

    Filter ConfigurationAssignmentFilterPropertiesArgs

    Properties of the configuration assignment

    Location string

    Location of the resource

    MaintenanceConfigurationId string

    The maintenance configuration Id

    ResourceId string

    The unique resourceId

    resourceGroupName String

    Resource group name

    configurationAssignmentName String

    Configuration assignment name

    filter ConfigurationAssignmentFilterProperties

    Properties of the configuration assignment

    location String

    Location of the resource

    maintenanceConfigurationId String

    The maintenance configuration Id

    resourceId String

    The unique resourceId

    resourceGroupName string

    Resource group name

    configurationAssignmentName string

    Configuration assignment name

    filter ConfigurationAssignmentFilterProperties

    Properties of the configuration assignment

    location string

    Location of the resource

    maintenanceConfigurationId string

    The maintenance configuration Id

    resourceId string

    The unique resourceId

    resource_group_name str

    Resource group name

    configuration_assignment_name str

    Configuration assignment name

    filter ConfigurationAssignmentFilterPropertiesArgs

    Properties of the configuration assignment

    location str

    Location of the resource

    maintenance_configuration_id str

    The maintenance configuration Id

    resource_id str

    The unique resourceId

    resourceGroupName String

    Resource group name

    configurationAssignmentName String

    Configuration assignment name

    filter Property Map

    Properties of the configuration assignment

    location String

    Location of the resource

    maintenanceConfigurationId String

    The maintenance configuration Id

    resourceId String

    The unique resourceId

    Outputs

    All input properties are implicitly available as output properties. Additionally, the ConfigurationAssignmentsForResourceGroup resource produces the following output properties:

    Id string

    The provider-assigned unique ID for this managed resource.

    Name string

    Name of the resource

    SystemData Pulumi.AzureNative.Maintenance.Outputs.SystemDataResponse

    Azure Resource Manager metadata containing createdBy and modifiedBy information.

    Type string

    Type of the resource

    Id string

    The provider-assigned unique ID for this managed resource.

    Name string

    Name of the resource

    SystemData SystemDataResponse

    Azure Resource Manager metadata containing createdBy and modifiedBy information.

    Type string

    Type of the resource

    id String

    The provider-assigned unique ID for this managed resource.

    name String

    Name of the resource

    systemData SystemDataResponse

    Azure Resource Manager metadata containing createdBy and modifiedBy information.

    type String

    Type of the resource

    id string

    The provider-assigned unique ID for this managed resource.

    name string

    Name of the resource

    systemData SystemDataResponse

    Azure Resource Manager metadata containing createdBy and modifiedBy information.

    type string

    Type of the resource

    id str

    The provider-assigned unique ID for this managed resource.

    name str

    Name of the resource

    system_data SystemDataResponse

    Azure Resource Manager metadata containing createdBy and modifiedBy information.

    type str

    Type of the resource

    id String

    The provider-assigned unique ID for this managed resource.

    name String

    Name of the resource

    systemData Property Map

    Azure Resource Manager metadata containing createdBy and modifiedBy information.

    type String

    Type of the resource

    Supporting Types

    ConfigurationAssignmentFilterProperties, ConfigurationAssignmentFilterPropertiesArgs

    Locations List<string>

    List of locations to scope the query to.

    OsTypes List<string>

    List of allowed operating systems.

    ResourceGroups List<string>

    List of allowed resource groups.

    ResourceTypes List<string>

    List of allowed resources.

    TagSettings Pulumi.AzureNative.Maintenance.Inputs.TagSettingsProperties

    Tag settings for the VM.

    Locations []string

    List of locations to scope the query to.

    OsTypes []string

    List of allowed operating systems.

    ResourceGroups []string

    List of allowed resource groups.

    ResourceTypes []string

    List of allowed resources.

    TagSettings TagSettingsProperties

    Tag settings for the VM.

    locations List<String>

    List of locations to scope the query to.

    osTypes List<String>

    List of allowed operating systems.

    resourceGroups List<String>

    List of allowed resource groups.

    resourceTypes List<String>

    List of allowed resources.

    tagSettings TagSettingsProperties

    Tag settings for the VM.

    locations string[]

    List of locations to scope the query to.

    osTypes string[]

    List of allowed operating systems.

    resourceGroups string[]

    List of allowed resource groups.

    resourceTypes string[]

    List of allowed resources.

    tagSettings TagSettingsProperties

    Tag settings for the VM.

    locations Sequence[str]

    List of locations to scope the query to.

    os_types Sequence[str]

    List of allowed operating systems.

    resource_groups Sequence[str]

    List of allowed resource groups.

    resource_types Sequence[str]

    List of allowed resources.

    tag_settings TagSettingsProperties

    Tag settings for the VM.

    locations List<String>

    List of locations to scope the query to.

    osTypes List<String>

    List of allowed operating systems.

    resourceGroups List<String>

    List of allowed resource groups.

    resourceTypes List<String>

    List of allowed resources.

    tagSettings Property Map

    Tag settings for the VM.

    ConfigurationAssignmentFilterPropertiesResponse, ConfigurationAssignmentFilterPropertiesResponseArgs

    Locations List<string>

    List of locations to scope the query to.

    OsTypes List<string>

    List of allowed operating systems.

    ResourceGroups List<string>

    List of allowed resource groups.

    ResourceTypes List<string>

    List of allowed resources.

    TagSettings Pulumi.AzureNative.Maintenance.Inputs.TagSettingsPropertiesResponse

    Tag settings for the VM.

    Locations []string

    List of locations to scope the query to.

    OsTypes []string

    List of allowed operating systems.

    ResourceGroups []string

    List of allowed resource groups.

    ResourceTypes []string

    List of allowed resources.

    TagSettings TagSettingsPropertiesResponse

    Tag settings for the VM.

    locations List<String>

    List of locations to scope the query to.

    osTypes List<String>

    List of allowed operating systems.

    resourceGroups List<String>

    List of allowed resource groups.

    resourceTypes List<String>

    List of allowed resources.

    tagSettings TagSettingsPropertiesResponse

    Tag settings for the VM.

    locations string[]

    List of locations to scope the query to.

    osTypes string[]

    List of allowed operating systems.

    resourceGroups string[]

    List of allowed resource groups.

    resourceTypes string[]

    List of allowed resources.

    tagSettings TagSettingsPropertiesResponse

    Tag settings for the VM.

    locations Sequence[str]

    List of locations to scope the query to.

    os_types Sequence[str]

    List of allowed operating systems.

    resource_groups Sequence[str]

    List of allowed resource groups.

    resource_types Sequence[str]

    List of allowed resources.

    tag_settings TagSettingsPropertiesResponse

    Tag settings for the VM.

    locations List<String>

    List of locations to scope the query to.

    osTypes List<String>

    List of allowed operating systems.

    resourceGroups List<String>

    List of allowed resource groups.

    resourceTypes List<String>

    List of allowed resources.

    tagSettings Property Map

    Tag settings for the VM.

    SystemDataResponse, SystemDataResponseArgs

    CreatedAt string

    The timestamp of resource creation (UTC).

    CreatedBy string

    The identity that created the resource.

    CreatedByType string

    The type of identity that created the resource.

    LastModifiedAt string

    The timestamp of resource last modification (UTC)

    LastModifiedBy string

    The identity that last modified the resource.

    LastModifiedByType string

    The type of identity that last modified the resource.

    CreatedAt string

    The timestamp of resource creation (UTC).

    CreatedBy string

    The identity that created the resource.

    CreatedByType string

    The type of identity that created the resource.

    LastModifiedAt string

    The timestamp of resource last modification (UTC)

    LastModifiedBy string

    The identity that last modified the resource.

    LastModifiedByType string

    The type of identity that last modified the resource.

    createdAt String

    The timestamp of resource creation (UTC).

    createdBy String

    The identity that created the resource.

    createdByType String

    The type of identity that created the resource.

    lastModifiedAt String

    The timestamp of resource last modification (UTC)

    lastModifiedBy String

    The identity that last modified the resource.

    lastModifiedByType String

    The type of identity that last modified the resource.

    createdAt string

    The timestamp of resource creation (UTC).

    createdBy string

    The identity that created the resource.

    createdByType string

    The type of identity that created the resource.

    lastModifiedAt string

    The timestamp of resource last modification (UTC)

    lastModifiedBy string

    The identity that last modified the resource.

    lastModifiedByType string

    The type of identity that last modified the resource.

    created_at str

    The timestamp of resource creation (UTC).

    created_by str

    The identity that created the resource.

    created_by_type str

    The type of identity that created the resource.

    last_modified_at str

    The timestamp of resource last modification (UTC)

    last_modified_by str

    The identity that last modified the resource.

    last_modified_by_type str

    The type of identity that last modified the resource.

    createdAt String

    The timestamp of resource creation (UTC).

    createdBy String

    The identity that created the resource.

    createdByType String

    The type of identity that created the resource.

    lastModifiedAt String

    The timestamp of resource last modification (UTC)

    lastModifiedBy String

    The identity that last modified the resource.

    lastModifiedByType String

    The type of identity that last modified the resource.

    TagOperators, TagOperatorsArgs

    All
    All
    Any
    Any
    TagOperatorsAll
    All
    TagOperatorsAny
    Any
    All
    All
    Any
    Any
    All
    All
    Any
    Any
    ALL
    All
    ANY
    Any
    "All"
    All
    "Any"
    Any

    TagSettingsProperties, TagSettingsPropertiesArgs

    FilterOperator Pulumi.AzureNative.Maintenance.TagOperators

    Filter VMs by Any or All specified tags.

    Tags Dictionary<string, ImmutableArray<string>>

    Dictionary of tags with its list of values.

    FilterOperator TagOperators

    Filter VMs by Any or All specified tags.

    Tags map[string][]string

    Dictionary of tags with its list of values.

    filterOperator TagOperators

    Filter VMs by Any or All specified tags.

    tags Map<String,List<String>>

    Dictionary of tags with its list of values.

    filterOperator TagOperators

    Filter VMs by Any or All specified tags.

    tags {[key: string]: string[]}

    Dictionary of tags with its list of values.

    filter_operator TagOperators

    Filter VMs by Any or All specified tags.

    tags Mapping[str, Sequence[str]]

    Dictionary of tags with its list of values.

    filterOperator "All" | "Any"

    Filter VMs by Any or All specified tags.

    tags Map<List<String>>

    Dictionary of tags with its list of values.

    TagSettingsPropertiesResponse, TagSettingsPropertiesResponseArgs

    FilterOperator string

    Filter VMs by Any or All specified tags.

    Tags Dictionary<string, ImmutableArray<string>>

    Dictionary of tags with its list of values.

    FilterOperator string

    Filter VMs by Any or All specified tags.

    Tags map[string][]string

    Dictionary of tags with its list of values.

    filterOperator String

    Filter VMs by Any or All specified tags.

    tags Map<String,List<String>>

    Dictionary of tags with its list of values.

    filterOperator string

    Filter VMs by Any or All specified tags.

    tags {[key: string]: string[]}

    Dictionary of tags with its list of values.

    filter_operator str

    Filter VMs by Any or All specified tags.

    tags Mapping[str, Sequence[str]]

    Dictionary of tags with its list of values.

    filterOperator String

    Filter VMs by Any or All specified tags.

    tags Map<List<String>>

    Dictionary of tags with its list of values.

    Import

    An existing resource can be imported using its type token, name, and identifier, e.g.

    $ pulumi import azure-native:maintenance:ConfigurationAssignmentsForResourceGroup workervmConfiguration /subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Maintenance/configurationAssignments/{configurationAssignmentName} 
    

    Package Details

    Repository
    Azure Native pulumi/pulumi-azure-native
    License
    Apache-2.0
    azure-native logo
    This is the latest version of Azure Native. Use the Azure Native v1 docs if using the v1 version of this package.
    Azure Native v2.9.0 published on Wednesday, Sep 27, 2023 by Pulumi