digitalocean.Volume
Explore with Pulumi AI
Provides a DigitalOcean Block Storage volume which can be attached to a Droplet in order to provide expanded storage.
Example Usage
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using DigitalOcean = Pulumi.DigitalOcean;
return await Deployment.RunAsync(() =>
{
var foobarVolume = new DigitalOcean.Volume("foobarVolume", new()
{
Region = "nyc1",
Size = 100,
InitialFilesystemType = "ext4",
Description = "an example volume",
});
var foobarDroplet = new DigitalOcean.Droplet("foobarDroplet", new()
{
Size = "s-1vcpu-1gb",
Image = "ubuntu-18-04-x64",
Region = "nyc1",
});
var foobarVolumeAttachment = new DigitalOcean.VolumeAttachment("foobarVolumeAttachment", new()
{
DropletId = foobarDroplet.Id,
VolumeId = foobarVolume.Id,
});
});
package main
import (
"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
foobarVolume, err := digitalocean.NewVolume(ctx, "foobarVolume", &digitalocean.VolumeArgs{
Region: pulumi.String("nyc1"),
Size: pulumi.Int(100),
InitialFilesystemType: pulumi.String("ext4"),
Description: pulumi.String("an example volume"),
})
if err != nil {
return err
}
foobarDroplet, err := digitalocean.NewDroplet(ctx, "foobarDroplet", &digitalocean.DropletArgs{
Size: pulumi.String("s-1vcpu-1gb"),
Image: pulumi.String("ubuntu-18-04-x64"),
Region: pulumi.String("nyc1"),
})
if err != nil {
return err
}
_, err = digitalocean.NewVolumeAttachment(ctx, "foobarVolumeAttachment", &digitalocean.VolumeAttachmentArgs{
DropletId: foobarDroplet.ID(),
VolumeId: foobarVolume.ID(),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.digitalocean.Volume;
import com.pulumi.digitalocean.VolumeArgs;
import com.pulumi.digitalocean.Droplet;
import com.pulumi.digitalocean.DropletArgs;
import com.pulumi.digitalocean.VolumeAttachment;
import com.pulumi.digitalocean.VolumeAttachmentArgs;
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 foobarVolume = new Volume("foobarVolume", VolumeArgs.builder()
.region("nyc1")
.size(100)
.initialFilesystemType("ext4")
.description("an example volume")
.build());
var foobarDroplet = new Droplet("foobarDroplet", DropletArgs.builder()
.size("s-1vcpu-1gb")
.image("ubuntu-18-04-x64")
.region("nyc1")
.build());
var foobarVolumeAttachment = new VolumeAttachment("foobarVolumeAttachment", VolumeAttachmentArgs.builder()
.dropletId(foobarDroplet.id())
.volumeId(foobarVolume.id())
.build());
}
}
import pulumi
import pulumi_digitalocean as digitalocean
foobar_volume = digitalocean.Volume("foobarVolume",
region="nyc1",
size=100,
initial_filesystem_type="ext4",
description="an example volume")
foobar_droplet = digitalocean.Droplet("foobarDroplet",
size="s-1vcpu-1gb",
image="ubuntu-18-04-x64",
region="nyc1")
foobar_volume_attachment = digitalocean.VolumeAttachment("foobarVolumeAttachment",
droplet_id=foobar_droplet.id,
volume_id=foobar_volume.id)
import * as pulumi from "@pulumi/pulumi";
import * as digitalocean from "@pulumi/digitalocean";
const foobarVolume = new digitalocean.Volume("foobarVolume", {
region: "nyc1",
size: 100,
initialFilesystemType: "ext4",
description: "an example volume",
});
const foobarDroplet = new digitalocean.Droplet("foobarDroplet", {
size: "s-1vcpu-1gb",
image: "ubuntu-18-04-x64",
region: "nyc1",
});
const foobarVolumeAttachment = new digitalocean.VolumeAttachment("foobarVolumeAttachment", {
dropletId: foobarDroplet.id,
volumeId: foobarVolume.id,
});
resources:
foobarVolume:
type: digitalocean:Volume
properties:
region: nyc1
size: 100
initialFilesystemType: ext4
description: an example volume
foobarDroplet:
type: digitalocean:Droplet
properties:
size: s-1vcpu-1gb
image: ubuntu-18-04-x64
region: nyc1
foobarVolumeAttachment:
type: digitalocean:VolumeAttachment
properties:
dropletId: ${foobarDroplet.id}
volumeId: ${foobarVolume.id}
You can also create a volume from an existing snapshot.
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using DigitalOcean = Pulumi.DigitalOcean;
return await Deployment.RunAsync(() =>
{
var foobarVolumeSnapshot = DigitalOcean.GetVolumeSnapshot.Invoke(new()
{
Name = "baz",
});
var foobarVolume = new DigitalOcean.Volume("foobarVolume", new()
{
Region = "lon1",
Size = foobarVolumeSnapshot.Apply(getVolumeSnapshotResult => getVolumeSnapshotResult.MinDiskSize),
SnapshotId = foobarVolumeSnapshot.Apply(getVolumeSnapshotResult => getVolumeSnapshotResult.Id),
});
});
package main
import (
"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
foobarVolumeSnapshot, err := digitalocean.LookupVolumeSnapshot(ctx, &digitalocean.LookupVolumeSnapshotArgs{
Name: pulumi.StringRef("baz"),
}, nil)
if err != nil {
return err
}
_, err = digitalocean.NewVolume(ctx, "foobarVolume", &digitalocean.VolumeArgs{
Region: pulumi.String("lon1"),
Size: *pulumi.Int(foobarVolumeSnapshot.MinDiskSize),
SnapshotId: *pulumi.String(foobarVolumeSnapshot.Id),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.digitalocean.DigitaloceanFunctions;
import com.pulumi.digitalocean.inputs.GetVolumeSnapshotArgs;
import com.pulumi.digitalocean.Volume;
import com.pulumi.digitalocean.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) {
final var foobarVolumeSnapshot = DigitaloceanFunctions.getVolumeSnapshot(GetVolumeSnapshotArgs.builder()
.name("baz")
.build());
var foobarVolume = new Volume("foobarVolume", VolumeArgs.builder()
.region("lon1")
.size(foobarVolumeSnapshot.applyValue(getVolumeSnapshotResult -> getVolumeSnapshotResult.minDiskSize()))
.snapshotId(foobarVolumeSnapshot.applyValue(getVolumeSnapshotResult -> getVolumeSnapshotResult.id()))
.build());
}
}
import pulumi
import pulumi_digitalocean as digitalocean
foobar_volume_snapshot = digitalocean.get_volume_snapshot(name="baz")
foobar_volume = digitalocean.Volume("foobarVolume",
region="lon1",
size=foobar_volume_snapshot.min_disk_size,
snapshot_id=foobar_volume_snapshot.id)
import * as pulumi from "@pulumi/pulumi";
import * as digitalocean from "@pulumi/digitalocean";
const foobarVolumeSnapshot = digitalocean.getVolumeSnapshot({
name: "baz",
});
const foobarVolume = new digitalocean.Volume("foobarVolume", {
region: "lon1",
size: foobarVolumeSnapshot.then(foobarVolumeSnapshot => foobarVolumeSnapshot.minDiskSize),
snapshotId: foobarVolumeSnapshot.then(foobarVolumeSnapshot => foobarVolumeSnapshot.id),
});
resources:
foobarVolume:
type: digitalocean:Volume
properties:
region: lon1
size: ${foobarVolumeSnapshot.minDiskSize}
snapshotId: ${foobarVolumeSnapshot.id}
variables:
foobarVolumeSnapshot:
fn::invoke:
Function: digitalocean:getVolumeSnapshot
Arguments:
name: baz
Create Volume Resource
new Volume(name: string, args: VolumeArgs, opts?: CustomResourceOptions);
@overload
def Volume(resource_name: str,
opts: Optional[ResourceOptions] = None,
description: Optional[str] = None,
filesystem_type: Optional[str] = None,
initial_filesystem_label: Optional[str] = None,
initial_filesystem_type: Optional[Union[str, FileSystemType]] = None,
name: Optional[str] = None,
region: Optional[Union[str, Region]] = None,
size: Optional[int] = None,
snapshot_id: Optional[str] = None,
tags: Optional[Sequence[str]] = None)
@overload
def Volume(resource_name: str,
args: VolumeArgs,
opts: Optional[ResourceOptions] = 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: digitalocean:Volume
properties: # The arguments to resource properties.
options: # 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.
- 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.
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
The Volume resource accepts the following input properties:
- Region
string | Pulumi.
Digital Ocean. Region The region that the block storage volume will be created in.
- Size int
The size of the block storage volume in GiB. If updated, can only be expanded.
- Description string
A free-form text field up to a limit of 1024 bytes to describe a block storage volume.
- Filesystem
Type string Filesystem type (
xfs
orext4
) for the block storage volume.This fields functionality has been replaced by
initial_filesystem_type
. The property will still remain as a computed attribute representing the current volumes filesystem type.- Initial
Filesystem stringLabel Initial filesystem label for the block storage volume.
- Initial
Filesystem string | Pulumi.Type Digital Ocean. File System Type Initial filesystem type (
xfs
orext4
) for the block storage volume.- Name string
A name for the block storage volume. Must be lowercase and be composed only of numbers, letters and "-", up to a limit of 64 characters. The name must begin with a letter.
- Snapshot
Id string The ID of an existing volume snapshot from which the new volume will be created. If supplied, the region and size will be limitied on creation to that of the referenced snapshot
- List<string>
A list of the tags to be applied to this Volume.
- Region string | Region
The region that the block storage volume will be created in.
- Size int
The size of the block storage volume in GiB. If updated, can only be expanded.
- Description string
A free-form text field up to a limit of 1024 bytes to describe a block storage volume.
- Filesystem
Type string Filesystem type (
xfs
orext4
) for the block storage volume.This fields functionality has been replaced by
initial_filesystem_type
. The property will still remain as a computed attribute representing the current volumes filesystem type.- Initial
Filesystem stringLabel Initial filesystem label for the block storage volume.
- Initial
Filesystem string | FileType System Type Initial filesystem type (
xfs
orext4
) for the block storage volume.- Name string
A name for the block storage volume. Must be lowercase and be composed only of numbers, letters and "-", up to a limit of 64 characters. The name must begin with a letter.
- Snapshot
Id string The ID of an existing volume snapshot from which the new volume will be created. If supplied, the region and size will be limitied on creation to that of the referenced snapshot
- []string
A list of the tags to be applied to this Volume.
- region String | Region
The region that the block storage volume will be created in.
- size Integer
The size of the block storage volume in GiB. If updated, can only be expanded.
- description String
A free-form text field up to a limit of 1024 bytes to describe a block storage volume.
- filesystem
Type String Filesystem type (
xfs
orext4
) for the block storage volume.This fields functionality has been replaced by
initial_filesystem_type
. The property will still remain as a computed attribute representing the current volumes filesystem type.- initial
Filesystem StringLabel Initial filesystem label for the block storage volume.
- initial
Filesystem String | FileType System Type Initial filesystem type (
xfs
orext4
) for the block storage volume.- name String
A name for the block storage volume. Must be lowercase and be composed only of numbers, letters and "-", up to a limit of 64 characters. The name must begin with a letter.
- snapshot
Id String The ID of an existing volume snapshot from which the new volume will be created. If supplied, the region and size will be limitied on creation to that of the referenced snapshot
- List<String>
A list of the tags to be applied to this Volume.
- region string | Region
The region that the block storage volume will be created in.
- size number
The size of the block storage volume in GiB. If updated, can only be expanded.
- description string
A free-form text field up to a limit of 1024 bytes to describe a block storage volume.
- filesystem
Type string Filesystem type (
xfs
orext4
) for the block storage volume.This fields functionality has been replaced by
initial_filesystem_type
. The property will still remain as a computed attribute representing the current volumes filesystem type.- initial
Filesystem stringLabel Initial filesystem label for the block storage volume.
- initial
Filesystem string | FileType System Type Initial filesystem type (
xfs
orext4
) for the block storage volume.- name string
A name for the block storage volume. Must be lowercase and be composed only of numbers, letters and "-", up to a limit of 64 characters. The name must begin with a letter.
- snapshot
Id string The ID of an existing volume snapshot from which the new volume will be created. If supplied, the region and size will be limitied on creation to that of the referenced snapshot
- string[]
A list of the tags to be applied to this Volume.
- region str | Region
The region that the block storage volume will be created in.
- size int
The size of the block storage volume in GiB. If updated, can only be expanded.
- description str
A free-form text field up to a limit of 1024 bytes to describe a block storage volume.
- filesystem_
type str Filesystem type (
xfs
orext4
) for the block storage volume.This fields functionality has been replaced by
initial_filesystem_type
. The property will still remain as a computed attribute representing the current volumes filesystem type.- initial_
filesystem_ strlabel Initial filesystem label for the block storage volume.
- initial_
filesystem_ str | Filetype System Type Initial filesystem type (
xfs
orext4
) for the block storage volume.- name str
A name for the block storage volume. Must be lowercase and be composed only of numbers, letters and "-", up to a limit of 64 characters. The name must begin with a letter.
- snapshot_
id str The ID of an existing volume snapshot from which the new volume will be created. If supplied, the region and size will be limitied on creation to that of the referenced snapshot
- Sequence[str]
A list of the tags to be applied to this Volume.
- region String | "nyc1" | "nyc2" | "nyc3" | "sgp1" | "lon1" | "ams2" | "ams3" | "fra1" | "tor1" | "sfo1" | "sfo2" | "sfo3" | "blr1"
The region that the block storage volume will be created in.
- size Number
The size of the block storage volume in GiB. If updated, can only be expanded.
- description String
A free-form text field up to a limit of 1024 bytes to describe a block storage volume.
- filesystem
Type String Filesystem type (
xfs
orext4
) for the block storage volume.This fields functionality has been replaced by
initial_filesystem_type
. The property will still remain as a computed attribute representing the current volumes filesystem type.- initial
Filesystem StringLabel Initial filesystem label for the block storage volume.
- initial
Filesystem String | "ext4" | "xfs"Type Initial filesystem type (
xfs
orext4
) for the block storage volume.- name String
A name for the block storage volume. Must be lowercase and be composed only of numbers, letters and "-", up to a limit of 64 characters. The name must begin with a letter.
- snapshot
Id String The ID of an existing volume snapshot from which the new volume will be created. If supplied, the region and size will be limitied on creation to that of the referenced snapshot
- List<String>
A list of the tags to be applied to this Volume.
Outputs
All input properties are implicitly available as output properties. Additionally, the Volume resource produces the following output properties:
- Droplet
Ids List<int> A list of associated droplet ids.
- Filesystem
Label string Filesystem label for the block storage volume.
- Id string
The provider-assigned unique ID for this managed resource.
- Volume
Urn string The uniform resource name for the volume.
- Droplet
Ids []int A list of associated droplet ids.
- Filesystem
Label string Filesystem label for the block storage volume.
- Id string
The provider-assigned unique ID for this managed resource.
- Volume
Urn string The uniform resource name for the volume.
- droplet
Ids List<Integer> A list of associated droplet ids.
- filesystem
Label String Filesystem label for the block storage volume.
- id String
The provider-assigned unique ID for this managed resource.
- volume
Urn String The uniform resource name for the volume.
- droplet
Ids number[] A list of associated droplet ids.
- filesystem
Label string Filesystem label for the block storage volume.
- id string
The provider-assigned unique ID for this managed resource.
- volume
Urn string The uniform resource name for the volume.
- droplet_
ids Sequence[int] A list of associated droplet ids.
- filesystem_
label str Filesystem label for the block storage volume.
- id str
The provider-assigned unique ID for this managed resource.
- volume_
urn str The uniform resource name for the volume.
- droplet
Ids List<Number> A list of associated droplet ids.
- filesystem
Label String Filesystem label for the block storage volume.
- id String
The provider-assigned unique ID for this managed resource.
- volume
Urn String The uniform resource name for the 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,
description: Optional[str] = None,
droplet_ids: Optional[Sequence[int]] = None,
filesystem_label: Optional[str] = None,
filesystem_type: Optional[str] = None,
initial_filesystem_label: Optional[str] = None,
initial_filesystem_type: Optional[Union[str, FileSystemType]] = None,
name: Optional[str] = None,
region: Optional[Union[str, Region]] = None,
size: Optional[int] = None,
snapshot_id: Optional[str] = None,
tags: Optional[Sequence[str]] = None,
volume_urn: Optional[str] = None) -> Volume
func 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)
Resource lookup is not supported in YAML
- 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.
- Description string
A free-form text field up to a limit of 1024 bytes to describe a block storage volume.
- Droplet
Ids List<int> A list of associated droplet ids.
- Filesystem
Label string Filesystem label for the block storage volume.
- Filesystem
Type string Filesystem type (
xfs
orext4
) for the block storage volume.This fields functionality has been replaced by
initial_filesystem_type
. The property will still remain as a computed attribute representing the current volumes filesystem type.- Initial
Filesystem stringLabel Initial filesystem label for the block storage volume.
- Initial
Filesystem string | Pulumi.Type Digital Ocean. File System Type Initial filesystem type (
xfs
orext4
) for the block storage volume.- Name string
A name for the block storage volume. Must be lowercase and be composed only of numbers, letters and "-", up to a limit of 64 characters. The name must begin with a letter.
- Region
string | Pulumi.
Digital Ocean. Region The region that the block storage volume will be created in.
- Size int
The size of the block storage volume in GiB. If updated, can only be expanded.
- Snapshot
Id string The ID of an existing volume snapshot from which the new volume will be created. If supplied, the region and size will be limitied on creation to that of the referenced snapshot
- List<string>
A list of the tags to be applied to this Volume.
- Volume
Urn string The uniform resource name for the volume.
- Description string
A free-form text field up to a limit of 1024 bytes to describe a block storage volume.
- Droplet
Ids []int A list of associated droplet ids.
- Filesystem
Label string Filesystem label for the block storage volume.
- Filesystem
Type string Filesystem type (
xfs
orext4
) for the block storage volume.This fields functionality has been replaced by
initial_filesystem_type
. The property will still remain as a computed attribute representing the current volumes filesystem type.- Initial
Filesystem stringLabel Initial filesystem label for the block storage volume.
- Initial
Filesystem string | FileType System Type Initial filesystem type (
xfs
orext4
) for the block storage volume.- Name string
A name for the block storage volume. Must be lowercase and be composed only of numbers, letters and "-", up to a limit of 64 characters. The name must begin with a letter.
- Region string | Region
The region that the block storage volume will be created in.
- Size int
The size of the block storage volume in GiB. If updated, can only be expanded.
- Snapshot
Id string The ID of an existing volume snapshot from which the new volume will be created. If supplied, the region and size will be limitied on creation to that of the referenced snapshot
- []string
A list of the tags to be applied to this Volume.
- Volume
Urn string The uniform resource name for the volume.
- description String
A free-form text field up to a limit of 1024 bytes to describe a block storage volume.
- droplet
Ids List<Integer> A list of associated droplet ids.
- filesystem
Label String Filesystem label for the block storage volume.
- filesystem
Type String Filesystem type (
xfs
orext4
) for the block storage volume.This fields functionality has been replaced by
initial_filesystem_type
. The property will still remain as a computed attribute representing the current volumes filesystem type.- initial
Filesystem StringLabel Initial filesystem label for the block storage volume.
- initial
Filesystem String | FileType System Type Initial filesystem type (
xfs
orext4
) for the block storage volume.- name String
A name for the block storage volume. Must be lowercase and be composed only of numbers, letters and "-", up to a limit of 64 characters. The name must begin with a letter.
- region String | Region
The region that the block storage volume will be created in.
- size Integer
The size of the block storage volume in GiB. If updated, can only be expanded.
- snapshot
Id String The ID of an existing volume snapshot from which the new volume will be created. If supplied, the region and size will be limitied on creation to that of the referenced snapshot
- List<String>
A list of the tags to be applied to this Volume.
- volume
Urn String The uniform resource name for the volume.
- description string
A free-form text field up to a limit of 1024 bytes to describe a block storage volume.
- droplet
Ids number[] A list of associated droplet ids.
- filesystem
Label string Filesystem label for the block storage volume.
- filesystem
Type string Filesystem type (
xfs
orext4
) for the block storage volume.This fields functionality has been replaced by
initial_filesystem_type
. The property will still remain as a computed attribute representing the current volumes filesystem type.- initial
Filesystem stringLabel Initial filesystem label for the block storage volume.
- initial
Filesystem string | FileType System Type Initial filesystem type (
xfs
orext4
) for the block storage volume.- name string
A name for the block storage volume. Must be lowercase and be composed only of numbers, letters and "-", up to a limit of 64 characters. The name must begin with a letter.
- region string | Region
The region that the block storage volume will be created in.
- size number
The size of the block storage volume in GiB. If updated, can only be expanded.
- snapshot
Id string The ID of an existing volume snapshot from which the new volume will be created. If supplied, the region and size will be limitied on creation to that of the referenced snapshot
- string[]
A list of the tags to be applied to this Volume.
- volume
Urn string The uniform resource name for the volume.
- description str
A free-form text field up to a limit of 1024 bytes to describe a block storage volume.
- droplet_
ids Sequence[int] A list of associated droplet ids.
- filesystem_
label str Filesystem label for the block storage volume.
- filesystem_
type str Filesystem type (
xfs
orext4
) for the block storage volume.This fields functionality has been replaced by
initial_filesystem_type
. The property will still remain as a computed attribute representing the current volumes filesystem type.- initial_
filesystem_ strlabel Initial filesystem label for the block storage volume.
- initial_
filesystem_ str | Filetype System Type Initial filesystem type (
xfs
orext4
) for the block storage volume.- name str
A name for the block storage volume. Must be lowercase and be composed only of numbers, letters and "-", up to a limit of 64 characters. The name must begin with a letter.
- region str | Region
The region that the block storage volume will be created in.
- size int
The size of the block storage volume in GiB. If updated, can only be expanded.
- snapshot_
id str The ID of an existing volume snapshot from which the new volume will be created. If supplied, the region and size will be limitied on creation to that of the referenced snapshot
- Sequence[str]
A list of the tags to be applied to this Volume.
- volume_
urn str The uniform resource name for the volume.
- description String
A free-form text field up to a limit of 1024 bytes to describe a block storage volume.
- droplet
Ids List<Number> A list of associated droplet ids.
- filesystem
Label String Filesystem label for the block storage volume.
- filesystem
Type String Filesystem type (
xfs
orext4
) for the block storage volume.This fields functionality has been replaced by
initial_filesystem_type
. The property will still remain as a computed attribute representing the current volumes filesystem type.- initial
Filesystem StringLabel Initial filesystem label for the block storage volume.
- initial
Filesystem String | "ext4" | "xfs"Type Initial filesystem type (
xfs
orext4
) for the block storage volume.- name String
A name for the block storage volume. Must be lowercase and be composed only of numbers, letters and "-", up to a limit of 64 characters. The name must begin with a letter.
- region String | "nyc1" | "nyc2" | "nyc3" | "sgp1" | "lon1" | "ams2" | "ams3" | "fra1" | "tor1" | "sfo1" | "sfo2" | "sfo3" | "blr1"
The region that the block storage volume will be created in.
- size Number
The size of the block storage volume in GiB. If updated, can only be expanded.
- snapshot
Id String The ID of an existing volume snapshot from which the new volume will be created. If supplied, the region and size will be limitied on creation to that of the referenced snapshot
- List<String>
A list of the tags to be applied to this Volume.
- volume
Urn String The uniform resource name for the volume.
Supporting Types
FileSystemType, FileSystemTypeArgs
- EXT4
- ext4
- XFS
- xfs
- File
System Type EXT4 - ext4
- File
System Type XFS - xfs
- EXT4
- ext4
- XFS
- xfs
- EXT4
- ext4
- XFS
- xfs
- EXT4
- ext4
- XFS
- xfs
- "ext4"
- ext4
- "xfs"
- xfs
Region, RegionArgs
- NYC1
- nyc1
- NYC2
- nyc2
- NYC3
- nyc3
- SGP1
- sgp1
- LON1
- lon1
- AMS2
- ams2
- AMS3
- ams3
- FRA1
- fra1
- TOR1
- tor1
- SFO1
- sfo1
- SFO2
- sfo2
- SFO3
- sfo3
- BLR1
- blr1
- Region
NYC1 - nyc1
- Region
NYC2 - nyc2
- Region
NYC3 - nyc3
- Region
SGP1 - sgp1
- Region
LON1 - lon1
- Region
AMS2 - ams2
- Region
AMS3 - ams3
- Region
FRA1 - fra1
- Region
TOR1 - tor1
- Region
SFO1 - sfo1
- Region
SFO2 - sfo2
- Region
SFO3 - sfo3
- Region
BLR1 - blr1
- NYC1
- nyc1
- NYC2
- nyc2
- NYC3
- nyc3
- SGP1
- sgp1
- LON1
- lon1
- AMS2
- ams2
- AMS3
- ams3
- FRA1
- fra1
- TOR1
- tor1
- SFO1
- sfo1
- SFO2
- sfo2
- SFO3
- sfo3
- BLR1
- blr1
- NYC1
- nyc1
- NYC2
- nyc2
- NYC3
- nyc3
- SGP1
- sgp1
- LON1
- lon1
- AMS2
- ams2
- AMS3
- ams3
- FRA1
- fra1
- TOR1
- tor1
- SFO1
- sfo1
- SFO2
- sfo2
- SFO3
- sfo3
- BLR1
- blr1
- NYC1
- nyc1
- NYC2
- nyc2
- NYC3
- nyc3
- SGP1
- sgp1
- LON1
- lon1
- AMS2
- ams2
- AMS3
- ams3
- FRA1
- fra1
- TOR1
- tor1
- SFO1
- sfo1
- SFO2
- sfo2
- SFO3
- sfo3
- BLR1
- blr1
- "nyc1"
- nyc1
- "nyc2"
- nyc2
- "nyc3"
- nyc3
- "sgp1"
- sgp1
- "lon1"
- lon1
- "ams2"
- ams2
- "ams3"
- ams3
- "fra1"
- fra1
- "tor1"
- tor1
- "sfo1"
- sfo1
- "sfo2"
- sfo2
- "sfo3"
- sfo3
- "blr1"
- blr1
Import
Volumes can be imported using the volume id
, e.g.
$ pulumi import digitalocean:index/volume:Volume volume 506f78a4-e098-11e5-ad9f-000f53306ae1
Package Details
- Repository
- DigitalOcean pulumi/pulumi-digitalocean
- License
- Apache-2.0
- Notes
This Pulumi package is based on the
digitalocean
Terraform Provider.