get Volume Quota Rule
Use this data source to access information about an existing Volume Quota Rule.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";
const example = azure.netapp.getVolumeQuotaRule({
name: "exampleQuotaRule",
volumeId: "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.NetApp/netAppAccounts/account1/capacityPools/pool1/volumes/vol1",
});
export const id = example.then(example => example.id);
Content copied to clipboard
import pulumi
import pulumi_azure as azure
example = azure.netapp.get_volume_quota_rule(name="exampleQuotaRule",
volume_id="/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.NetApp/netAppAccounts/account1/capacityPools/pool1/volumes/vol1")
pulumi.export("id", 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.NetApp.GetVolumeQuotaRule.Invoke(new()
{
Name = "exampleQuotaRule",
VolumeId = "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.NetApp/netAppAccounts/account1/capacityPools/pool1/volumes/vol1",
});
return new Dictionary<string, object?>
{
["id"] = example.Apply(getVolumeQuotaRuleResult => getVolumeQuotaRuleResult.Id),
};
});
Content copied to clipboard
package main
import (
"github.com/pulumi/pulumi-azure/sdk/v6/go/azure/netapp"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
example, err := netapp.LookupVolumeQuotaRule(ctx, &netapp.LookupVolumeQuotaRuleArgs{
Name: "exampleQuotaRule",
VolumeId: "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.NetApp/netAppAccounts/account1/capacityPools/pool1/volumes/vol1",
}, nil)
if err != nil {
return err
}
ctx.Export("id", 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.netapp.NetappFunctions;
import com.pulumi.azure.netapp.inputs.GetVolumeQuotaRuleArgs;
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 = NetappFunctions.getVolumeQuotaRule(GetVolumeQuotaRuleArgs.builder()
.name("exampleQuotaRule")
.volumeId("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.NetApp/netAppAccounts/account1/capacityPools/pool1/volumes/vol1")
.build());
ctx.export("id", example.applyValue(getVolumeQuotaRuleResult -> getVolumeQuotaRuleResult.id()));
}
}
Content copied to clipboard
variables:
example:
fn::invoke:
function: azure:netapp:getVolumeQuotaRule
arguments:
name: exampleQuotaRule
volumeId: /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.NetApp/netAppAccounts/account1/capacityPools/pool1/volumes/vol1
outputs:
id: ${example.id}
Content copied to clipboard
Return
A collection of values returned by getVolumeQuotaRule.
Parameters
argument
A collection of arguments for invoking getVolumeQuotaRule.
Return
A collection of values returned by getVolumeQuotaRule.
Parameters
name
The name of this Volume Quota Rule.
volume Id
The NetApp volume ID where the Volume Quota Rule is assigned to.
See also
suspend fun getVolumeQuotaRule(argument: suspend GetVolumeQuotaRulePlainArgsBuilder.() -> Unit): GetVolumeQuotaRuleResult
Return
A collection of values returned by getVolumeQuotaRule.
Parameters
argument
Builder for com.pulumi.azure.netapp.kotlin.inputs.GetVolumeQuotaRulePlainArgs.