azure-native-v2.extendedlocation.ResourceSyncRule
Explore with Pulumi AI
Resource Sync Rules definition. Azure REST API version: 2021-08-31-preview. Prior API version in Azure Native 1.x: 2021-08-31-preview.
Create ResourceSyncRule Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new ResourceSyncRule(name: string, args: ResourceSyncRuleArgs, opts?: CustomResourceOptions);
@overload
def ResourceSyncRule(resource_name: str,
args: ResourceSyncRuleArgs,
opts: Optional[ResourceOptions] = None)
@overload
def ResourceSyncRule(resource_name: str,
opts: Optional[ResourceOptions] = None,
resource_group_name: Optional[str] = None,
resource_name_: Optional[str] = None,
child_resource_name: Optional[str] = None,
location: Optional[str] = None,
priority: Optional[int] = None,
selector: Optional[ResourceSyncRulePropertiesSelectorArgs] = None,
tags: Optional[Mapping[str, str]] = None,
target_resource_group: Optional[str] = None)
func NewResourceSyncRule(ctx *Context, name string, args ResourceSyncRuleArgs, opts ...ResourceOption) (*ResourceSyncRule, error)
public ResourceSyncRule(string name, ResourceSyncRuleArgs args, CustomResourceOptions? opts = null)
public ResourceSyncRule(String name, ResourceSyncRuleArgs args)
public ResourceSyncRule(String name, ResourceSyncRuleArgs args, CustomResourceOptions options)
type: azure-native:extendedlocation:ResourceSyncRule
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name
This property is required. string - The unique name of the resource.
- args
This property is required. ResourceSyncRuleArgs - The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name
This property is required. str - The unique name of the resource.
- args
This property is required. ResourceSyncRuleArgs - The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name
This property is required. string - The unique name of the resource.
- args
This property is required. ResourceSyncRuleArgs - The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name
This property is required. string - The unique name of the resource.
- args
This property is required. ResourceSyncRuleArgs - The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name
This property is required. String - The unique name of the resource.
- args
This property is required. ResourceSyncRuleArgs - The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var resourceSyncRuleResource = new AzureNative.Extendedlocation.ResourceSyncRule("resourceSyncRuleResource", new()
{
ResourceGroupName = "string",
ResourceName = "string",
ChildResourceName = "string",
Location = "string",
Priority = 0,
Selector =
{
{ "matchLabels",
{
{ "string", "string" },
} },
},
Tags =
{
{ "string", "string" },
},
TargetResourceGroup = "string",
});
example, err := extendedlocation.NewResourceSyncRule(ctx, "resourceSyncRuleResource", &extendedlocation.ResourceSyncRuleArgs{
ResourceGroupName: "string",
ResourceName: "string",
ChildResourceName: "string",
Location: "string",
Priority: 0,
Selector: map[string]interface{}{
"matchLabels": map[string]interface{}{
"string": "string",
},
},
Tags: map[string]interface{}{
"string": "string",
},
TargetResourceGroup: "string",
})
var resourceSyncRuleResource = new ResourceSyncRule("resourceSyncRuleResource", ResourceSyncRuleArgs.builder()
.resourceGroupName("string")
.resourceName("string")
.childResourceName("string")
.location("string")
.priority(0)
.selector(%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference))
.tags(%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference))
.targetResourceGroup("string")
.build());
resource_sync_rule_resource = azure_native.extendedlocation.ResourceSyncRule("resourceSyncRuleResource",
resource_group_name=string,
resource_name_=string,
child_resource_name=string,
location=string,
priority=0,
selector={
matchLabels: {
string: string,
},
},
tags={
string: string,
},
target_resource_group=string)
const resourceSyncRuleResource = new azure_native.extendedlocation.ResourceSyncRule("resourceSyncRuleResource", {
resourceGroupName: "string",
resourceName: "string",
childResourceName: "string",
location: "string",
priority: 0,
selector: {
matchLabels: {
string: "string",
},
},
tags: {
string: "string",
},
targetResourceGroup: "string",
});
type: azure-native:extendedlocation:ResourceSyncRule
properties:
childResourceName: string
location: string
priority: 0
resourceGroupName: string
resourceName: string
selector:
matchLabels:
string: string
tags:
string: string
targetResourceGroup: string
ResourceSyncRule Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The ResourceSyncRule resource accepts the following input properties:
- Resource
Group Name This property is required. Changes to this property will trigger replacement.
- The name of the resource group. The name is case insensitive.
- Resource
Name This property is required. Changes to this property will trigger replacement.
- Custom Locations name.
- Child
Resource Name Changes to this property will trigger replacement.
- Resource Sync Rule name.
- Location
Changes to this property will trigger replacement.
- The geo-location where the resource lives
- Priority int
- Priority represents a priority of the Resource Sync Rule
- Selector
Pulumi.
Azure Native. Extended Location. Inputs. Resource Sync Rule Properties Selector - A label selector is composed of two parts, matchLabels and matchExpressions. The first part, matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'. The second part, matchExpressions is a list of resource selector requirements. Valid operators include In, NotIn, Exists, and DoesNotExist. The values set must be non-empty in the case of In and NotIn. The values set must be empty in the case of Exists and DoesNotExist. All of the requirements, from both matchLabels and matchExpressions must all be satisfied in order to match.
- Dictionary<string, string>
- Resource tags.
- Target
Resource stringGroup - For an unmapped custom resource, its labels will be used to find matching resource sync rules. If this resource sync rule is one of the matching rules with highest priority, then the unmapped custom resource will be projected to the target resource group associated with this resource sync rule. The user creating this resource sync rule should have write permissions on the target resource group and this write permission will be validated when creating the resource sync rule.
- Resource
Group Name This property is required. Changes to this property will trigger replacement.
- The name of the resource group. The name is case insensitive.
- Resource
Name This property is required. Changes to this property will trigger replacement.
- Custom Locations name.
- Child
Resource Name Changes to this property will trigger replacement.
- Resource Sync Rule name.
- Location
Changes to this property will trigger replacement.
- The geo-location where the resource lives
- Priority int
- Priority represents a priority of the Resource Sync Rule
- Selector
Resource
Sync Rule Properties Selector Args - A label selector is composed of two parts, matchLabels and matchExpressions. The first part, matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'. The second part, matchExpressions is a list of resource selector requirements. Valid operators include In, NotIn, Exists, and DoesNotExist. The values set must be non-empty in the case of In and NotIn. The values set must be empty in the case of Exists and DoesNotExist. All of the requirements, from both matchLabels and matchExpressions must all be satisfied in order to match.
- map[string]string
- Resource tags.
- Target
Resource stringGroup - For an unmapped custom resource, its labels will be used to find matching resource sync rules. If this resource sync rule is one of the matching rules with highest priority, then the unmapped custom resource will be projected to the target resource group associated with this resource sync rule. The user creating this resource sync rule should have write permissions on the target resource group and this write permission will be validated when creating the resource sync rule.
- resource
Group Name This property is required. Changes to this property will trigger replacement.
- The name of the resource group. The name is case insensitive.
- resource
Name This property is required. Changes to this property will trigger replacement.
- Custom Locations name.
- child
Resource Name Changes to this property will trigger replacement.
- Resource Sync Rule name.
- location
Changes to this property will trigger replacement.
- The geo-location where the resource lives
- priority Integer
- Priority represents a priority of the Resource Sync Rule
- selector
Resource
Sync Rule Properties Selector - A label selector is composed of two parts, matchLabels and matchExpressions. The first part, matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'. The second part, matchExpressions is a list of resource selector requirements. Valid operators include In, NotIn, Exists, and DoesNotExist. The values set must be non-empty in the case of In and NotIn. The values set must be empty in the case of Exists and DoesNotExist. All of the requirements, from both matchLabels and matchExpressions must all be satisfied in order to match.
- Map<String,String>
- Resource tags.
- target
Resource StringGroup - For an unmapped custom resource, its labels will be used to find matching resource sync rules. If this resource sync rule is one of the matching rules with highest priority, then the unmapped custom resource will be projected to the target resource group associated with this resource sync rule. The user creating this resource sync rule should have write permissions on the target resource group and this write permission will be validated when creating the resource sync rule.
- resource
Group Name This property is required. Changes to this property will trigger replacement.
- The name of the resource group. The name is case insensitive.
- resource
Name This property is required. Changes to this property will trigger replacement.
- Custom Locations name.
- child
Resource Name Changes to this property will trigger replacement.
- Resource Sync Rule name.
- location
Changes to this property will trigger replacement.
- The geo-location where the resource lives
- priority number
- Priority represents a priority of the Resource Sync Rule
- selector
Resource
Sync Rule Properties Selector - A label selector is composed of two parts, matchLabels and matchExpressions. The first part, matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'. The second part, matchExpressions is a list of resource selector requirements. Valid operators include In, NotIn, Exists, and DoesNotExist. The values set must be non-empty in the case of In and NotIn. The values set must be empty in the case of Exists and DoesNotExist. All of the requirements, from both matchLabels and matchExpressions must all be satisfied in order to match.
- {[key: string]: string}
- Resource tags.
- target
Resource stringGroup - For an unmapped custom resource, its labels will be used to find matching resource sync rules. If this resource sync rule is one of the matching rules with highest priority, then the unmapped custom resource will be projected to the target resource group associated with this resource sync rule. The user creating this resource sync rule should have write permissions on the target resource group and this write permission will be validated when creating the resource sync rule.
- resource_
group_ name This property is required. Changes to this property will trigger replacement.
- The name of the resource group. The name is case insensitive.
- resource_
name This property is required. Changes to this property will trigger replacement.
- Custom Locations name.
- child_
resource_ name Changes to this property will trigger replacement.
- Resource Sync Rule name.
- location
Changes to this property will trigger replacement.
- The geo-location where the resource lives
- priority int
- Priority represents a priority of the Resource Sync Rule
- selector
Resource
Sync Rule Properties Selector Args - A label selector is composed of two parts, matchLabels and matchExpressions. The first part, matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'. The second part, matchExpressions is a list of resource selector requirements. Valid operators include In, NotIn, Exists, and DoesNotExist. The values set must be non-empty in the case of In and NotIn. The values set must be empty in the case of Exists and DoesNotExist. All of the requirements, from both matchLabels and matchExpressions must all be satisfied in order to match.
- Mapping[str, str]
- Resource tags.
- target_
resource_ strgroup - For an unmapped custom resource, its labels will be used to find matching resource sync rules. If this resource sync rule is one of the matching rules with highest priority, then the unmapped custom resource will be projected to the target resource group associated with this resource sync rule. The user creating this resource sync rule should have write permissions on the target resource group and this write permission will be validated when creating the resource sync rule.
- resource
Group Name This property is required. Changes to this property will trigger replacement.
- The name of the resource group. The name is case insensitive.
- resource
Name This property is required. Changes to this property will trigger replacement.
- Custom Locations name.
- child
Resource Name Changes to this property will trigger replacement.
- Resource Sync Rule name.
- location
Changes to this property will trigger replacement.
- The geo-location where the resource lives
- priority Number
- Priority represents a priority of the Resource Sync Rule
- selector Property Map
- A label selector is composed of two parts, matchLabels and matchExpressions. The first part, matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'. The second part, matchExpressions is a list of resource selector requirements. Valid operators include In, NotIn, Exists, and DoesNotExist. The values set must be non-empty in the case of In and NotIn. The values set must be empty in the case of Exists and DoesNotExist. All of the requirements, from both matchLabels and matchExpressions must all be satisfied in order to match.
- Map<String>
- Resource tags.
- target
Resource StringGroup - For an unmapped custom resource, its labels will be used to find matching resource sync rules. If this resource sync rule is one of the matching rules with highest priority, then the unmapped custom resource will be projected to the target resource group associated with this resource sync rule. The user creating this resource sync rule should have write permissions on the target resource group and this write permission will be validated when creating the resource sync rule.
Outputs
All input properties are implicitly available as output properties. Additionally, the ResourceSyncRule resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Name string
- The name of the resource
- Provisioning
State string - Provisioning State for the Resource Sync Rule.
- System
Data Pulumi.Azure Native. Extended Location. Outputs. System Data Response - Metadata pertaining to creation and last modification of the resource
- Type string
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- Id string
- The provider-assigned unique ID for this managed resource.
- Name string
- The name of the resource
- Provisioning
State string - Provisioning State for the Resource Sync Rule.
- System
Data SystemData Response - Metadata pertaining to creation and last modification of the resource
- Type string
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- id String
- The provider-assigned unique ID for this managed resource.
- name String
- The name of the resource
- provisioning
State String - Provisioning State for the Resource Sync Rule.
- system
Data SystemData Response - Metadata pertaining to creation and last modification of the resource
- type String
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- id string
- The provider-assigned unique ID for this managed resource.
- name string
- The name of the resource
- provisioning
State string - Provisioning State for the Resource Sync Rule.
- system
Data SystemData Response - Metadata pertaining to creation and last modification of the resource
- type string
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- id str
- The provider-assigned unique ID for this managed resource.
- name str
- The name of the resource
- provisioning_
state str - Provisioning State for the Resource Sync Rule.
- system_
data SystemData Response - Metadata pertaining to creation and last modification of the resource
- type str
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- id String
- The provider-assigned unique ID for this managed resource.
- name String
- The name of the resource
- provisioning
State String - Provisioning State for the Resource Sync Rule.
- system
Data Property Map - Metadata pertaining to creation and last modification of the resource
- type String
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
Supporting Types
ResourceSyncRulePropertiesResponseSelector, ResourceSyncRulePropertiesResponseSelectorArgs
- Match
Labels Dictionary<string, string> - MatchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'.
- Match
Labels map[string]string - MatchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'.
- match
Labels Map<String,String> - MatchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'.
- match
Labels {[key: string]: string} - MatchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'.
- match_
labels Mapping[str, str] - MatchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'.
- match
Labels Map<String> - MatchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'.
ResourceSyncRulePropertiesSelector, ResourceSyncRulePropertiesSelectorArgs
- Match
Labels Dictionary<string, string> - MatchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'.
- Match
Labels map[string]string - MatchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'.
- match
Labels Map<String,String> - MatchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'.
- match
Labels {[key: string]: string} - MatchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'.
- match_
labels Mapping[str, str] - MatchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'.
- match
Labels Map<String> - MatchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'.
SystemDataResponse, SystemDataResponseArgs
- Created
At string - The timestamp of resource creation (UTC).
- Created
By string - The identity that created the resource.
- Created
By stringType - The type of identity that created the resource.
- Last
Modified stringAt - The timestamp of resource last modification (UTC)
- Last
Modified stringBy - The identity that last modified the resource.
- Last
Modified stringBy Type - The type of identity that last modified the resource.
- Created
At string - The timestamp of resource creation (UTC).
- Created
By string - The identity that created the resource.
- Created
By stringType - The type of identity that created the resource.
- Last
Modified stringAt - The timestamp of resource last modification (UTC)
- Last
Modified stringBy - The identity that last modified the resource.
- Last
Modified stringBy Type - The type of identity that last modified the resource.
- created
At String - The timestamp of resource creation (UTC).
- created
By String - The identity that created the resource.
- created
By StringType - The type of identity that created the resource.
- last
Modified StringAt - The timestamp of resource last modification (UTC)
- last
Modified StringBy - The identity that last modified the resource.
- last
Modified StringBy Type - The type of identity that last modified the resource.
- created
At string - The timestamp of resource creation (UTC).
- created
By string - The identity that created the resource.
- created
By stringType - The type of identity that created the resource.
- last
Modified stringAt - The timestamp of resource last modification (UTC)
- last
Modified stringBy - The identity that last modified the resource.
- last
Modified stringBy Type - 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_ strtype - The type of identity that created the resource.
- last_
modified_ strat - The timestamp of resource last modification (UTC)
- last_
modified_ strby - The identity that last modified the resource.
- last_
modified_ strby_ type - The type of identity that last modified the resource.
- created
At String - The timestamp of resource creation (UTC).
- created
By String - The identity that created the resource.
- created
By StringType - The type of identity that created the resource.
- last
Modified StringAt - The timestamp of resource last modification (UTC)
- last
Modified StringBy - The identity that last modified the resource.
- last
Modified StringBy Type - The type of identity that last modified the resource.
Import
An existing resource can be imported using its type token, name, and identifier, e.g.
$ pulumi import azure-native:extendedlocation:ResourceSyncRule resourceSyncRule01 /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ExtendedLocation/customLocations/{resourceName}/resourceSyncRules/{childResourceName}
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- azure-native-v2 pulumi/pulumi-azure-native
- License
- Apache-2.0