We recommend using Azure Native.
azure.elasticsan.Volume
Explore with Pulumi AI
Manages an Elastic SAN Volume resource.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";
const example = new azure.core.ResourceGroup("example", {
    name: "example-rg",
    location: "West Europe",
});
const exampleElasticSan = new azure.elasticsan.ElasticSan("example", {
    name: "example-es",
    resourceGroupName: example.name,
    location: example.location,
    baseSizeInTib: 1,
    sku: {
        name: "Premium_LRS",
    },
});
const exampleVolumeGroup = new azure.elasticsan.VolumeGroup("example", {
    name: "example-esvg",
    elasticSanId: exampleElasticSan.id,
});
const exampleVolume = new azure.elasticsan.Volume("example", {
    name: "example-esv",
    volumeGroupId: exampleVolumeGroup.id,
    sizeInGib: 1,
});
export const targetIqn = exampleVolume.targetIqn;
import pulumi
import pulumi_azure as azure
example = azure.core.ResourceGroup("example",
    name="example-rg",
    location="West Europe")
example_elastic_san = azure.elasticsan.ElasticSan("example",
    name="example-es",
    resource_group_name=example.name,
    location=example.location,
    base_size_in_tib=1,
    sku={
        "name": "Premium_LRS",
    })
example_volume_group = azure.elasticsan.VolumeGroup("example",
    name="example-esvg",
    elastic_san_id=example_elastic_san.id)
example_volume = azure.elasticsan.Volume("example",
    name="example-esv",
    volume_group_id=example_volume_group.id,
    size_in_gib=1)
pulumi.export("targetIqn", example_volume.target_iqn)
package main
import (
	"github.com/pulumi/pulumi-azure/sdk/v6/go/azure/core"
	"github.com/pulumi/pulumi-azure/sdk/v6/go/azure/elasticsan"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		example, err := core.NewResourceGroup(ctx, "example", &core.ResourceGroupArgs{
			Name:     pulumi.String("example-rg"),
			Location: pulumi.String("West Europe"),
		})
		if err != nil {
			return err
		}
		exampleElasticSan, err := elasticsan.NewElasticSan(ctx, "example", &elasticsan.ElasticSanArgs{
			Name:              pulumi.String("example-es"),
			ResourceGroupName: example.Name,
			Location:          example.Location,
			BaseSizeInTib:     pulumi.Int(1),
			Sku: &elasticsan.ElasticSanSkuArgs{
				Name: pulumi.String("Premium_LRS"),
			},
		})
		if err != nil {
			return err
		}
		exampleVolumeGroup, err := elasticsan.NewVolumeGroup(ctx, "example", &elasticsan.VolumeGroupArgs{
			Name:         pulumi.String("example-esvg"),
			ElasticSanId: exampleElasticSan.ID(),
		})
		if err != nil {
			return err
		}
		exampleVolume, err := elasticsan.NewVolume(ctx, "example", &elasticsan.VolumeArgs{
			Name:          pulumi.String("example-esv"),
			VolumeGroupId: exampleVolumeGroup.ID(),
			SizeInGib:     pulumi.Int(1),
		})
		if err != nil {
			return err
		}
		ctx.Export("targetIqn", exampleVolume.TargetIqn)
		return nil
	})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Azure = Pulumi.Azure;
return await Deployment.RunAsync(() => 
{
    var example = new Azure.Core.ResourceGroup("example", new()
    {
        Name = "example-rg",
        Location = "West Europe",
    });
    var exampleElasticSan = new Azure.ElasticSan.ElasticSan("example", new()
    {
        Name = "example-es",
        ResourceGroupName = example.Name,
        Location = example.Location,
        BaseSizeInTib = 1,
        Sku = new Azure.ElasticSan.Inputs.ElasticSanSkuArgs
        {
            Name = "Premium_LRS",
        },
    });
    var exampleVolumeGroup = new Azure.ElasticSan.VolumeGroup("example", new()
    {
        Name = "example-esvg",
        ElasticSanId = exampleElasticSan.Id,
    });
    var exampleVolume = new Azure.ElasticSan.Volume("example", new()
    {
        Name = "example-esv",
        VolumeGroupId = exampleVolumeGroup.Id,
        SizeInGib = 1,
    });
    return new Dictionary<string, object?>
    {
        ["targetIqn"] = exampleVolume.TargetIqn,
    };
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azure.core.ResourceGroup;
import com.pulumi.azure.core.ResourceGroupArgs;
import com.pulumi.azure.elasticsan.ElasticSan;
import com.pulumi.azure.elasticsan.ElasticSanArgs;
import com.pulumi.azure.elasticsan.inputs.ElasticSanSkuArgs;
import com.pulumi.azure.elasticsan.VolumeGroup;
import com.pulumi.azure.elasticsan.VolumeGroupArgs;
import com.pulumi.azure.elasticsan.Volume;
import com.pulumi.azure.elasticsan.VolumeArgs;
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 example = new ResourceGroup("example", ResourceGroupArgs.builder()
            .name("example-rg")
            .location("West Europe")
            .build());
        var exampleElasticSan = new ElasticSan("exampleElasticSan", ElasticSanArgs.builder()
            .name("example-es")
            .resourceGroupName(example.name())
            .location(example.location())
            .baseSizeInTib(1)
            .sku(ElasticSanSkuArgs.builder()
                .name("Premium_LRS")
                .build())
            .build());
        var exampleVolumeGroup = new VolumeGroup("exampleVolumeGroup", VolumeGroupArgs.builder()
            .name("example-esvg")
            .elasticSanId(exampleElasticSan.id())
            .build());
        var exampleVolume = new Volume("exampleVolume", VolumeArgs.builder()
            .name("example-esv")
            .volumeGroupId(exampleVolumeGroup.id())
            .sizeInGib(1)
            .build());
        ctx.export("targetIqn", exampleVolume.targetIqn());
    }
}
resources:
  example:
    type: azure:core:ResourceGroup
    properties:
      name: example-rg
      location: West Europe
  exampleElasticSan:
    type: azure:elasticsan:ElasticSan
    name: example
    properties:
      name: example-es
      resourceGroupName: ${example.name}
      location: ${example.location}
      baseSizeInTib: 1
      sku:
        name: Premium_LRS
  exampleVolumeGroup:
    type: azure:elasticsan:VolumeGroup
    name: example
    properties:
      name: example-esvg
      elasticSanId: ${exampleElasticSan.id}
  exampleVolume:
    type: azure:elasticsan:Volume
    name: example
    properties:
      name: example-esv
      volumeGroupId: ${exampleVolumeGroup.id}
      sizeInGib: 1
outputs:
  targetIqn: ${exampleVolume.targetIqn}
Example of creating an Elastic SAN Volume from a Disk Snapshot
import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";
const example = new azure.core.ResourceGroup("example", {
    name: "example-rg",
    location: "West Europe",
});
const exampleElasticSan = new azure.elasticsan.ElasticSan("example", {
    name: "example-es",
    resourceGroupName: example.name,
    location: example.location,
    baseSizeInTib: 1,
    sku: {
        name: "Premium_LRS",
    },
});
const exampleVolumeGroup = new azure.elasticsan.VolumeGroup("example", {
    name: "example-esvg",
    elasticSanId: exampleElasticSan.id,
});
const exampleManagedDisk = new azure.compute.ManagedDisk("example", {
    name: "example-disk",
    location: example.location,
    resourceGroupName: example.name,
    createOption: "Empty",
    storageAccountType: "Standard_LRS",
    diskSizeGb: 2,
});
const exampleSnapshot = new azure.compute.Snapshot("example", {
    name: "example-ss",
    location: example.location,
    resourceGroupName: example.name,
    createOption: "Copy",
    sourceUri: exampleManagedDisk.id,
});
const example2 = new azure.elasticsan.Volume("example2", {
    name: "example-esv2",
    volumeGroupId: exampleVolumeGroup.id,
    sizeInGib: 2,
    createSource: {
        sourceType: "DiskSnapshot",
        sourceId: exampleSnapshot.id,
    },
});
import pulumi
import pulumi_azure as azure
example = azure.core.ResourceGroup("example",
    name="example-rg",
    location="West Europe")
example_elastic_san = azure.elasticsan.ElasticSan("example",
    name="example-es",
    resource_group_name=example.name,
    location=example.location,
    base_size_in_tib=1,
    sku={
        "name": "Premium_LRS",
    })
example_volume_group = azure.elasticsan.VolumeGroup("example",
    name="example-esvg",
    elastic_san_id=example_elastic_san.id)
example_managed_disk = azure.compute.ManagedDisk("example",
    name="example-disk",
    location=example.location,
    resource_group_name=example.name,
    create_option="Empty",
    storage_account_type="Standard_LRS",
    disk_size_gb=2)
example_snapshot = azure.compute.Snapshot("example",
    name="example-ss",
    location=example.location,
    resource_group_name=example.name,
    create_option="Copy",
    source_uri=example_managed_disk.id)
example2 = azure.elasticsan.Volume("example2",
    name="example-esv2",
    volume_group_id=example_volume_group.id,
    size_in_gib=2,
    create_source={
        "source_type": "DiskSnapshot",
        "source_id": example_snapshot.id,
    })
package main
import (
	"github.com/pulumi/pulumi-azure/sdk/v6/go/azure/compute"
	"github.com/pulumi/pulumi-azure/sdk/v6/go/azure/core"
	"github.com/pulumi/pulumi-azure/sdk/v6/go/azure/elasticsan"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		example, err := core.NewResourceGroup(ctx, "example", &core.ResourceGroupArgs{
			Name:     pulumi.String("example-rg"),
			Location: pulumi.String("West Europe"),
		})
		if err != nil {
			return err
		}
		exampleElasticSan, err := elasticsan.NewElasticSan(ctx, "example", &elasticsan.ElasticSanArgs{
			Name:              pulumi.String("example-es"),
			ResourceGroupName: example.Name,
			Location:          example.Location,
			BaseSizeInTib:     pulumi.Int(1),
			Sku: &elasticsan.ElasticSanSkuArgs{
				Name: pulumi.String("Premium_LRS"),
			},
		})
		if err != nil {
			return err
		}
		exampleVolumeGroup, err := elasticsan.NewVolumeGroup(ctx, "example", &elasticsan.VolumeGroupArgs{
			Name:         pulumi.String("example-esvg"),
			ElasticSanId: exampleElasticSan.ID(),
		})
		if err != nil {
			return err
		}
		exampleManagedDisk, err := compute.NewManagedDisk(ctx, "example", &compute.ManagedDiskArgs{
			Name:               pulumi.String("example-disk"),
			Location:           example.Location,
			ResourceGroupName:  example.Name,
			CreateOption:       pulumi.String("Empty"),
			StorageAccountType: pulumi.String("Standard_LRS"),
			DiskSizeGb:         pulumi.Int(2),
		})
		if err != nil {
			return err
		}
		exampleSnapshot, err := compute.NewSnapshot(ctx, "example", &compute.SnapshotArgs{
			Name:              pulumi.String("example-ss"),
			Location:          example.Location,
			ResourceGroupName: example.Name,
			CreateOption:      pulumi.String("Copy"),
			SourceUri:         exampleManagedDisk.ID(),
		})
		if err != nil {
			return err
		}
		_, err = elasticsan.NewVolume(ctx, "example2", &elasticsan.VolumeArgs{
			Name:          pulumi.String("example-esv2"),
			VolumeGroupId: exampleVolumeGroup.ID(),
			SizeInGib:     pulumi.Int(2),
			CreateSource: &elasticsan.VolumeCreateSourceArgs{
				SourceType: pulumi.String("DiskSnapshot"),
				SourceId:   exampleSnapshot.ID(),
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Azure = Pulumi.Azure;
return await Deployment.RunAsync(() => 
{
    var example = new Azure.Core.ResourceGroup("example", new()
    {
        Name = "example-rg",
        Location = "West Europe",
    });
    var exampleElasticSan = new Azure.ElasticSan.ElasticSan("example", new()
    {
        Name = "example-es",
        ResourceGroupName = example.Name,
        Location = example.Location,
        BaseSizeInTib = 1,
        Sku = new Azure.ElasticSan.Inputs.ElasticSanSkuArgs
        {
            Name = "Premium_LRS",
        },
    });
    var exampleVolumeGroup = new Azure.ElasticSan.VolumeGroup("example", new()
    {
        Name = "example-esvg",
        ElasticSanId = exampleElasticSan.Id,
    });
    var exampleManagedDisk = new Azure.Compute.ManagedDisk("example", new()
    {
        Name = "example-disk",
        Location = example.Location,
        ResourceGroupName = example.Name,
        CreateOption = "Empty",
        StorageAccountType = "Standard_LRS",
        DiskSizeGb = 2,
    });
    var exampleSnapshot = new Azure.Compute.Snapshot("example", new()
    {
        Name = "example-ss",
        Location = example.Location,
        ResourceGroupName = example.Name,
        CreateOption = "Copy",
        SourceUri = exampleManagedDisk.Id,
    });
    var example2 = new Azure.ElasticSan.Volume("example2", new()
    {
        Name = "example-esv2",
        VolumeGroupId = exampleVolumeGroup.Id,
        SizeInGib = 2,
        CreateSource = new Azure.ElasticSan.Inputs.VolumeCreateSourceArgs
        {
            SourceType = "DiskSnapshot",
            SourceId = exampleSnapshot.Id,
        },
    });
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azure.core.ResourceGroup;
import com.pulumi.azure.core.ResourceGroupArgs;
import com.pulumi.azure.elasticsan.ElasticSan;
import com.pulumi.azure.elasticsan.ElasticSanArgs;
import com.pulumi.azure.elasticsan.inputs.ElasticSanSkuArgs;
import com.pulumi.azure.elasticsan.VolumeGroup;
import com.pulumi.azure.elasticsan.VolumeGroupArgs;
import com.pulumi.azure.compute.ManagedDisk;
import com.pulumi.azure.compute.ManagedDiskArgs;
import com.pulumi.azure.compute.Snapshot;
import com.pulumi.azure.compute.SnapshotArgs;
import com.pulumi.azure.elasticsan.Volume;
import com.pulumi.azure.elasticsan.VolumeArgs;
import com.pulumi.azure.elasticsan.inputs.VolumeCreateSourceArgs;
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 example = new ResourceGroup("example", ResourceGroupArgs.builder()
            .name("example-rg")
            .location("West Europe")
            .build());
        var exampleElasticSan = new ElasticSan("exampleElasticSan", ElasticSanArgs.builder()
            .name("example-es")
            .resourceGroupName(example.name())
            .location(example.location())
            .baseSizeInTib(1)
            .sku(ElasticSanSkuArgs.builder()
                .name("Premium_LRS")
                .build())
            .build());
        var exampleVolumeGroup = new VolumeGroup("exampleVolumeGroup", VolumeGroupArgs.builder()
            .name("example-esvg")
            .elasticSanId(exampleElasticSan.id())
            .build());
        var exampleManagedDisk = new ManagedDisk("exampleManagedDisk", ManagedDiskArgs.builder()
            .name("example-disk")
            .location(example.location())
            .resourceGroupName(example.name())
            .createOption("Empty")
            .storageAccountType("Standard_LRS")
            .diskSizeGb(2)
            .build());
        var exampleSnapshot = new Snapshot("exampleSnapshot", SnapshotArgs.builder()
            .name("example-ss")
            .location(example.location())
            .resourceGroupName(example.name())
            .createOption("Copy")
            .sourceUri(exampleManagedDisk.id())
            .build());
        var example2 = new Volume("example2", VolumeArgs.builder()
            .name("example-esv2")
            .volumeGroupId(exampleVolumeGroup.id())
            .sizeInGib(2)
            .createSource(VolumeCreateSourceArgs.builder()
                .sourceType("DiskSnapshot")
                .sourceId(exampleSnapshot.id())
                .build())
            .build());
    }
}
resources:
  example:
    type: azure:core:ResourceGroup
    properties:
      name: example-rg
      location: West Europe
  exampleElasticSan:
    type: azure:elasticsan:ElasticSan
    name: example
    properties:
      name: example-es
      resourceGroupName: ${example.name}
      location: ${example.location}
      baseSizeInTib: 1
      sku:
        name: Premium_LRS
  exampleVolumeGroup:
    type: azure:elasticsan:VolumeGroup
    name: example
    properties:
      name: example-esvg
      elasticSanId: ${exampleElasticSan.id}
  exampleManagedDisk:
    type: azure:compute:ManagedDisk
    name: example
    properties:
      name: example-disk
      location: ${example.location}
      resourceGroupName: ${example.name}
      createOption: Empty
      storageAccountType: Standard_LRS
      diskSizeGb: 2
  exampleSnapshot:
    type: azure:compute:Snapshot
    name: example
    properties:
      name: example-ss
      location: ${example.location}
      resourceGroupName: ${example.name}
      createOption: Copy
      sourceUri: ${exampleManagedDisk.id}
  example2:
    type: azure:elasticsan:Volume
    properties:
      name: example-esv2
      volumeGroupId: ${exampleVolumeGroup.id}
      sizeInGib: 2
      createSource:
        sourceType: DiskSnapshot
        sourceId: ${exampleSnapshot.id}
Create Volume Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Volume(name: string, args: VolumeArgs, opts?: CustomResourceOptions);@overload
def Volume(resource_name: str,
           args: VolumeArgs,
           opts: Optional[ResourceOptions] = None)
@overload
def Volume(resource_name: str,
           opts: Optional[ResourceOptions] = None,
           size_in_gib: Optional[int] = None,
           volume_group_id: Optional[str] = None,
           create_source: Optional[VolumeCreateSourceArgs] = None,
           name: Optional[str] = None)func NewVolume(ctx *Context, name string, args VolumeArgs, opts ...ResourceOption) (*Volume, error)public Volume(string name, VolumeArgs args, CustomResourceOptions? opts = null)
public Volume(String name, VolumeArgs args)
public Volume(String name, VolumeArgs args, CustomResourceOptions options)
type: azure:elasticsan:Volume
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 VolumeArgs
- 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 VolumeArgs
- 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 VolumeArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args VolumeArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args VolumeArgs
- 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 volumeResource = new Azure.ElasticSan.Volume("volumeResource", new()
{
    SizeInGib = 0,
    VolumeGroupId = "string",
    CreateSource = new Azure.ElasticSan.Inputs.VolumeCreateSourceArgs
    {
        SourceId = "string",
        SourceType = "string",
    },
    Name = "string",
});
example, err := elasticsan.NewVolume(ctx, "volumeResource", &elasticsan.VolumeArgs{
	SizeInGib:     pulumi.Int(0),
	VolumeGroupId: pulumi.String("string"),
	CreateSource: &elasticsan.VolumeCreateSourceArgs{
		SourceId:   pulumi.String("string"),
		SourceType: pulumi.String("string"),
	},
	Name: pulumi.String("string"),
})
var volumeResource = new Volume("volumeResource", VolumeArgs.builder()
    .sizeInGib(0)
    .volumeGroupId("string")
    .createSource(VolumeCreateSourceArgs.builder()
        .sourceId("string")
        .sourceType("string")
        .build())
    .name("string")
    .build());
volume_resource = azure.elasticsan.Volume("volumeResource",
    size_in_gib=0,
    volume_group_id="string",
    create_source={
        "source_id": "string",
        "source_type": "string",
    },
    name="string")
const volumeResource = new azure.elasticsan.Volume("volumeResource", {
    sizeInGib: 0,
    volumeGroupId: "string",
    createSource: {
        sourceId: "string",
        sourceType: "string",
    },
    name: "string",
});
type: azure:elasticsan:Volume
properties:
    createSource:
        sourceId: string
        sourceType: string
    name: string
    sizeInGib: 0
    volumeGroupId: string
Volume 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 Volume resource accepts the following input properties:
- SizeIn intGib 
- Specifies the size of the Elastic SAN Volume in GiB. The size should be within the remaining capacity of the parent Elastic SAN. Possible values are between - 1and- 65536(16 TiB).- NOTE: The size can only be increased. If - create_sourceis specified, then the size must be equal to or greater than the source's size.
- VolumeGroup stringId 
- Specifies the Volume Group ID within which this Elastic SAN Volume should exist. Changing this forces a new resource to be created.
- CreateSource VolumeCreate Source 
- A create_sourceblock as defined below.
- Name string
- Specifies the name of this Elastic SAN Volume. Changing this forces a new resource to be created.
- SizeIn intGib 
- Specifies the size of the Elastic SAN Volume in GiB. The size should be within the remaining capacity of the parent Elastic SAN. Possible values are between - 1and- 65536(16 TiB).- NOTE: The size can only be increased. If - create_sourceis specified, then the size must be equal to or greater than the source's size.
- VolumeGroup stringId 
- Specifies the Volume Group ID within which this Elastic SAN Volume should exist. Changing this forces a new resource to be created.
- CreateSource VolumeCreate Source Args 
- A create_sourceblock as defined below.
- Name string
- Specifies the name of this Elastic SAN Volume. Changing this forces a new resource to be created.
- sizeIn IntegerGib 
- Specifies the size of the Elastic SAN Volume in GiB. The size should be within the remaining capacity of the parent Elastic SAN. Possible values are between - 1and- 65536(16 TiB).- NOTE: The size can only be increased. If - create_sourceis specified, then the size must be equal to or greater than the source's size.
- volumeGroup StringId 
- Specifies the Volume Group ID within which this Elastic SAN Volume should exist. Changing this forces a new resource to be created.
- createSource VolumeCreate Source 
- A create_sourceblock as defined below.
- name String
- Specifies the name of this Elastic SAN Volume. Changing this forces a new resource to be created.
- sizeIn numberGib 
- Specifies the size of the Elastic SAN Volume in GiB. The size should be within the remaining capacity of the parent Elastic SAN. Possible values are between - 1and- 65536(16 TiB).- NOTE: The size can only be increased. If - create_sourceis specified, then the size must be equal to or greater than the source's size.
- volumeGroup stringId 
- Specifies the Volume Group ID within which this Elastic SAN Volume should exist. Changing this forces a new resource to be created.
- createSource VolumeCreate Source 
- A create_sourceblock as defined below.
- name string
- Specifies the name of this Elastic SAN Volume. Changing this forces a new resource to be created.
- size_in_ intgib 
- Specifies the size of the Elastic SAN Volume in GiB. The size should be within the remaining capacity of the parent Elastic SAN. Possible values are between - 1and- 65536(16 TiB).- NOTE: The size can only be increased. If - create_sourceis specified, then the size must be equal to or greater than the source's size.
- volume_group_ strid 
- Specifies the Volume Group ID within which this Elastic SAN Volume should exist. Changing this forces a new resource to be created.
- create_source VolumeCreate Source Args 
- A create_sourceblock as defined below.
- name str
- Specifies the name of this Elastic SAN Volume. Changing this forces a new resource to be created.
- sizeIn NumberGib 
- Specifies the size of the Elastic SAN Volume in GiB. The size should be within the remaining capacity of the parent Elastic SAN. Possible values are between - 1and- 65536(16 TiB).- NOTE: The size can only be increased. If - create_sourceis specified, then the size must be equal to or greater than the source's size.
- volumeGroup StringId 
- Specifies the Volume Group ID within which this Elastic SAN Volume should exist. Changing this forces a new resource to be created.
- createSource Property Map
- A create_sourceblock as defined below.
- name String
- Specifies the name of this Elastic SAN Volume. Changing this forces a new resource to be created.
Outputs
All input properties are implicitly available as output properties. Additionally, the Volume resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- TargetIqn string
- The iSCSI Target IQN of the Elastic SAN Volume.
- TargetPortal stringHostname 
- The iSCSI Target Portal Host Name of the Elastic SAN Volume.
- TargetPortal intPort 
- The iSCSI Target Portal Port of the Elastic SAN Volume.
- VolumeId string
- The UUID of the Elastic SAN Volume.
- Id string
- The provider-assigned unique ID for this managed resource.
- TargetIqn string
- The iSCSI Target IQN of the Elastic SAN Volume.
- TargetPortal stringHostname 
- The iSCSI Target Portal Host Name of the Elastic SAN Volume.
- TargetPortal intPort 
- The iSCSI Target Portal Port of the Elastic SAN Volume.
- VolumeId string
- The UUID of the Elastic SAN Volume.
- id String
- The provider-assigned unique ID for this managed resource.
- targetIqn String
- The iSCSI Target IQN of the Elastic SAN Volume.
- targetPortal StringHostname 
- The iSCSI Target Portal Host Name of the Elastic SAN Volume.
- targetPortal IntegerPort 
- The iSCSI Target Portal Port of the Elastic SAN Volume.
- volumeId String
- The UUID of the Elastic SAN Volume.
- id string
- The provider-assigned unique ID for this managed resource.
- targetIqn string
- The iSCSI Target IQN of the Elastic SAN Volume.
- targetPortal stringHostname 
- The iSCSI Target Portal Host Name of the Elastic SAN Volume.
- targetPortal numberPort 
- The iSCSI Target Portal Port of the Elastic SAN Volume.
- volumeId string
- The UUID of the Elastic SAN Volume.
- id str
- The provider-assigned unique ID for this managed resource.
- target_iqn str
- The iSCSI Target IQN of the Elastic SAN Volume.
- target_portal_ strhostname 
- The iSCSI Target Portal Host Name of the Elastic SAN Volume.
- target_portal_ intport 
- The iSCSI Target Portal Port of the Elastic SAN Volume.
- volume_id str
- The UUID of the Elastic SAN Volume.
- id String
- The provider-assigned unique ID for this managed resource.
- targetIqn String
- The iSCSI Target IQN of the Elastic SAN Volume.
- targetPortal StringHostname 
- The iSCSI Target Portal Host Name of the Elastic SAN Volume.
- targetPortal NumberPort 
- The iSCSI Target Portal Port of the Elastic SAN Volume.
- volumeId String
- The UUID of the Elastic SAN Volume.
Look up Existing Volume Resource
Get an existing Volume resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: VolumeState, opts?: CustomResourceOptions): Volume@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        create_source: Optional[VolumeCreateSourceArgs] = None,
        name: Optional[str] = None,
        size_in_gib: Optional[int] = None,
        target_iqn: Optional[str] = None,
        target_portal_hostname: Optional[str] = None,
        target_portal_port: Optional[int] = None,
        volume_group_id: Optional[str] = None,
        volume_id: Optional[str] = None) -> Volumefunc GetVolume(ctx *Context, name string, id IDInput, state *VolumeState, opts ...ResourceOption) (*Volume, error)public static Volume Get(string name, Input<string> id, VolumeState? state, CustomResourceOptions? opts = null)public static Volume get(String name, Output<String> id, VolumeState state, CustomResourceOptions options)resources:  _:    type: azure:elasticsan:Volume    get:      id: ${id}- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- CreateSource VolumeCreate Source 
- A create_sourceblock as defined below.
- Name string
- Specifies the name of this Elastic SAN Volume. Changing this forces a new resource to be created.
- SizeIn intGib 
- Specifies the size of the Elastic SAN Volume in GiB. The size should be within the remaining capacity of the parent Elastic SAN. Possible values are between - 1and- 65536(16 TiB).- NOTE: The size can only be increased. If - create_sourceis specified, then the size must be equal to or greater than the source's size.
- TargetIqn string
- The iSCSI Target IQN of the Elastic SAN Volume.
- TargetPortal stringHostname 
- The iSCSI Target Portal Host Name of the Elastic SAN Volume.
- TargetPortal intPort 
- The iSCSI Target Portal Port of the Elastic SAN Volume.
- VolumeGroup stringId 
- Specifies the Volume Group ID within which this Elastic SAN Volume should exist. Changing this forces a new resource to be created.
- VolumeId string
- The UUID of the Elastic SAN Volume.
- CreateSource VolumeCreate Source Args 
- A create_sourceblock as defined below.
- Name string
- Specifies the name of this Elastic SAN Volume. Changing this forces a new resource to be created.
- SizeIn intGib 
- Specifies the size of the Elastic SAN Volume in GiB. The size should be within the remaining capacity of the parent Elastic SAN. Possible values are between - 1and- 65536(16 TiB).- NOTE: The size can only be increased. If - create_sourceis specified, then the size must be equal to or greater than the source's size.
- TargetIqn string
- The iSCSI Target IQN of the Elastic SAN Volume.
- TargetPortal stringHostname 
- The iSCSI Target Portal Host Name of the Elastic SAN Volume.
- TargetPortal intPort 
- The iSCSI Target Portal Port of the Elastic SAN Volume.
- VolumeGroup stringId 
- Specifies the Volume Group ID within which this Elastic SAN Volume should exist. Changing this forces a new resource to be created.
- VolumeId string
- The UUID of the Elastic SAN Volume.
- createSource VolumeCreate Source 
- A create_sourceblock as defined below.
- name String
- Specifies the name of this Elastic SAN Volume. Changing this forces a new resource to be created.
- sizeIn IntegerGib 
- Specifies the size of the Elastic SAN Volume in GiB. The size should be within the remaining capacity of the parent Elastic SAN. Possible values are between - 1and- 65536(16 TiB).- NOTE: The size can only be increased. If - create_sourceis specified, then the size must be equal to or greater than the source's size.
- targetIqn String
- The iSCSI Target IQN of the Elastic SAN Volume.
- targetPortal StringHostname 
- The iSCSI Target Portal Host Name of the Elastic SAN Volume.
- targetPortal IntegerPort 
- The iSCSI Target Portal Port of the Elastic SAN Volume.
- volumeGroup StringId 
- Specifies the Volume Group ID within which this Elastic SAN Volume should exist. Changing this forces a new resource to be created.
- volumeId String
- The UUID of the Elastic SAN Volume.
- createSource VolumeCreate Source 
- A create_sourceblock as defined below.
- name string
- Specifies the name of this Elastic SAN Volume. Changing this forces a new resource to be created.
- sizeIn numberGib 
- Specifies the size of the Elastic SAN Volume in GiB. The size should be within the remaining capacity of the parent Elastic SAN. Possible values are between - 1and- 65536(16 TiB).- NOTE: The size can only be increased. If - create_sourceis specified, then the size must be equal to or greater than the source's size.
- targetIqn string
- The iSCSI Target IQN of the Elastic SAN Volume.
- targetPortal stringHostname 
- The iSCSI Target Portal Host Name of the Elastic SAN Volume.
- targetPortal numberPort 
- The iSCSI Target Portal Port of the Elastic SAN Volume.
- volumeGroup stringId 
- Specifies the Volume Group ID within which this Elastic SAN Volume should exist. Changing this forces a new resource to be created.
- volumeId string
- The UUID of the Elastic SAN Volume.
- create_source VolumeCreate Source Args 
- A create_sourceblock as defined below.
- name str
- Specifies the name of this Elastic SAN Volume. Changing this forces a new resource to be created.
- size_in_ intgib 
- Specifies the size of the Elastic SAN Volume in GiB. The size should be within the remaining capacity of the parent Elastic SAN. Possible values are between - 1and- 65536(16 TiB).- NOTE: The size can only be increased. If - create_sourceis specified, then the size must be equal to or greater than the source's size.
- target_iqn str
- The iSCSI Target IQN of the Elastic SAN Volume.
- target_portal_ strhostname 
- The iSCSI Target Portal Host Name of the Elastic SAN Volume.
- target_portal_ intport 
- The iSCSI Target Portal Port of the Elastic SAN Volume.
- volume_group_ strid 
- Specifies the Volume Group ID within which this Elastic SAN Volume should exist. Changing this forces a new resource to be created.
- volume_id str
- The UUID of the Elastic SAN Volume.
- createSource Property Map
- A create_sourceblock as defined below.
- name String
- Specifies the name of this Elastic SAN Volume. Changing this forces a new resource to be created.
- sizeIn NumberGib 
- Specifies the size of the Elastic SAN Volume in GiB. The size should be within the remaining capacity of the parent Elastic SAN. Possible values are between - 1and- 65536(16 TiB).- NOTE: The size can only be increased. If - create_sourceis specified, then the size must be equal to or greater than the source's size.
- targetIqn String
- The iSCSI Target IQN of the Elastic SAN Volume.
- targetPortal StringHostname 
- The iSCSI Target Portal Host Name of the Elastic SAN Volume.
- targetPortal NumberPort 
- The iSCSI Target Portal Port of the Elastic SAN Volume.
- volumeGroup StringId 
- Specifies the Volume Group ID within which this Elastic SAN Volume should exist. Changing this forces a new resource to be created.
- volumeId String
- The UUID of the Elastic SAN Volume.
Supporting Types
VolumeCreateSource, VolumeCreateSourceArgs      
- SourceId string
- Specifies the ID of the source to create the Elastic SAN Volume from. Changing this forces a new resource to be created.
- SourceType string
- Specifies the type of the source to create the Elastic SAN Volume from. Possible values are Disk,DiskRestorePoint,DiskSnapshotandVolumeSnapshot. Changing this forces a new resource to be created.
- SourceId string
- Specifies the ID of the source to create the Elastic SAN Volume from. Changing this forces a new resource to be created.
- SourceType string
- Specifies the type of the source to create the Elastic SAN Volume from. Possible values are Disk,DiskRestorePoint,DiskSnapshotandVolumeSnapshot. Changing this forces a new resource to be created.
- sourceId String
- Specifies the ID of the source to create the Elastic SAN Volume from. Changing this forces a new resource to be created.
- sourceType String
- Specifies the type of the source to create the Elastic SAN Volume from. Possible values are Disk,DiskRestorePoint,DiskSnapshotandVolumeSnapshot. Changing this forces a new resource to be created.
- sourceId string
- Specifies the ID of the source to create the Elastic SAN Volume from. Changing this forces a new resource to be created.
- sourceType string
- Specifies the type of the source to create the Elastic SAN Volume from. Possible values are Disk,DiskRestorePoint,DiskSnapshotandVolumeSnapshot. Changing this forces a new resource to be created.
- source_id str
- Specifies the ID of the source to create the Elastic SAN Volume from. Changing this forces a new resource to be created.
- source_type str
- Specifies the type of the source to create the Elastic SAN Volume from. Possible values are Disk,DiskRestorePoint,DiskSnapshotandVolumeSnapshot. Changing this forces a new resource to be created.
- sourceId String
- Specifies the ID of the source to create the Elastic SAN Volume from. Changing this forces a new resource to be created.
- sourceType String
- Specifies the type of the source to create the Elastic SAN Volume from. Possible values are Disk,DiskRestorePoint,DiskSnapshotandVolumeSnapshot. Changing this forces a new resource to be created.
Import
An existing Elastic SAN Volume can be imported into Pulumi using the resource id, e.g.
$ pulumi import azure:elasticsan/volume:Volume example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.ElasticSan/elasticSans/esan1/volumeGroups/vg1/volumes/vol1
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Azure Classic pulumi/pulumi-azure
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the azurermTerraform Provider.