Class SnapshotCopy
Creates a Snapshot of a snapshot.
Example Usage
using Pulumi;
using Aws = Pulumi.Aws;
class MyStack : Stack
{
public MyStack()
{
var example = new Aws.Ebs.Volume("example", new Aws.Ebs.VolumeArgs
{
AvailabilityZone = "us-west-2a",
Size = 40,
Tags =
{
{ "Name", "HelloWorld" },
},
});
var exampleSnapshot = new Aws.Ebs.Snapshot("exampleSnapshot", new Aws.Ebs.SnapshotArgs
{
Tags =
{
{ "Name", "HelloWorld_snap" },
},
VolumeId = example.Id,
});
var exampleCopy = new Aws.Ebs.SnapshotCopy("exampleCopy", new Aws.Ebs.SnapshotCopyArgs
{
SourceRegion = "us-west-2",
SourceSnapshotId = exampleSnapshot.Id,
Tags =
{
{ "Name", "HelloWorld_copy_snap" },
},
});
}
}
Inherited Members
Namespace: Pulumi.Aws.Ebs
Assembly: Pulumi.Aws.dll
Syntax
public class SnapshotCopy : CustomResource
Constructors
View SourceSnapshotCopy(String, SnapshotCopyArgs, CustomResourceOptions)
Create a SnapshotCopy resource with the given unique name, arguments, and options.
Declaration
public SnapshotCopy(string name, SnapshotCopyArgs args, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resource |
| SnapshotCopyArgs | args | The arguments used to populate this resource's properties |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Properties
View SourceDataEncryptionKeyId
The data encryption key identifier for the snapshot.
source_snapshot_idThe ARN of the copied snapshot.source_regionThe region of the source snapshot.
Declaration
public Output<string> DataEncryptionKeyId { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Description
A description of what the snapshot is.
Declaration
public Output<string> Description { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Encrypted
Whether the snapshot is encrypted.
Declaration
public Output<bool?> Encrypted { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Nullable<System.Boolean>> |
KmsKeyId
The ARN for the KMS encryption key.
Declaration
public Output<string> KmsKeyId { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
OwnerAlias
Value from an Amazon-maintained list (amazon, aws-marketplace, microsoft) of snapshot owners.
Declaration
public Output<string> OwnerAlias { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
OwnerId
The AWS account ID of the snapshot owner.
Declaration
public Output<string> OwnerId { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
SourceRegion
The region of the source snapshot.
Declaration
public Output<string> SourceRegion { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
SourceSnapshotId
The ARN for the snapshot to be copied.
Declaration
public Output<string> SourceSnapshotId { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Tags
A map of tags for the snapshot.
Declaration
public Output<ImmutableDictionary<string, object>> Tags { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Collections.Immutable.ImmutableDictionary<System.String, System.Object>> |
VolumeId
Declaration
public Output<string> VolumeId { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
VolumeSize
The size of the drive in GiBs.
Declaration
public Output<int> VolumeSize { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Int32> |
Methods
View SourceGet(String, Input<String>, SnapshotCopyState, CustomResourceOptions)
Get an existing SnapshotCopy resource's state with the given name, ID, and optional extra properties used to qualify the lookup.
Declaration
public static SnapshotCopy Get(string name, Input<string> id, SnapshotCopyState 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. |
| SnapshotCopyState | state | Any extra arguments used during the lookup. |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Returns
| Type | Description |
|---|---|
| SnapshotCopy |