GetVolume

Get information on a volume for use in other resources. This data source provides all of the volumes properties as configured on your DigitalOcean account. This is useful if the volume in question is not managed by this provider or you need to utilize any of the volumes data.

An error is triggered if the provided volume name does not exist.

Example Usage

using Pulumi;
using DigitalOcean = Pulumi.DigitalOcean;

class MyStack : Stack
{
    public MyStack()
    {
        var example = Output.Create(DigitalOcean.GetVolume.InvokeAsync(new DigitalOcean.GetVolumeArgs
        {
            Name = "app-data",
            Region = "nyc3",
        }));
    }

}

Coming soon!

import pulumi
import pulumi_digitalocean as digitalocean

example = digitalocean.get_volume(name="app-data",
    region="nyc3")
import * as pulumi from "@pulumi/pulumi";
import * as digitalocean from "@pulumi/digitalocean";

const example = pulumi.output(digitalocean.getVolume({
    name: "app-data",
    region: "nyc3",
}, { async: true }));

Using GetVolume

function getVolume(args: GetVolumeArgs, opts?: InvokeOptions): Promise<GetVolumeResult>
function  get_volume(description=None, name=None, region=None, opts=None)
func LookupVolume(ctx *Context, args *LookupVolumeArgs, opts ...InvokeOption) (*LookupVolumeResult, error)

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

public static class GetVolume {
    public static Task<GetVolumeResult> InvokeAsync(GetVolumeArgs args, InvokeOptions? opts = null)
}

The following arguments are supported:

Name string

The name of block storage volume.

Description string

Text describing a block storage volume.

Region string

The region the block storage volume is provisioned in.

Name string

The name of block storage volume.

Description string

Text describing a block storage volume.

Region string

The region the block storage volume is provisioned in.

name string

The name of block storage volume.

description string

Text describing a block storage volume.

region string

The region the block storage volume is provisioned in.

name str

The name of block storage volume.

description str

Text describing a block storage volume.

region str

The region the block storage volume is provisioned in.

GetVolume Result

The following output properties are available:

DropletIds List<int>

A list of associated Droplet ids.

FilesystemLabel string

Filesystem label currently in-use on the block storage volume.

FilesystemType string

Filesystem type currently in-use on the block storage volume.

Id string

The provider-assigned unique ID for this managed resource.

Name string
Size int

The size of the block storage volume in GiB.

Tags List<string>

A list of the tags associated to the Volume.

Urn string
Description string

Text describing a block storage volume.

Region string
DropletIds []int

A list of associated Droplet ids.

FilesystemLabel string

Filesystem label currently in-use on the block storage volume.

FilesystemType string

Filesystem type currently in-use on the block storage volume.

Id string

The provider-assigned unique ID for this managed resource.

Name string
Size int

The size of the block storage volume in GiB.

Tags []string

A list of the tags associated to the Volume.

Urn string
Description string

Text describing a block storage volume.

Region string
dropletIds number[]

A list of associated Droplet ids.

filesystemLabel string

Filesystem label currently in-use on the block storage volume.

filesystemType string

Filesystem type currently in-use on the block storage volume.

id string

The provider-assigned unique ID for this managed resource.

name string
size number

The size of the block storage volume in GiB.

tags string[]

A list of the tags associated to the Volume.

urn string
description string

Text describing a block storage volume.

region string
droplet_ids List[Integer]

A list of associated Droplet ids.

filesystem_label str

Filesystem label currently in-use on the block storage volume.

filesystem_type str

Filesystem type currently in-use on the block storage volume.

id str

The provider-assigned unique ID for this managed resource.

name str
size float

The size of the block storage volume in GiB.

tags List[str]

A list of the tags associated to the Volume.

urn str
description str

Text describing a block storage volume.

region str

Package Details

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