azure-native.managednetwork.ManagedNetworkPeeringPolicy
Explore with Pulumi AI
The Managed Network Peering Policy resource Azure REST API version: 2019-06-01-preview. Prior API version in Azure Native 1.x: 2019-06-01-preview.
Example Usage
ManagedNetworkPeeringPoliciesPut
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var managedNetworkPeeringPolicy = new AzureNative.ManagedNetwork.ManagedNetworkPeeringPolicy("managedNetworkPeeringPolicy", new()
{
ManagedNetworkName = "myManagedNetwork",
ManagedNetworkPeeringPolicyName = "myHubAndSpoke",
Properties = new AzureNative.ManagedNetwork.Inputs.ManagedNetworkPeeringPolicyPropertiesArgs
{
Hub = new AzureNative.ManagedNetwork.Inputs.ResourceIdArgs
{
Id = "/subscriptionB/resourceGroups/myResourceGroup/providers/Microsoft.Network/virtualNetworks/myHubVnet",
},
Spokes = new[]
{
new AzureNative.ManagedNetwork.Inputs.ResourceIdArgs
{
Id = "/subscriptionB/resourceGroups/myResourceGroup/providers/Microsoft.ManagedNetwork/managedNetworks/myManagedNetwork/managedNetworkGroups/myManagedNetworkGroup1",
},
},
Type = AzureNative.ManagedNetwork.Type.HubAndSpokeTopology,
},
ResourceGroupName = "myResourceGroup",
});
});
package main
import (
managednetwork "github.com/pulumi/pulumi-azure-native-sdk/managednetwork/v2"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := managednetwork.NewManagedNetworkPeeringPolicy(ctx, "managedNetworkPeeringPolicy", &managednetwork.ManagedNetworkPeeringPolicyArgs{
ManagedNetworkName: pulumi.String("myManagedNetwork"),
ManagedNetworkPeeringPolicyName: pulumi.String("myHubAndSpoke"),
Properties: &managednetwork.ManagedNetworkPeeringPolicyPropertiesArgs{
Hub: &managednetwork.ResourceIdArgs{
Id: pulumi.String("/subscriptionB/resourceGroups/myResourceGroup/providers/Microsoft.Network/virtualNetworks/myHubVnet"),
},
Spokes: managednetwork.ResourceIdArray{
&managednetwork.ResourceIdArgs{
Id: pulumi.String("/subscriptionB/resourceGroups/myResourceGroup/providers/Microsoft.ManagedNetwork/managedNetworks/myManagedNetwork/managedNetworkGroups/myManagedNetworkGroup1"),
},
},
Type: pulumi.String(managednetwork.TypeHubAndSpokeTopology),
},
ResourceGroupName: pulumi.String("myResourceGroup"),
})
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.managednetwork.ManagedNetworkPeeringPolicy;
import com.pulumi.azurenative.managednetwork.ManagedNetworkPeeringPolicyArgs;
import com.pulumi.azurenative.managednetwork.inputs.ManagedNetworkPeeringPolicyPropertiesArgs;
import com.pulumi.azurenative.managednetwork.inputs.ResourceIdArgs;
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 managedNetworkPeeringPolicy = new ManagedNetworkPeeringPolicy("managedNetworkPeeringPolicy", ManagedNetworkPeeringPolicyArgs.builder()
.managedNetworkName("myManagedNetwork")
.managedNetworkPeeringPolicyName("myHubAndSpoke")
.properties(ManagedNetworkPeeringPolicyPropertiesArgs.builder()
.hub(ResourceIdArgs.builder()
.id("/subscriptionB/resourceGroups/myResourceGroup/providers/Microsoft.Network/virtualNetworks/myHubVnet")
.build())
.spokes(ResourceIdArgs.builder()
.id("/subscriptionB/resourceGroups/myResourceGroup/providers/Microsoft.ManagedNetwork/managedNetworks/myManagedNetwork/managedNetworkGroups/myManagedNetworkGroup1")
.build())
.type("HubAndSpokeTopology")
.build())
.resourceGroupName("myResourceGroup")
.build());
}
}
import pulumi
import pulumi_azure_native as azure_native
managed_network_peering_policy = azure_native.managednetwork.ManagedNetworkPeeringPolicy("managedNetworkPeeringPolicy",
managed_network_name="myManagedNetwork",
managed_network_peering_policy_name="myHubAndSpoke",
properties={
"hub": {
"id": "/subscriptionB/resourceGroups/myResourceGroup/providers/Microsoft.Network/virtualNetworks/myHubVnet",
},
"spokes": [{
"id": "/subscriptionB/resourceGroups/myResourceGroup/providers/Microsoft.ManagedNetwork/managedNetworks/myManagedNetwork/managedNetworkGroups/myManagedNetworkGroup1",
}],
"type": azure_native.managednetwork.Type.HUB_AND_SPOKE_TOPOLOGY,
},
resource_group_name="myResourceGroup")
import * as pulumi from "@pulumi/pulumi";
import * as azure_native from "@pulumi/azure-native";
const managedNetworkPeeringPolicy = new azure_native.managednetwork.ManagedNetworkPeeringPolicy("managedNetworkPeeringPolicy", {
managedNetworkName: "myManagedNetwork",
managedNetworkPeeringPolicyName: "myHubAndSpoke",
properties: {
hub: {
id: "/subscriptionB/resourceGroups/myResourceGroup/providers/Microsoft.Network/virtualNetworks/myHubVnet",
},
spokes: [{
id: "/subscriptionB/resourceGroups/myResourceGroup/providers/Microsoft.ManagedNetwork/managedNetworks/myManagedNetwork/managedNetworkGroups/myManagedNetworkGroup1",
}],
type: azure_native.managednetwork.Type.HubAndSpokeTopology,
},
resourceGroupName: "myResourceGroup",
});
resources:
managedNetworkPeeringPolicy:
type: azure-native:managednetwork:ManagedNetworkPeeringPolicy
properties:
managedNetworkName: myManagedNetwork
managedNetworkPeeringPolicyName: myHubAndSpoke
properties:
hub:
id: /subscriptionB/resourceGroups/myResourceGroup/providers/Microsoft.Network/virtualNetworks/myHubVnet
spokes:
- id: /subscriptionB/resourceGroups/myResourceGroup/providers/Microsoft.ManagedNetwork/managedNetworks/myManagedNetwork/managedNetworkGroups/myManagedNetworkGroup1
type: HubAndSpokeTopology
resourceGroupName: myResourceGroup
Create ManagedNetworkPeeringPolicy Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new ManagedNetworkPeeringPolicy(name: string, args: ManagedNetworkPeeringPolicyArgs, opts?: CustomResourceOptions);
@overload
def ManagedNetworkPeeringPolicy(resource_name: str,
args: ManagedNetworkPeeringPolicyArgs,
opts: Optional[ResourceOptions] = None)
@overload
def ManagedNetworkPeeringPolicy(resource_name: str,
opts: Optional[ResourceOptions] = None,
managed_network_name: Optional[str] = None,
resource_group_name: Optional[str] = None,
location: Optional[str] = None,
managed_network_peering_policy_name: Optional[str] = None,
properties: Optional[ManagedNetworkPeeringPolicyPropertiesArgs] = None)
func NewManagedNetworkPeeringPolicy(ctx *Context, name string, args ManagedNetworkPeeringPolicyArgs, opts ...ResourceOption) (*ManagedNetworkPeeringPolicy, error)
public ManagedNetworkPeeringPolicy(string name, ManagedNetworkPeeringPolicyArgs args, CustomResourceOptions? opts = null)
public ManagedNetworkPeeringPolicy(String name, ManagedNetworkPeeringPolicyArgs args)
public ManagedNetworkPeeringPolicy(String name, ManagedNetworkPeeringPolicyArgs args, CustomResourceOptions options)
type: azure-native:managednetwork:ManagedNetworkPeeringPolicy
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args ManagedNetworkPeeringPolicyArgs
- 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 ManagedNetworkPeeringPolicyArgs
- 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 ManagedNetworkPeeringPolicyArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ManagedNetworkPeeringPolicyArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args ManagedNetworkPeeringPolicyArgs
- 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 managedNetworkPeeringPolicyResource = new AzureNative.ManagedNetwork.ManagedNetworkPeeringPolicy("managedNetworkPeeringPolicyResource", new()
{
ManagedNetworkName = "string",
ResourceGroupName = "string",
Location = "string",
ManagedNetworkPeeringPolicyName = "string",
Properties = new AzureNative.ManagedNetwork.Inputs.ManagedNetworkPeeringPolicyPropertiesArgs
{
Type = "string",
Hub = new AzureNative.ManagedNetwork.Inputs.ResourceIdArgs
{
Id = "string",
},
Mesh = new[]
{
new AzureNative.ManagedNetwork.Inputs.ResourceIdArgs
{
Id = "string",
},
},
Spokes = new[]
{
new AzureNative.ManagedNetwork.Inputs.ResourceIdArgs
{
Id = "string",
},
},
},
});
example, err := managednetwork.NewManagedNetworkPeeringPolicy(ctx, "managedNetworkPeeringPolicyResource", &managednetwork.ManagedNetworkPeeringPolicyArgs{
ManagedNetworkName: pulumi.String("string"),
ResourceGroupName: pulumi.String("string"),
Location: pulumi.String("string"),
ManagedNetworkPeeringPolicyName: pulumi.String("string"),
Properties: &managednetwork.ManagedNetworkPeeringPolicyPropertiesArgs{
Type: pulumi.String("string"),
Hub: &managednetwork.ResourceIdArgs{
Id: pulumi.String("string"),
},
Mesh: managednetwork.ResourceIdArray{
&managednetwork.ResourceIdArgs{
Id: pulumi.String("string"),
},
},
Spokes: managednetwork.ResourceIdArray{
&managednetwork.ResourceIdArgs{
Id: pulumi.String("string"),
},
},
},
})
var managedNetworkPeeringPolicyResource = new ManagedNetworkPeeringPolicy("managedNetworkPeeringPolicyResource", ManagedNetworkPeeringPolicyArgs.builder()
.managedNetworkName("string")
.resourceGroupName("string")
.location("string")
.managedNetworkPeeringPolicyName("string")
.properties(ManagedNetworkPeeringPolicyPropertiesArgs.builder()
.type("string")
.hub(ResourceIdArgs.builder()
.id("string")
.build())
.mesh(ResourceIdArgs.builder()
.id("string")
.build())
.spokes(ResourceIdArgs.builder()
.id("string")
.build())
.build())
.build());
managed_network_peering_policy_resource = azure_native.managednetwork.ManagedNetworkPeeringPolicy("managedNetworkPeeringPolicyResource",
managed_network_name="string",
resource_group_name="string",
location="string",
managed_network_peering_policy_name="string",
properties={
"type": "string",
"hub": {
"id": "string",
},
"mesh": [{
"id": "string",
}],
"spokes": [{
"id": "string",
}],
})
const managedNetworkPeeringPolicyResource = new azure_native.managednetwork.ManagedNetworkPeeringPolicy("managedNetworkPeeringPolicyResource", {
managedNetworkName: "string",
resourceGroupName: "string",
location: "string",
managedNetworkPeeringPolicyName: "string",
properties: {
type: "string",
hub: {
id: "string",
},
mesh: [{
id: "string",
}],
spokes: [{
id: "string",
}],
},
});
type: azure-native:managednetwork:ManagedNetworkPeeringPolicy
properties:
location: string
managedNetworkName: string
managedNetworkPeeringPolicyName: string
properties:
hub:
id: string
mesh:
- id: string
spokes:
- id: string
type: string
resourceGroupName: string
ManagedNetworkPeeringPolicy 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 ManagedNetworkPeeringPolicy resource accepts the following input properties:
- Managed
Network stringName - The name of the Managed Network.
- Resource
Group stringName - The name of the resource group.
- Location string
- The geo-location where the resource lives
- Managed
Network stringPeering Policy Name - The name of the Managed Network Peering Policy.
- Properties
Pulumi.
Azure Native. Managed Network. Inputs. Managed Network Peering Policy Properties - Gets or sets the properties of a Managed Network Policy
- Managed
Network stringName - The name of the Managed Network.
- Resource
Group stringName - The name of the resource group.
- Location string
- The geo-location where the resource lives
- Managed
Network stringPeering Policy Name - The name of the Managed Network Peering Policy.
- Properties
Managed
Network Peering Policy Properties Args - Gets or sets the properties of a Managed Network Policy
- managed
Network StringName - The name of the Managed Network.
- resource
Group StringName - The name of the resource group.
- location String
- The geo-location where the resource lives
- managed
Network StringPeering Policy Name - The name of the Managed Network Peering Policy.
- properties
Managed
Network Peering Policy Properties - Gets or sets the properties of a Managed Network Policy
- managed
Network stringName - The name of the Managed Network.
- resource
Group stringName - The name of the resource group.
- location string
- The geo-location where the resource lives
- managed
Network stringPeering Policy Name - The name of the Managed Network Peering Policy.
- properties
Managed
Network Peering Policy Properties - Gets or sets the properties of a Managed Network Policy
- managed_
network_ strname - The name of the Managed Network.
- resource_
group_ strname - The name of the resource group.
- location str
- The geo-location where the resource lives
- managed_
network_ strpeering_ policy_ name - The name of the Managed Network Peering Policy.
- properties
Managed
Network Peering Policy Properties Args - Gets or sets the properties of a Managed Network Policy
- managed
Network StringName - The name of the Managed Network.
- resource
Group StringName - The name of the resource group.
- location String
- The geo-location where the resource lives
- managed
Network StringPeering Policy Name - The name of the Managed Network Peering Policy.
- properties Property Map
- Gets or sets the properties of a Managed Network Policy
Outputs
All input properties are implicitly available as output properties. Additionally, the ManagedNetworkPeeringPolicy resource produces the following output properties:
Supporting Types
ManagedNetworkPeeringPolicyProperties, ManagedNetworkPeeringPolicyPropertiesArgs
- Type
string | Pulumi.
Azure Native. Managed Network. Type - Gets or sets the connectivity type of a network structure policy
- Hub
Pulumi.
Azure Native. Managed Network. Inputs. Resource Id - Gets or sets the hub virtual network ID
- Mesh
List<Pulumi.
Azure Native. Managed Network. Inputs. Resource Id> - Gets or sets the mesh group IDs
- Spokes
List<Pulumi.
Azure Native. Managed Network. Inputs. Resource Id> - Gets or sets the spokes group IDs
- Type string | Type
- Gets or sets the connectivity type of a network structure policy
- Hub
Resource
Id - Gets or sets the hub virtual network ID
- Mesh
[]Resource
Id - Gets or sets the mesh group IDs
- Spokes
[]Resource
Id - Gets or sets the spokes group IDs
- type String | Type
- Gets or sets the connectivity type of a network structure policy
- hub
Resource
Id - Gets or sets the hub virtual network ID
- mesh
List<Resource
Id> - Gets or sets the mesh group IDs
- spokes
List<Resource
Id> - Gets or sets the spokes group IDs
- type string | Type
- Gets or sets the connectivity type of a network structure policy
- hub
Resource
Id - Gets or sets the hub virtual network ID
- mesh
Resource
Id[] - Gets or sets the mesh group IDs
- spokes
Resource
Id[] - Gets or sets the spokes group IDs
- type str | Type
- Gets or sets the connectivity type of a network structure policy
- hub
Resource
Id - Gets or sets the hub virtual network ID
- mesh
Sequence[Resource
Id] - Gets or sets the mesh group IDs
- spokes
Sequence[Resource
Id] - Gets or sets the spokes group IDs
- type
String | "Hub
And Spoke Topology" | "Mesh Topology" - Gets or sets the connectivity type of a network structure policy
- hub Property Map
- Gets or sets the hub virtual network ID
- mesh List<Property Map>
- Gets or sets the mesh group IDs
- spokes List<Property Map>
- Gets or sets the spokes group IDs
ManagedNetworkPeeringPolicyPropertiesResponse, ManagedNetworkPeeringPolicyPropertiesResponseArgs
- Etag string
- A unique read-only string that changes whenever the resource is updated.
- Provisioning
State string - Provisioning state of the ManagedNetwork resource.
- Type string
- Gets or sets the connectivity type of a network structure policy
- Hub
Pulumi.
Azure Native. Managed Network. Inputs. Resource Id Response - Gets or sets the hub virtual network ID
- Mesh
List<Pulumi.
Azure Native. Managed Network. Inputs. Resource Id Response> - Gets or sets the mesh group IDs
- Spokes
List<Pulumi.
Azure Native. Managed Network. Inputs. Resource Id Response> - Gets or sets the spokes group IDs
- Etag string
- A unique read-only string that changes whenever the resource is updated.
- Provisioning
State string - Provisioning state of the ManagedNetwork resource.
- Type string
- Gets or sets the connectivity type of a network structure policy
- Hub
Resource
Id Response - Gets or sets the hub virtual network ID
- Mesh
[]Resource
Id Response - Gets or sets the mesh group IDs
- Spokes
[]Resource
Id Response - Gets or sets the spokes group IDs
- etag String
- A unique read-only string that changes whenever the resource is updated.
- provisioning
State String - Provisioning state of the ManagedNetwork resource.
- type String
- Gets or sets the connectivity type of a network structure policy
- hub
Resource
Id Response - Gets or sets the hub virtual network ID
- mesh
List<Resource
Id Response> - Gets or sets the mesh group IDs
- spokes
List<Resource
Id Response> - Gets or sets the spokes group IDs
- etag string
- A unique read-only string that changes whenever the resource is updated.
- provisioning
State string - Provisioning state of the ManagedNetwork resource.
- type string
- Gets or sets the connectivity type of a network structure policy
- hub
Resource
Id Response - Gets or sets the hub virtual network ID
- mesh
Resource
Id Response[] - Gets or sets the mesh group IDs
- spokes
Resource
Id Response[] - Gets or sets the spokes group IDs
- etag str
- A unique read-only string that changes whenever the resource is updated.
- provisioning_
state str - Provisioning state of the ManagedNetwork resource.
- type str
- Gets or sets the connectivity type of a network structure policy
- hub
Resource
Id Response - Gets or sets the hub virtual network ID
- mesh
Sequence[Resource
Id Response] - Gets or sets the mesh group IDs
- spokes
Sequence[Resource
Id Response] - Gets or sets the spokes group IDs
- etag String
- A unique read-only string that changes whenever the resource is updated.
- provisioning
State String - Provisioning state of the ManagedNetwork resource.
- type String
- Gets or sets the connectivity type of a network structure policy
- hub Property Map
- Gets or sets the hub virtual network ID
- mesh List<Property Map>
- Gets or sets the mesh group IDs
- spokes List<Property Map>
- Gets or sets the spokes group IDs
ResourceId, ResourceIdArgs
- Id string
- Resource Id
- Id string
- Resource Id
- id String
- Resource Id
- id string
- Resource Id
- id str
- Resource Id
- id String
- Resource Id
ResourceIdResponse, ResourceIdResponseArgs
- Id string
- Resource Id
- Id string
- Resource Id
- id String
- Resource Id
- id string
- Resource Id
- id str
- Resource Id
- id String
- Resource Id
Type, TypeArgs
- Hub
And Spoke Topology - HubAndSpokeTopology
- Mesh
Topology - MeshTopology
- Type
Hub And Spoke Topology - HubAndSpokeTopology
- Type
Mesh Topology - MeshTopology
- Hub
And Spoke Topology - HubAndSpokeTopology
- Mesh
Topology - MeshTopology
- Hub
And Spoke Topology - HubAndSpokeTopology
- Mesh
Topology - MeshTopology
- HUB_AND_SPOKE_TOPOLOGY
- HubAndSpokeTopology
- MESH_TOPOLOGY
- MeshTopology
- "Hub
And Spoke Topology" - HubAndSpokeTopology
- "Mesh
Topology" - MeshTopology
Import
An existing resource can be imported using its type token, name, and identifier, e.g.
$ pulumi import azure-native:managednetwork:ManagedNetworkPeeringPolicy myHubAndSpoke /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedNetwork/managedNetworks/{managedNetworkName}/managedNetworkPeeringPolicies/{managedNetworkPeeringPolicyName}
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Azure Native pulumi/pulumi-azure-native
- License
- Apache-2.0