azure-native.network.NetworkGroup
Explore with Pulumi AI
The network group resource API Version: 2021-02-01-preview.
Example Usage
NetworkGroupsPut
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var networkGroup = new AzureNative.Network.NetworkGroup("networkGroup", new()
{
ConditionalMembership = "",
Description = "A sample group",
DisplayName = "My Network Group",
GroupMembers = new[]
{
new AzureNative.Network.Inputs.GroupMembersItemArgs
{
ResourceId = "/subscriptions/subscriptionC/resourceGroup/rg1/providers/Microsoft.Network/virtualnetworks/vnet1",
},
},
MemberType = "VirtualNetwork",
NetworkGroupName = "TestNetworkGroup",
NetworkManagerName = "testNetworkManager",
ResourceGroupName = "rg1",
});
});
package main
import (
network "github.com/pulumi/pulumi-azure-native-sdk/network"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := network.NewNetworkGroup(ctx, "networkGroup", &network.NetworkGroupArgs{
ConditionalMembership: pulumi.String(""),
Description: pulumi.String("A sample group"),
DisplayName: pulumi.String("My Network Group"),
GroupMembers: []network.GroupMembersItemArgs{
{
ResourceId: pulumi.String("/subscriptions/subscriptionC/resourceGroup/rg1/providers/Microsoft.Network/virtualnetworks/vnet1"),
},
},
MemberType: pulumi.String("VirtualNetwork"),
NetworkGroupName: pulumi.String("TestNetworkGroup"),
NetworkManagerName: pulumi.String("testNetworkManager"),
ResourceGroupName: pulumi.String("rg1"),
})
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.network.NetworkGroup;
import com.pulumi.azurenative.network.NetworkGroupArgs;
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 networkGroup = new NetworkGroup("networkGroup", NetworkGroupArgs.builder()
.conditionalMembership("")
.description("A sample group")
.displayName("My Network Group")
.groupMembers(Map.of("resourceId", "/subscriptions/subscriptionC/resourceGroup/rg1/providers/Microsoft.Network/virtualnetworks/vnet1"))
.memberType("VirtualNetwork")
.networkGroupName("TestNetworkGroup")
.networkManagerName("testNetworkManager")
.resourceGroupName("rg1")
.build());
}
}
import pulumi
import pulumi_azure_native as azure_native
network_group = azure_native.network.NetworkGroup("networkGroup",
conditional_membership="",
description="A sample group",
display_name="My Network Group",
group_members=[azure_native.network.GroupMembersItemArgs(
resource_id="/subscriptions/subscriptionC/resourceGroup/rg1/providers/Microsoft.Network/virtualnetworks/vnet1",
)],
member_type="VirtualNetwork",
network_group_name="TestNetworkGroup",
network_manager_name="testNetworkManager",
resource_group_name="rg1")
import * as pulumi from "@pulumi/pulumi";
import * as azure_native from "@pulumi/azure-native";
const networkGroup = new azure_native.network.NetworkGroup("networkGroup", {
conditionalMembership: "",
description: "A sample group",
displayName: "My Network Group",
groupMembers: [{
resourceId: "/subscriptions/subscriptionC/resourceGroup/rg1/providers/Microsoft.Network/virtualnetworks/vnet1",
}],
memberType: "VirtualNetwork",
networkGroupName: "TestNetworkGroup",
networkManagerName: "testNetworkManager",
resourceGroupName: "rg1",
});
resources:
networkGroup:
type: azure-native:network:NetworkGroup
properties:
conditionalMembership:
description: A sample group
displayName: My Network Group
groupMembers:
- resourceId: /subscriptions/subscriptionC/resourceGroup/rg1/providers/Microsoft.Network/virtualnetworks/vnet1
memberType: VirtualNetwork
networkGroupName: TestNetworkGroup
networkManagerName: testNetworkManager
resourceGroupName: rg1
Create NetworkGroup Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new NetworkGroup(name: string, args: NetworkGroupArgs, opts?: CustomResourceOptions);
@overload
def NetworkGroup(resource_name: str,
args: NetworkGroupArgs,
opts: Optional[ResourceOptions] = None)
@overload
def NetworkGroup(resource_name: str,
opts: Optional[ResourceOptions] = None,
network_manager_name: Optional[str] = None,
resource_group_name: Optional[str] = None,
conditional_membership: Optional[str] = None,
description: Optional[str] = None,
display_name: Optional[str] = None,
group_members: Optional[Sequence[GroupMembersItemArgs]] = None,
member_type: Optional[str] = None,
network_group_name: Optional[str] = None)
func NewNetworkGroup(ctx *Context, name string, args NetworkGroupArgs, opts ...ResourceOption) (*NetworkGroup, error)
public NetworkGroup(string name, NetworkGroupArgs args, CustomResourceOptions? opts = null)
public NetworkGroup(String name, NetworkGroupArgs args)
public NetworkGroup(String name, NetworkGroupArgs args, CustomResourceOptions options)
type: azure-native:network:NetworkGroup
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 NetworkGroupArgs
- 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 NetworkGroupArgs
- 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 NetworkGroupArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args NetworkGroupArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args NetworkGroupArgs
- 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 networkGroupResource = new AzureNative.Network.NetworkGroup("networkGroupResource", new()
{
NetworkManagerName = "string",
ResourceGroupName = "string",
ConditionalMembership = "string",
Description = "string",
DisplayName = "string",
GroupMembers = new[]
{
{
{ "resourceId", "string" },
},
},
MemberType = "string",
NetworkGroupName = "string",
});
example, err := network.NewNetworkGroup(ctx, "networkGroupResource", &network.NetworkGroupArgs{
NetworkManagerName: "string",
ResourceGroupName: "string",
ConditionalMembership: "string",
Description: "string",
DisplayName: "string",
GroupMembers: []map[string]interface{}{
map[string]interface{}{
"resourceId": "string",
},
},
MemberType: "string",
NetworkGroupName: "string",
})
var networkGroupResource = new NetworkGroup("networkGroupResource", NetworkGroupArgs.builder()
.networkManagerName("string")
.resourceGroupName("string")
.conditionalMembership("string")
.description("string")
.displayName("string")
.groupMembers(%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference))
.memberType("string")
.networkGroupName("string")
.build());
network_group_resource = azure_native.network.NetworkGroup("networkGroupResource",
network_manager_name=string,
resource_group_name=string,
conditional_membership=string,
description=string,
display_name=string,
group_members=[{
resourceId: string,
}],
member_type=string,
network_group_name=string)
const networkGroupResource = new azure_native.network.NetworkGroup("networkGroupResource", {
networkManagerName: "string",
resourceGroupName: "string",
conditionalMembership: "string",
description: "string",
displayName: "string",
groupMembers: [{
resourceId: "string",
}],
memberType: "string",
networkGroupName: "string",
});
type: azure-native:network:NetworkGroup
properties:
conditionalMembership: string
description: string
displayName: string
groupMembers:
- resourceId: string
memberType: string
networkGroupName: string
networkManagerName: string
resourceGroupName: string
NetworkGroup 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 NetworkGroup resource accepts the following input properties:
- Network
Manager stringName - The name of the network manager.
- Resource
Group stringName - The name of the resource group.
- Conditional
Membership string - Network group conditional filter.
- Description string
- A description of the network group.
- Display
Name string - A friendly name for the network group.
- Group
Members List<Pulumi.Azure Native. Network. Inputs. Group Members Item> - Group members of network group.
- Member
Type string - Group member type.
- Network
Group stringName - The name of the network group to get.
- Network
Manager stringName - The name of the network manager.
- Resource
Group stringName - The name of the resource group.
- Conditional
Membership string - Network group conditional filter.
- Description string
- A description of the network group.
- Display
Name string - A friendly name for the network group.
- Group
Members []GroupMembers Item Args - Group members of network group.
- Member
Type string - Group member type.
- Network
Group stringName - The name of the network group to get.
- network
Manager StringName - The name of the network manager.
- resource
Group StringName - The name of the resource group.
- conditional
Membership String - Network group conditional filter.
- description String
- A description of the network group.
- display
Name String - A friendly name for the network group.
- group
Members List<GroupMembers Item> - Group members of network group.
- member
Type String - Group member type.
- network
Group StringName - The name of the network group to get.
- network
Manager stringName - The name of the network manager.
- resource
Group stringName - The name of the resource group.
- conditional
Membership string - Network group conditional filter.
- description string
- A description of the network group.
- display
Name string - A friendly name for the network group.
- group
Members GroupMembers Item[] - Group members of network group.
- member
Type string - Group member type.
- network
Group stringName - The name of the network group to get.
- network_
manager_ strname - The name of the network manager.
- resource_
group_ strname - The name of the resource group.
- conditional_
membership str - Network group conditional filter.
- description str
- A description of the network group.
- display_
name str - A friendly name for the network group.
- group_
members Sequence[GroupMembers Item Args] - Group members of network group.
- member_
type str - Group member type.
- network_
group_ strname - The name of the network group to get.
- network
Manager StringName - The name of the network manager.
- resource
Group StringName - The name of the resource group.
- conditional
Membership String - Network group conditional filter.
- description String
- A description of the network group.
- display
Name String - A friendly name for the network group.
- group
Members List<Property Map> - Group members of network group.
- member
Type String - Group member type.
- network
Group StringName - The name of the network group to get.
Outputs
All input properties are implicitly available as output properties. Additionally, the NetworkGroup resource produces the following output properties:
- Etag string
- A unique read-only string that changes whenever the resource is updated.
- Id string
- The provider-assigned unique ID for this managed resource.
- Name string
- Resource name.
- Provisioning
State string - The provisioning state of the scope assignment resource.
- System
Data Pulumi.Azure Native. Network. Outputs. System Data Response - The system metadata related to this resource.
- Type string
- Resource type.
- Etag string
- A unique read-only string that changes whenever the resource is updated.
- Id string
- The provider-assigned unique ID for this managed resource.
- Name string
- Resource name.
- Provisioning
State string - The provisioning state of the scope assignment resource.
- System
Data SystemData Response - The system metadata related to this resource.
- Type string
- Resource type.
- etag String
- A unique read-only string that changes whenever the resource is updated.
- id String
- The provider-assigned unique ID for this managed resource.
- name String
- Resource name.
- provisioning
State String - The provisioning state of the scope assignment resource.
- system
Data SystemData Response - The system metadata related to this resource.
- type String
- Resource type.
- etag string
- A unique read-only string that changes whenever the resource is updated.
- id string
- The provider-assigned unique ID for this managed resource.
- name string
- Resource name.
- provisioning
State string - The provisioning state of the scope assignment resource.
- system
Data SystemData Response - The system metadata related to this resource.
- type string
- Resource type.
- etag str
- A unique read-only string that changes whenever the resource is updated.
- id str
- The provider-assigned unique ID for this managed resource.
- name str
- Resource name.
- provisioning_
state str - The provisioning state of the scope assignment resource.
- system_
data SystemData Response - The system metadata related to this resource.
- type str
- Resource type.
- etag String
- A unique read-only string that changes whenever the resource is updated.
- id String
- The provider-assigned unique ID for this managed resource.
- name String
- Resource name.
- provisioning
State String - The provisioning state of the scope assignment resource.
- system
Data Property Map - The system metadata related to this resource.
- type String
- Resource type.
Supporting Types
GroupMembersItem, GroupMembersItemArgs
- Resource
Id string - Resource Id.
- Resource
Id string - Resource Id.
- resource
Id String - Resource Id.
- resource
Id string - Resource Id.
- resource_
id str - Resource Id.
- resource
Id String - Resource Id.
GroupMembersItemResponse, GroupMembersItemResponseArgs
- Resource
Id string - Resource Id.
- Resource
Id string - Resource Id.
- resource
Id String - Resource Id.
- resource
Id string - Resource Id.
- resource_
id str - Resource Id.
- resource
Id String - Resource Id.
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 type of identity that last modified the resource.
- 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 type of identity that last modified the resource.
- 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 type of identity that last modified the resource.
- 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 type of identity that last modified the resource.
- 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 type of identity that last modified the resource.
- 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 type of identity that last modified the resource.
- 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:network:NetworkGroup TestNetworkGroup /subscriptions/subscriptionC/resourceGroup/rg1/providers/Microsoft.Network/networkManagers/testNetworkManager/networkGroups/TestNetworkGroup
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- azure-native-v1 pulumi/pulumi-azure-native
- License
- Apache-2.0