get Network Ddos Protection Plan
suspend fun getNetworkDdosProtectionPlan(argument: GetNetworkDdosProtectionPlanPlainArgs): GetNetworkDdosProtectionPlanResult
Use this data source to access information about an existing Azure Network DDoS Protection Plan.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";
const example = azure.network.getNetworkDdosProtectionPlan({
name: exampleAzurermNetworkDdosProtectionPlan.name,
resourceGroupName: exampleAzurermNetworkDdosProtectionPlan.resourceGroupName,
});
export const ddosProtectionPlanId = example.then(example => example.id);
Content copied to clipboard
import pulumi
import pulumi_azure as azure
example = azure.network.get_network_ddos_protection_plan(name=example_azurerm_network_ddos_protection_plan["name"],
resource_group_name=example_azurerm_network_ddos_protection_plan["resourceGroupName"])
pulumi.export("ddosProtectionPlanId", example.id)
Content copied to clipboard
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Azure = Pulumi.Azure;
return await Deployment.RunAsync(() =>
{
var example = Azure.Network.GetNetworkDdosProtectionPlan.Invoke(new()
{
Name = exampleAzurermNetworkDdosProtectionPlan.Name,
ResourceGroupName = exampleAzurermNetworkDdosProtectionPlan.ResourceGroupName,
});
return new Dictionary<string, object?>
{
["ddosProtectionPlanId"] = example.Apply(getNetworkDdosProtectionPlanResult => getNetworkDdosProtectionPlanResult.Id),
};
});
Content copied to clipboard
package main
import (
"github.com/pulumi/pulumi-azure/sdk/v6/go/azure/network"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
example, err := network.GetNetworkDdosProtectionPlan(ctx, &network.GetNetworkDdosProtectionPlanArgs{
Name: exampleAzurermNetworkDdosProtectionPlan.Name,
ResourceGroupName: exampleAzurermNetworkDdosProtectionPlan.ResourceGroupName,
}, nil)
if err != nil {
return err
}
ctx.Export("ddosProtectionPlanId", example.Id)
return nil
})
}
Content copied to clipboard
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azure.network.NetworkFunctions;
import com.pulumi.azure.network.inputs.GetNetworkDdosProtectionPlanArgs;
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) {
final var example = NetworkFunctions.getNetworkDdosProtectionPlan(GetNetworkDdosProtectionPlanArgs.builder()
.name(exampleAzurermNetworkDdosProtectionPlan.name())
.resourceGroupName(exampleAzurermNetworkDdosProtectionPlan.resourceGroupName())
.build());
ctx.export("ddosProtectionPlanId", example.applyValue(getNetworkDdosProtectionPlanResult -> getNetworkDdosProtectionPlanResult.id()));
}
}
Content copied to clipboard
variables:
example:
fn::invoke:
function: azure:network:getNetworkDdosProtectionPlan
arguments:
name: ${exampleAzurermNetworkDdosProtectionPlan.name}
resourceGroupName: ${exampleAzurermNetworkDdosProtectionPlan.resourceGroupName}
outputs:
ddosProtectionPlanId: ${example.id}
Content copied to clipboard
Return
A collection of values returned by getNetworkDdosProtectionPlan.
Parameters
argument
A collection of arguments for invoking getNetworkDdosProtectionPlan.
suspend fun getNetworkDdosProtectionPlan(name: String, resourceGroupName: String): GetNetworkDdosProtectionPlanResult
Return
A collection of values returned by getNetworkDdosProtectionPlan.
Parameters
name
The name of the Network DDoS Protection Plan.
resource Group Name
The name of the resource group where the Network DDoS Protection Plan exists.
See also
suspend fun getNetworkDdosProtectionPlan(argument: suspend GetNetworkDdosProtectionPlanPlainArgsBuilder.() -> Unit): GetNetworkDdosProtectionPlanResult
Return
A collection of values returned by getNetworkDdosProtectionPlan.
Parameters
argument
Builder for com.pulumi.azure.network.kotlin.inputs.GetNetworkDdosProtectionPlanPlainArgs.