1. Packages
  2. Powerflex Provider
  3. API Docs
  4. Snapshot
powerflex 1.8.0 published on Monday, Apr 14, 2025 by dell

powerflex.Snapshot

Explore with Pulumi AI

powerflex logo
powerflex 1.8.0 published on Monday, Apr 14, 2025 by dell

    Import

    /*

    Copyright (c) 2023-2024 Dell Inc., or its subsidiaries. All Rights Reserved.

    Licensed under the Mozilla Public License Version 2.0 (the “License”);

    you may not use this file except in compliance with the License.

    You may obtain a copy of the License at

    http://mozilla.org/MPL/2.0/
    

    Unless required by applicable law or agreed to in writing, software

    distributed under the License is distributed on an “AS IS” BASIS,

    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.

    See the License for the specific language governing permissions and

    limitations under the License.

    */

    import Snapshot by it’s id

    $ pulumi import powerflex:index/snapshot:Snapshot ss_data "<id>"
    
    1. This will import the snapshot instance with specified ID into your Terraform state.

    2. After successful import, you can run terraform state list to ensure the resource has been imported successfully.

    3. Now, you can fill in the resource block with the appropriate arguments and settings that match the imported resource’s real-world configuration.

    4. Execute pulumi preview to see if your configuration and the imported resource are in sync. Make adjustments if needed.

    5. Finally, execute pulumi up to bring the resource fully under Terraform’s management.

    6. Now, the resource which was not part of terraform became part of Terraform managed infrastructure.

    Create Snapshot Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new Snapshot(name: string, args?: SnapshotArgs, opts?: CustomResourceOptions);
    @overload
    def Snapshot(resource_name: str,
                 args: Optional[SnapshotArgs] = None,
                 opts: Optional[ResourceOptions] = None)
    
    @overload
    def Snapshot(resource_name: str,
                 opts: Optional[ResourceOptions] = None,
                 access_mode: Optional[str] = None,
                 capacity_unit: Optional[str] = None,
                 desired_retention: Optional[float] = None,
                 lock_auto_snapshot: Optional[bool] = None,
                 name: Optional[str] = None,
                 remove_mode: Optional[str] = None,
                 retention_unit: Optional[str] = None,
                 size: Optional[float] = None,
                 volume_id: Optional[str] = None,
                 volume_name: Optional[str] = None)
    func NewSnapshot(ctx *Context, name string, args *SnapshotArgs, opts ...ResourceOption) (*Snapshot, error)
    public Snapshot(string name, SnapshotArgs? args = null, CustomResourceOptions? opts = null)
    public Snapshot(String name, SnapshotArgs args)
    public Snapshot(String name, SnapshotArgs args, CustomResourceOptions options)
    
    type: powerflex:Snapshot
    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 SnapshotArgs
    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 SnapshotArgs
    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 SnapshotArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args SnapshotArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args SnapshotArgs
    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 snapshotResource = new Powerflex.Snapshot("snapshotResource", new()
    {
        AccessMode = "string",
        CapacityUnit = "string",
        DesiredRetention = 0,
        LockAutoSnapshot = false,
        Name = "string",
        RemoveMode = "string",
        RetentionUnit = "string",
        Size = 0,
        VolumeId = "string",
        VolumeName = "string",
    });
    
    example, err := powerflex.NewSnapshot(ctx, "snapshotResource", &powerflex.SnapshotArgs{
    	AccessMode:       pulumi.String("string"),
    	CapacityUnit:     pulumi.String("string"),
    	DesiredRetention: pulumi.Float64(0),
    	LockAutoSnapshot: pulumi.Bool(false),
    	Name:             pulumi.String("string"),
    	RemoveMode:       pulumi.String("string"),
    	RetentionUnit:    pulumi.String("string"),
    	Size:             pulumi.Float64(0),
    	VolumeId:         pulumi.String("string"),
    	VolumeName:       pulumi.String("string"),
    })
    
    var snapshotResource = new Snapshot("snapshotResource", SnapshotArgs.builder()
        .accessMode("string")
        .capacityUnit("string")
        .desiredRetention(0)
        .lockAutoSnapshot(false)
        .name("string")
        .removeMode("string")
        .retentionUnit("string")
        .size(0)
        .volumeId("string")
        .volumeName("string")
        .build());
    
    snapshot_resource = powerflex.Snapshot("snapshotResource",
        access_mode="string",
        capacity_unit="string",
        desired_retention=0,
        lock_auto_snapshot=False,
        name="string",
        remove_mode="string",
        retention_unit="string",
        size=0,
        volume_id="string",
        volume_name="string")
    
    const snapshotResource = new powerflex.Snapshot("snapshotResource", {
        accessMode: "string",
        capacityUnit: "string",
        desiredRetention: 0,
        lockAutoSnapshot: false,
        name: "string",
        removeMode: "string",
        retentionUnit: "string",
        size: 0,
        volumeId: "string",
        volumeName: "string",
    });
    
    type: powerflex:Snapshot
    properties:
        accessMode: string
        capacityUnit: string
        desiredRetention: 0
        lockAutoSnapshot: false
        name: string
        removeMode: string
        retentionUnit: string
        size: 0
        volumeId: string
        volumeName: string
    

    Snapshot 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 Snapshot resource accepts the following input properties:

    AccessMode string
    The Access mode of snapshot. Valid values are ReadOnly and ReadWrite. Default value is ReadOnly.
    CapacityUnit string
    Unit of capacity of the volume. Must be one of GB and TB. Default value is GB.
    DesiredRetention double
    The minimum amount of time that the snapshot should be retained on the array starting at the time of apply. The unit is defined by retention_unit. Cannot be decreased.
    LockAutoSnapshot bool
    lock auto snapshot
    Name string
    The name of the snapshot.
    RemoveMode string
    Remove mode of the snapshot. Valid values are ONLY_ME and INCLUDING_DESCENDANTS. Default value is ONLY_ME.
    RetentionUnit string
    Retention unit of the snapshot. Valid values are hours and days. Default value is hours.
    Size double
    Size of the snapshot. The unit of size is defined by capacity_unit. The storage capacity of a snapshot must be a multiple of 8GB and cannot be decreased.
    VolumeId string
    The ID of the volume from which snapshot is to be created. Conflicts with volume_name. Cannot be updated.
    VolumeName string
    The volume name for which snapshot is created. Conflicts with volume_id. Cannot be updated.
    AccessMode string
    The Access mode of snapshot. Valid values are ReadOnly and ReadWrite. Default value is ReadOnly.
    CapacityUnit string
    Unit of capacity of the volume. Must be one of GB and TB. Default value is GB.
    DesiredRetention float64
    The minimum amount of time that the snapshot should be retained on the array starting at the time of apply. The unit is defined by retention_unit. Cannot be decreased.
    LockAutoSnapshot bool
    lock auto snapshot
    Name string
    The name of the snapshot.
    RemoveMode string
    Remove mode of the snapshot. Valid values are ONLY_ME and INCLUDING_DESCENDANTS. Default value is ONLY_ME.
    RetentionUnit string
    Retention unit of the snapshot. Valid values are hours and days. Default value is hours.
    Size float64
    Size of the snapshot. The unit of size is defined by capacity_unit. The storage capacity of a snapshot must be a multiple of 8GB and cannot be decreased.
    VolumeId string
    The ID of the volume from which snapshot is to be created. Conflicts with volume_name. Cannot be updated.
    VolumeName string
    The volume name for which snapshot is created. Conflicts with volume_id. Cannot be updated.
    accessMode String
    The Access mode of snapshot. Valid values are ReadOnly and ReadWrite. Default value is ReadOnly.
    capacityUnit String
    Unit of capacity of the volume. Must be one of GB and TB. Default value is GB.
    desiredRetention Double
    The minimum amount of time that the snapshot should be retained on the array starting at the time of apply. The unit is defined by retention_unit. Cannot be decreased.
    lockAutoSnapshot Boolean
    lock auto snapshot
    name String
    The name of the snapshot.
    removeMode String
    Remove mode of the snapshot. Valid values are ONLY_ME and INCLUDING_DESCENDANTS. Default value is ONLY_ME.
    retentionUnit String
    Retention unit of the snapshot. Valid values are hours and days. Default value is hours.
    size Double
    Size of the snapshot. The unit of size is defined by capacity_unit. The storage capacity of a snapshot must be a multiple of 8GB and cannot be decreased.
    volumeId String
    The ID of the volume from which snapshot is to be created. Conflicts with volume_name. Cannot be updated.
    volumeName String
    The volume name for which snapshot is created. Conflicts with volume_id. Cannot be updated.
    accessMode string
    The Access mode of snapshot. Valid values are ReadOnly and ReadWrite. Default value is ReadOnly.
    capacityUnit string
    Unit of capacity of the volume. Must be one of GB and TB. Default value is GB.
    desiredRetention number
    The minimum amount of time that the snapshot should be retained on the array starting at the time of apply. The unit is defined by retention_unit. Cannot be decreased.
    lockAutoSnapshot boolean
    lock auto snapshot
    name string
    The name of the snapshot.
    removeMode string
    Remove mode of the snapshot. Valid values are ONLY_ME and INCLUDING_DESCENDANTS. Default value is ONLY_ME.
    retentionUnit string
    Retention unit of the snapshot. Valid values are hours and days. Default value is hours.
    size number
    Size of the snapshot. The unit of size is defined by capacity_unit. The storage capacity of a snapshot must be a multiple of 8GB and cannot be decreased.
    volumeId string
    The ID of the volume from which snapshot is to be created. Conflicts with volume_name. Cannot be updated.
    volumeName string
    The volume name for which snapshot is created. Conflicts with volume_id. Cannot be updated.
    access_mode str
    The Access mode of snapshot. Valid values are ReadOnly and ReadWrite. Default value is ReadOnly.
    capacity_unit str
    Unit of capacity of the volume. Must be one of GB and TB. Default value is GB.
    desired_retention float
    The minimum amount of time that the snapshot should be retained on the array starting at the time of apply. The unit is defined by retention_unit. Cannot be decreased.
    lock_auto_snapshot bool
    lock auto snapshot
    name str
    The name of the snapshot.
    remove_mode str
    Remove mode of the snapshot. Valid values are ONLY_ME and INCLUDING_DESCENDANTS. Default value is ONLY_ME.
    retention_unit str
    Retention unit of the snapshot. Valid values are hours and days. Default value is hours.
    size float
    Size of the snapshot. The unit of size is defined by capacity_unit. The storage capacity of a snapshot must be a multiple of 8GB and cannot be decreased.
    volume_id str
    The ID of the volume from which snapshot is to be created. Conflicts with volume_name. Cannot be updated.
    volume_name str
    The volume name for which snapshot is created. Conflicts with volume_id. Cannot be updated.
    accessMode String
    The Access mode of snapshot. Valid values are ReadOnly and ReadWrite. Default value is ReadOnly.
    capacityUnit String
    Unit of capacity of the volume. Must be one of GB and TB. Default value is GB.
    desiredRetention Number
    The minimum amount of time that the snapshot should be retained on the array starting at the time of apply. The unit is defined by retention_unit. Cannot be decreased.
    lockAutoSnapshot Boolean
    lock auto snapshot
    name String
    The name of the snapshot.
    removeMode String
    Remove mode of the snapshot. Valid values are ONLY_ME and INCLUDING_DESCENDANTS. Default value is ONLY_ME.
    retentionUnit String
    Retention unit of the snapshot. Valid values are hours and days. Default value is hours.
    size Number
    Size of the snapshot. The unit of size is defined by capacity_unit. The storage capacity of a snapshot must be a multiple of 8GB and cannot be decreased.
    volumeId String
    The ID of the volume from which snapshot is to be created. Conflicts with volume_name. Cannot be updated.
    volumeName String
    The volume name for which snapshot is created. Conflicts with volume_id. Cannot be updated.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the Snapshot resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    RetentionInMin string
    retention of snapshot in min
    SizeInKb double
    Size in KB
    Id string
    The provider-assigned unique ID for this managed resource.
    RetentionInMin string
    retention of snapshot in min
    SizeInKb float64
    Size in KB
    id String
    The provider-assigned unique ID for this managed resource.
    retentionInMin String
    retention of snapshot in min
    sizeInKb Double
    Size in KB
    id string
    The provider-assigned unique ID for this managed resource.
    retentionInMin string
    retention of snapshot in min
    sizeInKb number
    Size in KB
    id str
    The provider-assigned unique ID for this managed resource.
    retention_in_min str
    retention of snapshot in min
    size_in_kb float
    Size in KB
    id String
    The provider-assigned unique ID for this managed resource.
    retentionInMin String
    retention of snapshot in min
    sizeInKb Number
    Size in KB

    Look up Existing Snapshot Resource

    Get an existing Snapshot 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?: SnapshotState, opts?: CustomResourceOptions): Snapshot
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            access_mode: Optional[str] = None,
            capacity_unit: Optional[str] = None,
            desired_retention: Optional[float] = None,
            lock_auto_snapshot: Optional[bool] = None,
            name: Optional[str] = None,
            remove_mode: Optional[str] = None,
            retention_in_min: Optional[str] = None,
            retention_unit: Optional[str] = None,
            size: Optional[float] = None,
            size_in_kb: Optional[float] = None,
            volume_id: Optional[str] = None,
            volume_name: Optional[str] = None) -> Snapshot
    func GetSnapshot(ctx *Context, name string, id IDInput, state *SnapshotState, opts ...ResourceOption) (*Snapshot, error)
    public static Snapshot Get(string name, Input<string> id, SnapshotState? state, CustomResourceOptions? opts = null)
    public static Snapshot get(String name, Output<String> id, SnapshotState state, CustomResourceOptions options)
    resources:  _:    type: powerflex:Snapshot    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.
    The following state arguments are supported:
    AccessMode string
    The Access mode of snapshot. Valid values are ReadOnly and ReadWrite. Default value is ReadOnly.
    CapacityUnit string
    Unit of capacity of the volume. Must be one of GB and TB. Default value is GB.
    DesiredRetention double
    The minimum amount of time that the snapshot should be retained on the array starting at the time of apply. The unit is defined by retention_unit. Cannot be decreased.
    LockAutoSnapshot bool
    lock auto snapshot
    Name string
    The name of the snapshot.
    RemoveMode string
    Remove mode of the snapshot. Valid values are ONLY_ME and INCLUDING_DESCENDANTS. Default value is ONLY_ME.
    RetentionInMin string
    retention of snapshot in min
    RetentionUnit string
    Retention unit of the snapshot. Valid values are hours and days. Default value is hours.
    Size double
    Size of the snapshot. The unit of size is defined by capacity_unit. The storage capacity of a snapshot must be a multiple of 8GB and cannot be decreased.
    SizeInKb double
    Size in KB
    VolumeId string
    The ID of the volume from which snapshot is to be created. Conflicts with volume_name. Cannot be updated.
    VolumeName string
    The volume name for which snapshot is created. Conflicts with volume_id. Cannot be updated.
    AccessMode string
    The Access mode of snapshot. Valid values are ReadOnly and ReadWrite. Default value is ReadOnly.
    CapacityUnit string
    Unit of capacity of the volume. Must be one of GB and TB. Default value is GB.
    DesiredRetention float64
    The minimum amount of time that the snapshot should be retained on the array starting at the time of apply. The unit is defined by retention_unit. Cannot be decreased.
    LockAutoSnapshot bool
    lock auto snapshot
    Name string
    The name of the snapshot.
    RemoveMode string
    Remove mode of the snapshot. Valid values are ONLY_ME and INCLUDING_DESCENDANTS. Default value is ONLY_ME.
    RetentionInMin string
    retention of snapshot in min
    RetentionUnit string
    Retention unit of the snapshot. Valid values are hours and days. Default value is hours.
    Size float64
    Size of the snapshot. The unit of size is defined by capacity_unit. The storage capacity of a snapshot must be a multiple of 8GB and cannot be decreased.
    SizeInKb float64
    Size in KB
    VolumeId string
    The ID of the volume from which snapshot is to be created. Conflicts with volume_name. Cannot be updated.
    VolumeName string
    The volume name for which snapshot is created. Conflicts with volume_id. Cannot be updated.
    accessMode String
    The Access mode of snapshot. Valid values are ReadOnly and ReadWrite. Default value is ReadOnly.
    capacityUnit String
    Unit of capacity of the volume. Must be one of GB and TB. Default value is GB.
    desiredRetention Double
    The minimum amount of time that the snapshot should be retained on the array starting at the time of apply. The unit is defined by retention_unit. Cannot be decreased.
    lockAutoSnapshot Boolean
    lock auto snapshot
    name String
    The name of the snapshot.
    removeMode String
    Remove mode of the snapshot. Valid values are ONLY_ME and INCLUDING_DESCENDANTS. Default value is ONLY_ME.
    retentionInMin String
    retention of snapshot in min
    retentionUnit String
    Retention unit of the snapshot. Valid values are hours and days. Default value is hours.
    size Double
    Size of the snapshot. The unit of size is defined by capacity_unit. The storage capacity of a snapshot must be a multiple of 8GB and cannot be decreased.
    sizeInKb Double
    Size in KB
    volumeId String
    The ID of the volume from which snapshot is to be created. Conflicts with volume_name. Cannot be updated.
    volumeName String
    The volume name for which snapshot is created. Conflicts with volume_id. Cannot be updated.
    accessMode string
    The Access mode of snapshot. Valid values are ReadOnly and ReadWrite. Default value is ReadOnly.
    capacityUnit string
    Unit of capacity of the volume. Must be one of GB and TB. Default value is GB.
    desiredRetention number
    The minimum amount of time that the snapshot should be retained on the array starting at the time of apply. The unit is defined by retention_unit. Cannot be decreased.
    lockAutoSnapshot boolean
    lock auto snapshot
    name string
    The name of the snapshot.
    removeMode string
    Remove mode of the snapshot. Valid values are ONLY_ME and INCLUDING_DESCENDANTS. Default value is ONLY_ME.
    retentionInMin string
    retention of snapshot in min
    retentionUnit string
    Retention unit of the snapshot. Valid values are hours and days. Default value is hours.
    size number
    Size of the snapshot. The unit of size is defined by capacity_unit. The storage capacity of a snapshot must be a multiple of 8GB and cannot be decreased.
    sizeInKb number
    Size in KB
    volumeId string
    The ID of the volume from which snapshot is to be created. Conflicts with volume_name. Cannot be updated.
    volumeName string
    The volume name for which snapshot is created. Conflicts with volume_id. Cannot be updated.
    access_mode str
    The Access mode of snapshot. Valid values are ReadOnly and ReadWrite. Default value is ReadOnly.
    capacity_unit str
    Unit of capacity of the volume. Must be one of GB and TB. Default value is GB.
    desired_retention float
    The minimum amount of time that the snapshot should be retained on the array starting at the time of apply. The unit is defined by retention_unit. Cannot be decreased.
    lock_auto_snapshot bool
    lock auto snapshot
    name str
    The name of the snapshot.
    remove_mode str
    Remove mode of the snapshot. Valid values are ONLY_ME and INCLUDING_DESCENDANTS. Default value is ONLY_ME.
    retention_in_min str
    retention of snapshot in min
    retention_unit str
    Retention unit of the snapshot. Valid values are hours and days. Default value is hours.
    size float
    Size of the snapshot. The unit of size is defined by capacity_unit. The storage capacity of a snapshot must be a multiple of 8GB and cannot be decreased.
    size_in_kb float
    Size in KB
    volume_id str
    The ID of the volume from which snapshot is to be created. Conflicts with volume_name. Cannot be updated.
    volume_name str
    The volume name for which snapshot is created. Conflicts with volume_id. Cannot be updated.
    accessMode String
    The Access mode of snapshot. Valid values are ReadOnly and ReadWrite. Default value is ReadOnly.
    capacityUnit String
    Unit of capacity of the volume. Must be one of GB and TB. Default value is GB.
    desiredRetention Number
    The minimum amount of time that the snapshot should be retained on the array starting at the time of apply. The unit is defined by retention_unit. Cannot be decreased.
    lockAutoSnapshot Boolean
    lock auto snapshot
    name String
    The name of the snapshot.
    removeMode String
    Remove mode of the snapshot. Valid values are ONLY_ME and INCLUDING_DESCENDANTS. Default value is ONLY_ME.
    retentionInMin String
    retention of snapshot in min
    retentionUnit String
    Retention unit of the snapshot. Valid values are hours and days. Default value is hours.
    size Number
    Size of the snapshot. The unit of size is defined by capacity_unit. The storage capacity of a snapshot must be a multiple of 8GB and cannot be decreased.
    sizeInKb Number
    Size in KB
    volumeId String
    The ID of the volume from which snapshot is to be created. Conflicts with volume_name. Cannot be updated.
    volumeName String
    The volume name for which snapshot is created. Conflicts with volume_id. Cannot be updated.

    Package Details

    Repository
    powerflex dell/terraform-provider-powerflex
    License
    Notes
    This Pulumi package is based on the powerflex Terraform Provider.
    powerflex logo
    powerflex 1.8.0 published on Monday, Apr 14, 2025 by dell