GetSnapshot

Uses this data source to access information about an existing NetApp Snapshot.

NetApp Snapshot Usage

import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";

const test = azure.netapp.getSnapshot({
    resourceGroupName: "acctestRG",
    name: "acctestnetappsnapshot",
    accountName: "acctestnetappaccount",
    poolName: "acctestnetapppool",
    volumeName: "acctestnetappvolume",
});
export const netappSnapshotId = data.azurerm_netapp_snapshot.example.id;
import pulumi
import pulumi_azure as azure

test = azure.netapp.get_snapshot(resource_group_name="acctestRG",
    name="acctestnetappsnapshot",
    account_name="acctestnetappaccount",
    pool_name="acctestnetapppool",
    volume_name="acctestnetappvolume")
pulumi.export("netappSnapshotId", data["azurerm_netapp_snapshot"]["example"]["id"])
using Pulumi;
using Azure = Pulumi.Azure;

class MyStack : Stack
{
    public MyStack()
    {
        var test = Output.Create(Azure.NetApp.GetSnapshot.InvokeAsync(new Azure.NetApp.GetSnapshotArgs
        {
            ResourceGroupName = "acctestRG",
            Name = "acctestnetappsnapshot",
            AccountName = "acctestnetappaccount",
            PoolName = "acctestnetapppool",
            VolumeName = "acctestnetappvolume",
        }));
        this.NetappSnapshotId = data.Azurerm_netapp_snapshot.Example.Id;
    }

    [Output("netappSnapshotId")]
    public Output<string> NetappSnapshotId { get; set; }
}
package main

import (
	"github.com/pulumi/pulumi-azure/sdk/v3/go/azure/netapp"
	"github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := netapp.LookupSnapshot(ctx, &netapp.LookupSnapshotArgs{
			ResourceGroupName: "acctestRG",
			Name:              "acctestnetappsnapshot",
			AccountName:       "acctestnetappaccount",
			PoolName:          "acctestnetapppool",
			VolumeName:        "acctestnetappvolume",
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("netappSnapshotId", data.Azurerm_netapp_snapshot.Example.Id)
		return nil
	})
}

Using GetSnapshot

function getSnapshot(args: GetSnapshotArgs, opts?: InvokeOptions): Promise<GetSnapshotResult>
function  get_snapshot(account_name=None, name=None, pool_name=None, resource_group_name=None, volume_name=None, opts=None)
func LookupSnapshot(ctx *Context, args *LookupSnapshotArgs, opts ...InvokeOption) (*LookupSnapshotResult, error)

Note: This function is named LookupSnapshot in the Go SDK.

public static class GetSnapshot {
    public static Task<GetSnapshotResult> InvokeAsync(GetSnapshotArgs args, InvokeOptions? opts = null)
}

The following arguments are supported:

AccountName string

The name of the NetApp Account where the NetApp Pool exists.

Name string

The name of the NetApp Snapshot.

PoolName string

The name of the NetApp Pool where the NetApp Volume exists.

ResourceGroupName string

The Name of the Resource Group where the NetApp Snapshot exists.

VolumeName string

The name of the NetApp Volume where the NetApp Snapshot exists.

AccountName string

The name of the NetApp Account where the NetApp Pool exists.

Name string

The name of the NetApp Snapshot.

PoolName string

The name of the NetApp Pool where the NetApp Volume exists.

ResourceGroupName string

The Name of the Resource Group where the NetApp Snapshot exists.

VolumeName string

The name of the NetApp Volume where the NetApp Snapshot exists.

accountName string

The name of the NetApp Account where the NetApp Pool exists.

name string

The name of the NetApp Snapshot.

poolName string

The name of the NetApp Pool where the NetApp Volume exists.

resourceGroupName string

The Name of the Resource Group where the NetApp Snapshot exists.

volumeName string

The name of the NetApp Volume where the NetApp Snapshot exists.

account_name str

The name of the NetApp Account where the NetApp Pool exists.

name str

The name of the NetApp Snapshot.

pool_name str

The name of the NetApp Pool where the NetApp Volume exists.

resource_group_name str

The Name of the Resource Group where the NetApp Snapshot exists.

volume_name str

The name of the NetApp Volume where the NetApp Snapshot exists.

GetSnapshot Result

The following output properties are available:

AccountName string
Id string

The provider-assigned unique ID for this managed resource.

Location string

The Azure Region where the NetApp Snapshot exists.

Name string
PoolName string
ResourceGroupName string
VolumeName string
AccountName string
Id string

The provider-assigned unique ID for this managed resource.

Location string

The Azure Region where the NetApp Snapshot exists.

Name string
PoolName string
ResourceGroupName string
VolumeName string
accountName string
id string

The provider-assigned unique ID for this managed resource.

location string

The Azure Region where the NetApp Snapshot exists.

name string
poolName string
resourceGroupName string
volumeName string
account_name str
id str

The provider-assigned unique ID for this managed resource.

location str

The Azure Region where the NetApp Snapshot exists.

name str
pool_name str
resource_group_name str
volume_name str

Package Details

Repository
https://github.com/pulumi/pulumi-azure
License
Apache-2.0
Notes
This Pulumi package is based on the azurerm Terraform Provider.