Class DropletSnapshot
Provides a resource which can be used to create a snapshot from an existing DigitalOcean Droplet.
Example Usage
using Pulumi;
using DigitalOcean = Pulumi.DigitalOcean;
class MyStack : Stack
{
public MyStack()
{
var web = new DigitalOcean.Droplet("web", new DigitalOcean.DropletArgs
{
Size = "s-1vcpu-1gb",
Image = "centos-7-x64",
Region = "nyc3",
});
var web_snapshot = new DigitalOcean.DropletSnapshot("web-snapshot", new DigitalOcean.DropletSnapshotArgs
{
DropletId = web.Id,
});
}
}
Inherited Members
Namespace: Pulumi.DigitalOcean
Assembly: Pulumi.DigitalOcean.dll
Syntax
public class DropletSnapshot : CustomResource
Constructors
View SourceDropletSnapshot(String, DropletSnapshotArgs, CustomResourceOptions)
Create a DropletSnapshot resource with the given unique name, arguments, and options.
Declaration
public DropletSnapshot(string name, DropletSnapshotArgs args, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resource |
| DropletSnapshotArgs | args | The arguments used to populate this resource's properties |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Properties
View SourceCreatedAt
The date and time the Droplet snapshot was created.
Declaration
public Output<string> CreatedAt { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
DropletId
The ID of the Droplet from which the snapshot will be taken.
Declaration
public Output<string> DropletId { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
MinDiskSize
The minimum size in gigabytes required for a Droplet to be created based on this snapshot.
Declaration
public Output<int> MinDiskSize { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Int32> |
Name
A name for the Droplet snapshot.
Declaration
public Output<string> Name { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Regions
A list of DigitalOcean region "slugs" indicating where the droplet snapshot is available.
Declaration
public Output<ImmutableArray<string>> Regions { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Collections.Immutable.ImmutableArray<System.String>> |
Size
The billable size of the Droplet snapshot in gigabytes.
Declaration
public Output<double> Size { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Double> |
Methods
View SourceGet(String, Input<String>, DropletSnapshotState, CustomResourceOptions)
Get an existing DropletSnapshot resource's state with the given name, ID, and optional extra properties used to qualify the lookup.
Declaration
public static DropletSnapshot Get(string name, Input<string> id, DropletSnapshotState state = null, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resulting resource. |
| Input<System.String> | id | The unique provider ID of the resource to lookup. |
| DropletSnapshotState | state | Any extra arguments used during the lookup. |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Returns
| Type | Description |
|---|---|
| DropletSnapshot |