azure-native.network.NetworkWatcher
Explore with Pulumi AI
Network watcher in a resource group.
Uses Azure REST API version 2023-02-01. In version 1.x of the Azure Native provider, it used API version 2020-11-01.
Other available API versions: 2022-05-01, 2023-04-01, 2023-05-01, 2023-06-01, 2023-09-01, 2023-11-01, 2024-01-01, 2024-03-01, 2024-05-01.
Create NetworkWatcher Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new NetworkWatcher(name: string, args: NetworkWatcherArgs, opts?: CustomResourceOptions);
@overload
def NetworkWatcher(resource_name: str,
args: NetworkWatcherArgs,
opts: Optional[ResourceOptions] = None)
@overload
def NetworkWatcher(resource_name: str,
opts: Optional[ResourceOptions] = None,
resource_group_name: Optional[str] = None,
id: Optional[str] = None,
location: Optional[str] = None,
network_watcher_name: Optional[str] = None,
tags: Optional[Mapping[str, str]] = None)
func NewNetworkWatcher(ctx *Context, name string, args NetworkWatcherArgs, opts ...ResourceOption) (*NetworkWatcher, error)
public NetworkWatcher(string name, NetworkWatcherArgs args, CustomResourceOptions? opts = null)
public NetworkWatcher(String name, NetworkWatcherArgs args)
public NetworkWatcher(String name, NetworkWatcherArgs args, CustomResourceOptions options)
type: azure-native:network:NetworkWatcher
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. NetworkWatcherArgs - 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. NetworkWatcherArgs - 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. NetworkWatcherArgs - 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. NetworkWatcherArgs - 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. NetworkWatcherArgs - 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 networkWatcherResource = new AzureNative.Network.NetworkWatcher("networkWatcherResource", new()
{
ResourceGroupName = "string",
Id = "string",
Location = "string",
NetworkWatcherName = "string",
Tags =
{
{ "string", "string" },
},
});
example, err := network.NewNetworkWatcher(ctx, "networkWatcherResource", &network.NetworkWatcherArgs{
ResourceGroupName: pulumi.String("string"),
Id: pulumi.String("string"),
Location: pulumi.String("string"),
NetworkWatcherName: pulumi.String("string"),
Tags: pulumi.StringMap{
"string": pulumi.String("string"),
},
})
var networkWatcherResource = new NetworkWatcher("networkWatcherResource", NetworkWatcherArgs.builder()
.resourceGroupName("string")
.id("string")
.location("string")
.networkWatcherName("string")
.tags(Map.of("string", "string"))
.build());
network_watcher_resource = azure_native.network.NetworkWatcher("networkWatcherResource",
resource_group_name="string",
id="string",
location="string",
network_watcher_name="string",
tags={
"string": "string",
})
const networkWatcherResource = new azure_native.network.NetworkWatcher("networkWatcherResource", {
resourceGroupName: "string",
id: "string",
location: "string",
networkWatcherName: "string",
tags: {
string: "string",
},
});
type: azure-native:network:NetworkWatcher
properties:
id: string
location: string
networkWatcherName: string
resourceGroupName: string
tags:
string: string
NetworkWatcher 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 NetworkWatcher 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.
- Id string
- Resource ID.
- Location string
- Resource location.
- Network
Watcher Name Changes to this property will trigger replacement.
- The name of the network watcher.
- Dictionary<string, string>
- Resource tags.
- Resource
Group Name This property is required. Changes to this property will trigger replacement.
- The name of the resource group.
- Id string
- Resource ID.
- Location string
- Resource location.
- Network
Watcher Name Changes to this property will trigger replacement.
- The name of the network watcher.
- map[string]string
- Resource tags.
- resource
Group Name This property is required. Changes to this property will trigger replacement.
- The name of the resource group.
- id String
- Resource ID.
- location String
- Resource location.
- network
Watcher Name Changes to this property will trigger replacement.
- The name of the network watcher.
- Map<String,String>
- Resource tags.
- resource
Group Name This property is required. Changes to this property will trigger replacement.
- The name of the resource group.
- id string
- Resource ID.
- location string
- Resource location.
- network
Watcher Name Changes to this property will trigger replacement.
- The name of the network watcher.
- {[key: string]: string}
- Resource tags.
- resource_
group_ name This property is required. Changes to this property will trigger replacement.
- The name of the resource group.
- id str
- Resource ID.
- location str
- Resource location.
- network_
watcher_ name Changes to this property will trigger replacement.
- The name of the network watcher.
- Mapping[str, str]
- Resource tags.
- resource
Group Name This property is required. Changes to this property will trigger replacement.
- The name of the resource group.
- id String
- Resource ID.
- location String
- Resource location.
- network
Watcher Name Changes to this property will trigger replacement.
- The name of the network watcher.
- Map<String>
- Resource tags.
Outputs
All input properties are implicitly available as output properties. Additionally, the NetworkWatcher 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 network watcher 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 network watcher 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 network watcher 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 network watcher 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 network watcher 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 network watcher resource.
- type String
- Resource type.
Import
An existing resource can be imported using its type token, name, and identifier, e.g.
$ pulumi import azure-native:network:NetworkWatcher nw1 /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/networkWatchers/{networkWatcherName}
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Azure Native pulumi/pulumi-azure-native
- License
- Apache-2.0