1. Packages
  2. Ionoscloud Provider
  3. API Docs
  4. Snapshot
ionoscloud 6.7.6 published on Monday, Apr 14, 2025 by ionos-cloud

ionoscloud.Snapshot

Explore with Pulumi AI

ionoscloud logo
ionoscloud 6.7.6 published on Monday, Apr 14, 2025 by ionos-cloud

    Manages Snapshots on IonosCloud.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as ionoscloud from "@pulumi/ionoscloud";
    import * as random from "@pulumi/random";
    
    const exampleImage = ionoscloud.getImage({
        type: "HDD",
        imageAlias: "ubuntu:latest",
        location: "us/las",
    });
    const exampleDatacenter = new ionoscloud.Datacenter("exampleDatacenter", {
        location: "us/las",
        description: "Datacenter Description",
        secAuthProtection: false,
    });
    const exampleLan = new ionoscloud.Lan("exampleLan", {
        datacenterId: exampleDatacenter.datacenterId,
        "public": true,
    });
    const serverImagePassword = new random.index.Random_password("serverImagePassword", {
        length: 16,
        special: false,
    });
    const exampleServer = new ionoscloud.Server("exampleServer", {
        datacenterId: exampleDatacenter.datacenterId,
        cores: 1,
        ram: 1024,
        imageName: exampleImage.then(exampleImage => exampleImage.id),
        imagePassword: serverImagePassword.result,
        type: "ENTERPRISE",
        volume: {
            name: "system",
            size: 5,
            diskType: "SSD Standard",
            userData: "foo",
            bus: "VIRTIO",
            availabilityZone: "ZONE_1",
        },
    });
    const testSnapshot = new ionoscloud.Snapshot("testSnapshot", {
        datacenterId: exampleDatacenter.datacenterId,
        volumeId: exampleServer.bootVolume,
    });
    
    import pulumi
    import pulumi_ionoscloud as ionoscloud
    import pulumi_random as random
    
    example_image = ionoscloud.get_image(type="HDD",
        image_alias="ubuntu:latest",
        location="us/las")
    example_datacenter = ionoscloud.Datacenter("exampleDatacenter",
        location="us/las",
        description="Datacenter Description",
        sec_auth_protection=False)
    example_lan = ionoscloud.Lan("exampleLan",
        datacenter_id=example_datacenter.datacenter_id,
        public=True)
    server_image_password = random.index.Random_password("serverImagePassword",
        length=16,
        special=False)
    example_server = ionoscloud.Server("exampleServer",
        datacenter_id=example_datacenter.datacenter_id,
        cores=1,
        ram=1024,
        image_name=example_image.id,
        image_password=server_image_password["result"],
        type="ENTERPRISE",
        volume={
            "name": "system",
            "size": 5,
            "disk_type": "SSD Standard",
            "user_data": "foo",
            "bus": "VIRTIO",
            "availability_zone": "ZONE_1",
        })
    test_snapshot = ionoscloud.Snapshot("testSnapshot",
        datacenter_id=example_datacenter.datacenter_id,
        volume_id=example_server.boot_volume)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-random/sdk/go/random"
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/ionoscloud/v6/ionoscloud"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		exampleImage, err := ionoscloud.GetImage(ctx, &ionoscloud.GetImageArgs{
    			Type:       pulumi.StringRef("HDD"),
    			ImageAlias: pulumi.StringRef("ubuntu:latest"),
    			Location:   pulumi.StringRef("us/las"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		exampleDatacenter, err := ionoscloud.NewDatacenter(ctx, "exampleDatacenter", &ionoscloud.DatacenterArgs{
    			Location:          pulumi.String("us/las"),
    			Description:       pulumi.String("Datacenter Description"),
    			SecAuthProtection: pulumi.Bool(false),
    		})
    		if err != nil {
    			return err
    		}
    		_, err = ionoscloud.NewLan(ctx, "exampleLan", &ionoscloud.LanArgs{
    			DatacenterId: exampleDatacenter.DatacenterId,
    			Public:       pulumi.Bool(true),
    		})
    		if err != nil {
    			return err
    		}
    		serverImagePassword, err := random.NewRandom_password(ctx, "serverImagePassword", &random.Random_passwordArgs{
    			Length:  16,
    			Special: false,
    		})
    		if err != nil {
    			return err
    		}
    		exampleServer, err := ionoscloud.NewServer(ctx, "exampleServer", &ionoscloud.ServerArgs{
    			DatacenterId:  exampleDatacenter.DatacenterId,
    			Cores:         pulumi.Float64(1),
    			Ram:           pulumi.Float64(1024),
    			ImageName:     pulumi.String(exampleImage.Id),
    			ImagePassword: serverImagePassword.Result,
    			Type:          pulumi.String("ENTERPRISE"),
    			Volume: &ionoscloud.ServerVolumeArgs{
    				Name:             pulumi.String("system"),
    				Size:             pulumi.Float64(5),
    				DiskType:         pulumi.String("SSD Standard"),
    				UserData:         pulumi.String("foo"),
    				Bus:              pulumi.String("VIRTIO"),
    				AvailabilityZone: pulumi.String("ZONE_1"),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		_, err = ionoscloud.NewSnapshot(ctx, "testSnapshot", &ionoscloud.SnapshotArgs{
    			DatacenterId: exampleDatacenter.DatacenterId,
    			VolumeId:     exampleServer.BootVolume,
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Ionoscloud = Pulumi.Ionoscloud;
    using Random = Pulumi.Random;
    
    return await Deployment.RunAsync(() => 
    {
        var exampleImage = Ionoscloud.GetImage.Invoke(new()
        {
            Type = "HDD",
            ImageAlias = "ubuntu:latest",
            Location = "us/las",
        });
    
        var exampleDatacenter = new Ionoscloud.Datacenter("exampleDatacenter", new()
        {
            Location = "us/las",
            Description = "Datacenter Description",
            SecAuthProtection = false,
        });
    
        var exampleLan = new Ionoscloud.Lan("exampleLan", new()
        {
            DatacenterId = exampleDatacenter.DatacenterId,
            Public = true,
        });
    
        var serverImagePassword = new Random.Index.Random_password("serverImagePassword", new()
        {
            Length = 16,
            Special = false,
        });
    
        var exampleServer = new Ionoscloud.Server("exampleServer", new()
        {
            DatacenterId = exampleDatacenter.DatacenterId,
            Cores = 1,
            Ram = 1024,
            ImageName = exampleImage.Apply(getImageResult => getImageResult.Id),
            ImagePassword = serverImagePassword.Result,
            Type = "ENTERPRISE",
            Volume = new Ionoscloud.Inputs.ServerVolumeArgs
            {
                Name = "system",
                Size = 5,
                DiskType = "SSD Standard",
                UserData = "foo",
                Bus = "VIRTIO",
                AvailabilityZone = "ZONE_1",
            },
        });
    
        var testSnapshot = new Ionoscloud.Snapshot("testSnapshot", new()
        {
            DatacenterId = exampleDatacenter.DatacenterId,
            VolumeId = exampleServer.BootVolume,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.ionoscloud.IonoscloudFunctions;
    import com.pulumi.ionoscloud.inputs.GetImageArgs;
    import com.pulumi.ionoscloud.Datacenter;
    import com.pulumi.ionoscloud.DatacenterArgs;
    import com.pulumi.ionoscloud.Lan;
    import com.pulumi.ionoscloud.LanArgs;
    import com.pulumi.random.random_password;
    import com.pulumi.random.Random_passwordArgs;
    import com.pulumi.ionoscloud.Server;
    import com.pulumi.ionoscloud.ServerArgs;
    import com.pulumi.ionoscloud.inputs.ServerVolumeArgs;
    import com.pulumi.ionoscloud.Snapshot;
    import com.pulumi.ionoscloud.SnapshotArgs;
    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 exampleImage = IonoscloudFunctions.getImage(GetImageArgs.builder()
                .type("HDD")
                .imageAlias("ubuntu:latest")
                .location("us/las")
                .build());
    
            var exampleDatacenter = new Datacenter("exampleDatacenter", DatacenterArgs.builder()
                .location("us/las")
                .description("Datacenter Description")
                .secAuthProtection(false)
                .build());
    
            var exampleLan = new Lan("exampleLan", LanArgs.builder()
                .datacenterId(exampleDatacenter.datacenterId())
                .public_(true)
                .build());
    
            var serverImagePassword = new Random_password("serverImagePassword", Random_passwordArgs.builder()
                .length(16)
                .special(false)
                .build());
    
            var exampleServer = new Server("exampleServer", ServerArgs.builder()
                .datacenterId(exampleDatacenter.datacenterId())
                .cores(1)
                .ram(1024)
                .imageName(exampleImage.applyValue(getImageResult -> getImageResult.id()))
                .imagePassword(serverImagePassword.result())
                .type("ENTERPRISE")
                .volume(ServerVolumeArgs.builder()
                    .name("system")
                    .size(5)
                    .diskType("SSD Standard")
                    .userData("foo")
                    .bus("VIRTIO")
                    .availabilityZone("ZONE_1")
                    .build())
                .build());
    
            var testSnapshot = new Snapshot("testSnapshot", SnapshotArgs.builder()
                .datacenterId(exampleDatacenter.datacenterId())
                .volumeId(exampleServer.bootVolume())
                .build());
    
        }
    }
    
    resources:
      exampleDatacenter:
        type: ionoscloud:Datacenter
        properties:
          location: us/las
          description: Datacenter Description
          secAuthProtection: false
      exampleLan:
        type: ionoscloud:Lan
        properties:
          datacenterId: ${exampleDatacenter.datacenterId}
          public: true
      exampleServer:
        type: ionoscloud:Server
        properties:
          datacenterId: ${exampleDatacenter.datacenterId}
          cores: 1
          ram: 1024
          imageName: ${exampleImage.id}
          imagePassword: ${serverImagePassword.result}
          type: ENTERPRISE
          volume:
            name: system
            size: 5
            diskType: SSD Standard
            userData: foo
            bus: VIRTIO
            availabilityZone: ZONE_1
      testSnapshot:
        type: ionoscloud:Snapshot
        properties:
          datacenterId: ${exampleDatacenter.datacenterId}
          volumeId: ${exampleServer.bootVolume}
      serverImagePassword:
        type: random:random_password
        properties:
          length: 16
          special: false
    variables:
      exampleImage:
        fn::invoke:
          function: ionoscloud:getImage
          arguments:
            type: HDD
            imageAlias: ubuntu:latest
            location: us/las
    

    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: SnapshotArgs,
                 opts: Optional[ResourceOptions] = None)
    
    @overload
    def Snapshot(resource_name: str,
                 opts: Optional[ResourceOptions] = None,
                 volume_id: Optional[str] = None,
                 datacenter_id: Optional[str] = None,
                 name: Optional[str] = None,
                 disc_virtio_hot_plug: Optional[bool] = None,
                 disc_virtio_hot_unplug: Optional[bool] = None,
                 licence_type: Optional[str] = None,
                 cpu_hot_plug: Optional[bool] = None,
                 nic_hot_plug: Optional[bool] = None,
                 nic_hot_unplug: Optional[bool] = None,
                 ram_hot_plug: Optional[bool] = None,
                 sec_auth_protection: Optional[bool] = None,
                 snapshot_id: Optional[str] = None,
                 timeouts: Optional[SnapshotTimeoutsArgs] = None,
                 description: Optional[str] = None)
    func NewSnapshot(ctx *Context, name string, args SnapshotArgs, opts ...ResourceOption) (*Snapshot, error)
    public Snapshot(string name, SnapshotArgs args, CustomResourceOptions? opts = null)
    public Snapshot(String name, SnapshotArgs args)
    public Snapshot(String name, SnapshotArgs args, CustomResourceOptions options)
    
    type: ionoscloud: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 Ionoscloud.Snapshot("snapshotResource", new()
    {
        VolumeId = "string",
        DatacenterId = "string",
        Name = "string",
        DiscVirtioHotPlug = false,
        DiscVirtioHotUnplug = false,
        LicenceType = "string",
        CpuHotPlug = false,
        NicHotPlug = false,
        NicHotUnplug = false,
        RamHotPlug = false,
        SecAuthProtection = false,
        SnapshotId = "string",
        Timeouts = new Ionoscloud.Inputs.SnapshotTimeoutsArgs
        {
            Create = "string",
            Default = "string",
            Delete = "string",
            Update = "string",
        },
        Description = "string",
    });
    
    example, err := ionoscloud.NewSnapshot(ctx, "snapshotResource", &ionoscloud.SnapshotArgs{
    	VolumeId:            pulumi.String("string"),
    	DatacenterId:        pulumi.String("string"),
    	Name:                pulumi.String("string"),
    	DiscVirtioHotPlug:   pulumi.Bool(false),
    	DiscVirtioHotUnplug: pulumi.Bool(false),
    	LicenceType:         pulumi.String("string"),
    	CpuHotPlug:          pulumi.Bool(false),
    	NicHotPlug:          pulumi.Bool(false),
    	NicHotUnplug:        pulumi.Bool(false),
    	RamHotPlug:          pulumi.Bool(false),
    	SecAuthProtection:   pulumi.Bool(false),
    	SnapshotId:          pulumi.String("string"),
    	Timeouts: &ionoscloud.SnapshotTimeoutsArgs{
    		Create:  pulumi.String("string"),
    		Default: pulumi.String("string"),
    		Delete:  pulumi.String("string"),
    		Update:  pulumi.String("string"),
    	},
    	Description: pulumi.String("string"),
    })
    
    var snapshotResource = new Snapshot("snapshotResource", SnapshotArgs.builder()
        .volumeId("string")
        .datacenterId("string")
        .name("string")
        .discVirtioHotPlug(false)
        .discVirtioHotUnplug(false)
        .licenceType("string")
        .cpuHotPlug(false)
        .nicHotPlug(false)
        .nicHotUnplug(false)
        .ramHotPlug(false)
        .secAuthProtection(false)
        .snapshotId("string")
        .timeouts(SnapshotTimeoutsArgs.builder()
            .create("string")
            .default_("string")
            .delete("string")
            .update("string")
            .build())
        .description("string")
        .build());
    
    snapshot_resource = ionoscloud.Snapshot("snapshotResource",
        volume_id="string",
        datacenter_id="string",
        name="string",
        disc_virtio_hot_plug=False,
        disc_virtio_hot_unplug=False,
        licence_type="string",
        cpu_hot_plug=False,
        nic_hot_plug=False,
        nic_hot_unplug=False,
        ram_hot_plug=False,
        sec_auth_protection=False,
        snapshot_id="string",
        timeouts={
            "create": "string",
            "default": "string",
            "delete": "string",
            "update": "string",
        },
        description="string")
    
    const snapshotResource = new ionoscloud.Snapshot("snapshotResource", {
        volumeId: "string",
        datacenterId: "string",
        name: "string",
        discVirtioHotPlug: false,
        discVirtioHotUnplug: false,
        licenceType: "string",
        cpuHotPlug: false,
        nicHotPlug: false,
        nicHotUnplug: false,
        ramHotPlug: false,
        secAuthProtection: false,
        snapshotId: "string",
        timeouts: {
            create: "string",
            "default": "string",
            "delete": "string",
            update: "string",
        },
        description: "string",
    });
    
    type: ionoscloud:Snapshot
    properties:
        cpuHotPlug: false
        datacenterId: string
        description: string
        discVirtioHotPlug: false
        discVirtioHotUnplug: false
        licenceType: string
        name: string
        nicHotPlug: false
        nicHotUnplug: false
        ramHotPlug: false
        secAuthProtection: false
        snapshotId: string
        timeouts:
            create: string
            default: string
            delete: string
            update: string
        volumeId: 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:

    DatacenterId string
    [string] The ID of the Virtual Data Center.
    VolumeId string
    [string] The ID of the specific volume to take the snapshot from.
    CpuHotPlug bool
    (Computed)[string] Is capable of CPU hot plug (no reboot required). Can only be updated.
    Description string
    (Computed)[string] Human readable description
    DiscVirtioHotPlug bool
    (Computed)[string] Is capable of Virt-IO drive hot plug (no reboot required). Can only be updated.
    DiscVirtioHotUnplug bool
    (Computed)[string] Is capable of Virt-IO drive hot unplug (no reboot required). This works only for non-Windows virtual Machines. Can only be updated.
    LicenceType string
    (Computed)[string] OS type of this Snapshot
    Name string
    [string] The name of the snapshot.
    NicHotPlug bool
    (Computed)[string] Is capable of nic hot plug (no reboot required). Can only be updated.
    NicHotUnplug bool
    (Computed)[string] Is capable of nic hot unplug (no reboot required). Can only be updated.
    RamHotPlug bool
    (Computed)[string] Is capable of memory hot plug (no reboot required). Can only be updated.
    SecAuthProtection bool
    Boolean value representing if the snapshot requires extra protection e.g. two factor protection
    SnapshotId string
    Timeouts SnapshotTimeouts
    DatacenterId string
    [string] The ID of the Virtual Data Center.
    VolumeId string
    [string] The ID of the specific volume to take the snapshot from.
    CpuHotPlug bool
    (Computed)[string] Is capable of CPU hot plug (no reboot required). Can only be updated.
    Description string
    (Computed)[string] Human readable description
    DiscVirtioHotPlug bool
    (Computed)[string] Is capable of Virt-IO drive hot plug (no reboot required). Can only be updated.
    DiscVirtioHotUnplug bool
    (Computed)[string] Is capable of Virt-IO drive hot unplug (no reboot required). This works only for non-Windows virtual Machines. Can only be updated.
    LicenceType string
    (Computed)[string] OS type of this Snapshot
    Name string
    [string] The name of the snapshot.
    NicHotPlug bool
    (Computed)[string] Is capable of nic hot plug (no reboot required). Can only be updated.
    NicHotUnplug bool
    (Computed)[string] Is capable of nic hot unplug (no reboot required). Can only be updated.
    RamHotPlug bool
    (Computed)[string] Is capable of memory hot plug (no reboot required). Can only be updated.
    SecAuthProtection bool
    Boolean value representing if the snapshot requires extra protection e.g. two factor protection
    SnapshotId string
    Timeouts SnapshotTimeoutsArgs
    datacenterId String
    [string] The ID of the Virtual Data Center.
    volumeId String
    [string] The ID of the specific volume to take the snapshot from.
    cpuHotPlug Boolean
    (Computed)[string] Is capable of CPU hot plug (no reboot required). Can only be updated.
    description String
    (Computed)[string] Human readable description
    discVirtioHotPlug Boolean
    (Computed)[string] Is capable of Virt-IO drive hot plug (no reboot required). Can only be updated.
    discVirtioHotUnplug Boolean
    (Computed)[string] Is capable of Virt-IO drive hot unplug (no reboot required). This works only for non-Windows virtual Machines. Can only be updated.
    licenceType String
    (Computed)[string] OS type of this Snapshot
    name String
    [string] The name of the snapshot.
    nicHotPlug Boolean
    (Computed)[string] Is capable of nic hot plug (no reboot required). Can only be updated.
    nicHotUnplug Boolean
    (Computed)[string] Is capable of nic hot unplug (no reboot required). Can only be updated.
    ramHotPlug Boolean
    (Computed)[string] Is capable of memory hot plug (no reboot required). Can only be updated.
    secAuthProtection Boolean
    Boolean value representing if the snapshot requires extra protection e.g. two factor protection
    snapshotId String
    timeouts SnapshotTimeouts
    datacenterId string
    [string] The ID of the Virtual Data Center.
    volumeId string
    [string] The ID of the specific volume to take the snapshot from.
    cpuHotPlug boolean
    (Computed)[string] Is capable of CPU hot plug (no reboot required). Can only be updated.
    description string
    (Computed)[string] Human readable description
    discVirtioHotPlug boolean
    (Computed)[string] Is capable of Virt-IO drive hot plug (no reboot required). Can only be updated.
    discVirtioHotUnplug boolean
    (Computed)[string] Is capable of Virt-IO drive hot unplug (no reboot required). This works only for non-Windows virtual Machines. Can only be updated.
    licenceType string
    (Computed)[string] OS type of this Snapshot
    name string
    [string] The name of the snapshot.
    nicHotPlug boolean
    (Computed)[string] Is capable of nic hot plug (no reboot required). Can only be updated.
    nicHotUnplug boolean
    (Computed)[string] Is capable of nic hot unplug (no reboot required). Can only be updated.
    ramHotPlug boolean
    (Computed)[string] Is capable of memory hot plug (no reboot required). Can only be updated.
    secAuthProtection boolean
    Boolean value representing if the snapshot requires extra protection e.g. two factor protection
    snapshotId string
    timeouts SnapshotTimeouts
    datacenter_id str
    [string] The ID of the Virtual Data Center.
    volume_id str
    [string] The ID of the specific volume to take the snapshot from.
    cpu_hot_plug bool
    (Computed)[string] Is capable of CPU hot plug (no reboot required). Can only be updated.
    description str
    (Computed)[string] Human readable description
    disc_virtio_hot_plug bool
    (Computed)[string] Is capable of Virt-IO drive hot plug (no reboot required). Can only be updated.
    disc_virtio_hot_unplug bool
    (Computed)[string] Is capable of Virt-IO drive hot unplug (no reboot required). This works only for non-Windows virtual Machines. Can only be updated.
    licence_type str
    (Computed)[string] OS type of this Snapshot
    name str
    [string] The name of the snapshot.
    nic_hot_plug bool
    (Computed)[string] Is capable of nic hot plug (no reboot required). Can only be updated.
    nic_hot_unplug bool
    (Computed)[string] Is capable of nic hot unplug (no reboot required). Can only be updated.
    ram_hot_plug bool
    (Computed)[string] Is capable of memory hot plug (no reboot required). Can only be updated.
    sec_auth_protection bool
    Boolean value representing if the snapshot requires extra protection e.g. two factor protection
    snapshot_id str
    timeouts SnapshotTimeoutsArgs
    datacenterId String
    [string] The ID of the Virtual Data Center.
    volumeId String
    [string] The ID of the specific volume to take the snapshot from.
    cpuHotPlug Boolean
    (Computed)[string] Is capable of CPU hot plug (no reboot required). Can only be updated.
    description String
    (Computed)[string] Human readable description
    discVirtioHotPlug Boolean
    (Computed)[string] Is capable of Virt-IO drive hot plug (no reboot required). Can only be updated.
    discVirtioHotUnplug Boolean
    (Computed)[string] Is capable of Virt-IO drive hot unplug (no reboot required). This works only for non-Windows virtual Machines. Can only be updated.
    licenceType String
    (Computed)[string] OS type of this Snapshot
    name String
    [string] The name of the snapshot.
    nicHotPlug Boolean
    (Computed)[string] Is capable of nic hot plug (no reboot required). Can only be updated.
    nicHotUnplug Boolean
    (Computed)[string] Is capable of nic hot unplug (no reboot required). Can only be updated.
    ramHotPlug Boolean
    (Computed)[string] Is capable of memory hot plug (no reboot required). Can only be updated.
    secAuthProtection Boolean
    Boolean value representing if the snapshot requires extra protection e.g. two factor protection
    snapshotId String
    timeouts Property Map

    Outputs

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

    CpuHotUnplug bool
    Is capable of CPU hot unplug (no reboot required)
    DiscScsiHotPlug bool
    Is capable of SCSI drive hot plug (no reboot required)
    DiscScsiHotUnplug bool
    Is capable of SCSI drive hot unplug (no reboot required). This works only for non-Windows virtual Machines.
    Id string
    The provider-assigned unique ID for this managed resource.
    Location string
    Location of that image/snapshot
    RamHotUnplug bool
    Is capable of memory hot unplug (no reboot required)
    Size double
    The size of the image in GB
    CpuHotUnplug bool
    Is capable of CPU hot unplug (no reboot required)
    DiscScsiHotPlug bool
    Is capable of SCSI drive hot plug (no reboot required)
    DiscScsiHotUnplug bool
    Is capable of SCSI drive hot unplug (no reboot required). This works only for non-Windows virtual Machines.
    Id string
    The provider-assigned unique ID for this managed resource.
    Location string
    Location of that image/snapshot
    RamHotUnplug bool
    Is capable of memory hot unplug (no reboot required)
    Size float64
    The size of the image in GB
    cpuHotUnplug Boolean
    Is capable of CPU hot unplug (no reboot required)
    discScsiHotPlug Boolean
    Is capable of SCSI drive hot plug (no reboot required)
    discScsiHotUnplug Boolean
    Is capable of SCSI drive hot unplug (no reboot required). This works only for non-Windows virtual Machines.
    id String
    The provider-assigned unique ID for this managed resource.
    location String
    Location of that image/snapshot
    ramHotUnplug Boolean
    Is capable of memory hot unplug (no reboot required)
    size Double
    The size of the image in GB
    cpuHotUnplug boolean
    Is capable of CPU hot unplug (no reboot required)
    discScsiHotPlug boolean
    Is capable of SCSI drive hot plug (no reboot required)
    discScsiHotUnplug boolean
    Is capable of SCSI drive hot unplug (no reboot required). This works only for non-Windows virtual Machines.
    id string
    The provider-assigned unique ID for this managed resource.
    location string
    Location of that image/snapshot
    ramHotUnplug boolean
    Is capable of memory hot unplug (no reboot required)
    size number
    The size of the image in GB
    cpu_hot_unplug bool
    Is capable of CPU hot unplug (no reboot required)
    disc_scsi_hot_plug bool
    Is capable of SCSI drive hot plug (no reboot required)
    disc_scsi_hot_unplug bool
    Is capable of SCSI drive hot unplug (no reboot required). This works only for non-Windows virtual Machines.
    id str
    The provider-assigned unique ID for this managed resource.
    location str
    Location of that image/snapshot
    ram_hot_unplug bool
    Is capable of memory hot unplug (no reboot required)
    size float
    The size of the image in GB
    cpuHotUnplug Boolean
    Is capable of CPU hot unplug (no reboot required)
    discScsiHotPlug Boolean
    Is capable of SCSI drive hot plug (no reboot required)
    discScsiHotUnplug Boolean
    Is capable of SCSI drive hot unplug (no reboot required). This works only for non-Windows virtual Machines.
    id String
    The provider-assigned unique ID for this managed resource.
    location String
    Location of that image/snapshot
    ramHotUnplug Boolean
    Is capable of memory hot unplug (no reboot required)
    size Number
    The size of the image in GB

    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,
            cpu_hot_plug: Optional[bool] = None,
            cpu_hot_unplug: Optional[bool] = None,
            datacenter_id: Optional[str] = None,
            description: Optional[str] = None,
            disc_scsi_hot_plug: Optional[bool] = None,
            disc_scsi_hot_unplug: Optional[bool] = None,
            disc_virtio_hot_plug: Optional[bool] = None,
            disc_virtio_hot_unplug: Optional[bool] = None,
            licence_type: Optional[str] = None,
            location: Optional[str] = None,
            name: Optional[str] = None,
            nic_hot_plug: Optional[bool] = None,
            nic_hot_unplug: Optional[bool] = None,
            ram_hot_plug: Optional[bool] = None,
            ram_hot_unplug: Optional[bool] = None,
            sec_auth_protection: Optional[bool] = None,
            size: Optional[float] = None,
            snapshot_id: Optional[str] = None,
            timeouts: Optional[SnapshotTimeoutsArgs] = None,
            volume_id: 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: ionoscloud: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:
    CpuHotPlug bool
    (Computed)[string] Is capable of CPU hot plug (no reboot required). Can only be updated.
    CpuHotUnplug bool
    Is capable of CPU hot unplug (no reboot required)
    DatacenterId string
    [string] The ID of the Virtual Data Center.
    Description string
    (Computed)[string] Human readable description
    DiscScsiHotPlug bool
    Is capable of SCSI drive hot plug (no reboot required)
    DiscScsiHotUnplug bool
    Is capable of SCSI drive hot unplug (no reboot required). This works only for non-Windows virtual Machines.
    DiscVirtioHotPlug bool
    (Computed)[string] Is capable of Virt-IO drive hot plug (no reboot required). Can only be updated.
    DiscVirtioHotUnplug bool
    (Computed)[string] Is capable of Virt-IO drive hot unplug (no reboot required). This works only for non-Windows virtual Machines. Can only be updated.
    LicenceType string
    (Computed)[string] OS type of this Snapshot
    Location string
    Location of that image/snapshot
    Name string
    [string] The name of the snapshot.
    NicHotPlug bool
    (Computed)[string] Is capable of nic hot plug (no reboot required). Can only be updated.
    NicHotUnplug bool
    (Computed)[string] Is capable of nic hot unplug (no reboot required). Can only be updated.
    RamHotPlug bool
    (Computed)[string] Is capable of memory hot plug (no reboot required). Can only be updated.
    RamHotUnplug bool
    Is capable of memory hot unplug (no reboot required)
    SecAuthProtection bool
    Boolean value representing if the snapshot requires extra protection e.g. two factor protection
    Size double
    The size of the image in GB
    SnapshotId string
    Timeouts SnapshotTimeouts
    VolumeId string
    [string] The ID of the specific volume to take the snapshot from.
    CpuHotPlug bool
    (Computed)[string] Is capable of CPU hot plug (no reboot required). Can only be updated.
    CpuHotUnplug bool
    Is capable of CPU hot unplug (no reboot required)
    DatacenterId string
    [string] The ID of the Virtual Data Center.
    Description string
    (Computed)[string] Human readable description
    DiscScsiHotPlug bool
    Is capable of SCSI drive hot plug (no reboot required)
    DiscScsiHotUnplug bool
    Is capable of SCSI drive hot unplug (no reboot required). This works only for non-Windows virtual Machines.
    DiscVirtioHotPlug bool
    (Computed)[string] Is capable of Virt-IO drive hot plug (no reboot required). Can only be updated.
    DiscVirtioHotUnplug bool
    (Computed)[string] Is capable of Virt-IO drive hot unplug (no reboot required). This works only for non-Windows virtual Machines. Can only be updated.
    LicenceType string
    (Computed)[string] OS type of this Snapshot
    Location string
    Location of that image/snapshot
    Name string
    [string] The name of the snapshot.
    NicHotPlug bool
    (Computed)[string] Is capable of nic hot plug (no reboot required). Can only be updated.
    NicHotUnplug bool
    (Computed)[string] Is capable of nic hot unplug (no reboot required). Can only be updated.
    RamHotPlug bool
    (Computed)[string] Is capable of memory hot plug (no reboot required). Can only be updated.
    RamHotUnplug bool
    Is capable of memory hot unplug (no reboot required)
    SecAuthProtection bool
    Boolean value representing if the snapshot requires extra protection e.g. two factor protection
    Size float64
    The size of the image in GB
    SnapshotId string
    Timeouts SnapshotTimeoutsArgs
    VolumeId string
    [string] The ID of the specific volume to take the snapshot from.
    cpuHotPlug Boolean
    (Computed)[string] Is capable of CPU hot plug (no reboot required). Can only be updated.
    cpuHotUnplug Boolean
    Is capable of CPU hot unplug (no reboot required)
    datacenterId String
    [string] The ID of the Virtual Data Center.
    description String
    (Computed)[string] Human readable description
    discScsiHotPlug Boolean
    Is capable of SCSI drive hot plug (no reboot required)
    discScsiHotUnplug Boolean
    Is capable of SCSI drive hot unplug (no reboot required). This works only for non-Windows virtual Machines.
    discVirtioHotPlug Boolean
    (Computed)[string] Is capable of Virt-IO drive hot plug (no reboot required). Can only be updated.
    discVirtioHotUnplug Boolean
    (Computed)[string] Is capable of Virt-IO drive hot unplug (no reboot required). This works only for non-Windows virtual Machines. Can only be updated.
    licenceType String
    (Computed)[string] OS type of this Snapshot
    location String
    Location of that image/snapshot
    name String
    [string] The name of the snapshot.
    nicHotPlug Boolean
    (Computed)[string] Is capable of nic hot plug (no reboot required). Can only be updated.
    nicHotUnplug Boolean
    (Computed)[string] Is capable of nic hot unplug (no reboot required). Can only be updated.
    ramHotPlug Boolean
    (Computed)[string] Is capable of memory hot plug (no reboot required). Can only be updated.
    ramHotUnplug Boolean
    Is capable of memory hot unplug (no reboot required)
    secAuthProtection Boolean
    Boolean value representing if the snapshot requires extra protection e.g. two factor protection
    size Double
    The size of the image in GB
    snapshotId String
    timeouts SnapshotTimeouts
    volumeId String
    [string] The ID of the specific volume to take the snapshot from.
    cpuHotPlug boolean
    (Computed)[string] Is capable of CPU hot plug (no reboot required). Can only be updated.
    cpuHotUnplug boolean
    Is capable of CPU hot unplug (no reboot required)
    datacenterId string
    [string] The ID of the Virtual Data Center.
    description string
    (Computed)[string] Human readable description
    discScsiHotPlug boolean
    Is capable of SCSI drive hot plug (no reboot required)
    discScsiHotUnplug boolean
    Is capable of SCSI drive hot unplug (no reboot required). This works only for non-Windows virtual Machines.
    discVirtioHotPlug boolean
    (Computed)[string] Is capable of Virt-IO drive hot plug (no reboot required). Can only be updated.
    discVirtioHotUnplug boolean
    (Computed)[string] Is capable of Virt-IO drive hot unplug (no reboot required). This works only for non-Windows virtual Machines. Can only be updated.
    licenceType string
    (Computed)[string] OS type of this Snapshot
    location string
    Location of that image/snapshot
    name string
    [string] The name of the snapshot.
    nicHotPlug boolean
    (Computed)[string] Is capable of nic hot plug (no reboot required). Can only be updated.
    nicHotUnplug boolean
    (Computed)[string] Is capable of nic hot unplug (no reboot required). Can only be updated.
    ramHotPlug boolean
    (Computed)[string] Is capable of memory hot plug (no reboot required). Can only be updated.
    ramHotUnplug boolean
    Is capable of memory hot unplug (no reboot required)
    secAuthProtection boolean
    Boolean value representing if the snapshot requires extra protection e.g. two factor protection
    size number
    The size of the image in GB
    snapshotId string
    timeouts SnapshotTimeouts
    volumeId string
    [string] The ID of the specific volume to take the snapshot from.
    cpu_hot_plug bool
    (Computed)[string] Is capable of CPU hot plug (no reboot required). Can only be updated.
    cpu_hot_unplug bool
    Is capable of CPU hot unplug (no reboot required)
    datacenter_id str
    [string] The ID of the Virtual Data Center.
    description str
    (Computed)[string] Human readable description
    disc_scsi_hot_plug bool
    Is capable of SCSI drive hot plug (no reboot required)
    disc_scsi_hot_unplug bool
    Is capable of SCSI drive hot unplug (no reboot required). This works only for non-Windows virtual Machines.
    disc_virtio_hot_plug bool
    (Computed)[string] Is capable of Virt-IO drive hot plug (no reboot required). Can only be updated.
    disc_virtio_hot_unplug bool
    (Computed)[string] Is capable of Virt-IO drive hot unplug (no reboot required). This works only for non-Windows virtual Machines. Can only be updated.
    licence_type str
    (Computed)[string] OS type of this Snapshot
    location str
    Location of that image/snapshot
    name str
    [string] The name of the snapshot.
    nic_hot_plug bool
    (Computed)[string] Is capable of nic hot plug (no reboot required). Can only be updated.
    nic_hot_unplug bool
    (Computed)[string] Is capable of nic hot unplug (no reboot required). Can only be updated.
    ram_hot_plug bool
    (Computed)[string] Is capable of memory hot plug (no reboot required). Can only be updated.
    ram_hot_unplug bool
    Is capable of memory hot unplug (no reboot required)
    sec_auth_protection bool
    Boolean value representing if the snapshot requires extra protection e.g. two factor protection
    size float
    The size of the image in GB
    snapshot_id str
    timeouts SnapshotTimeoutsArgs
    volume_id str
    [string] The ID of the specific volume to take the snapshot from.
    cpuHotPlug Boolean
    (Computed)[string] Is capable of CPU hot plug (no reboot required). Can only be updated.
    cpuHotUnplug Boolean
    Is capable of CPU hot unplug (no reboot required)
    datacenterId String
    [string] The ID of the Virtual Data Center.
    description String
    (Computed)[string] Human readable description
    discScsiHotPlug Boolean
    Is capable of SCSI drive hot plug (no reboot required)
    discScsiHotUnplug Boolean
    Is capable of SCSI drive hot unplug (no reboot required). This works only for non-Windows virtual Machines.
    discVirtioHotPlug Boolean
    (Computed)[string] Is capable of Virt-IO drive hot plug (no reboot required). Can only be updated.
    discVirtioHotUnplug Boolean
    (Computed)[string] Is capable of Virt-IO drive hot unplug (no reboot required). This works only for non-Windows virtual Machines. Can only be updated.
    licenceType String
    (Computed)[string] OS type of this Snapshot
    location String
    Location of that image/snapshot
    name String
    [string] The name of the snapshot.
    nicHotPlug Boolean
    (Computed)[string] Is capable of nic hot plug (no reboot required). Can only be updated.
    nicHotUnplug Boolean
    (Computed)[string] Is capable of nic hot unplug (no reboot required). Can only be updated.
    ramHotPlug Boolean
    (Computed)[string] Is capable of memory hot plug (no reboot required). Can only be updated.
    ramHotUnplug Boolean
    Is capable of memory hot unplug (no reboot required)
    secAuthProtection Boolean
    Boolean value representing if the snapshot requires extra protection e.g. two factor protection
    size Number
    The size of the image in GB
    snapshotId String
    timeouts Property Map
    volumeId String
    [string] The ID of the specific volume to take the snapshot from.

    Supporting Types

    SnapshotTimeouts, SnapshotTimeoutsArgs

    Create string
    Default string
    Delete string
    Update string
    Create string
    Default string
    Delete string
    Update string
    create String
    default_ String
    delete String
    update String
    create string
    default string
    delete string
    update string
    create String
    default String
    delete String
    update String

    Import

    Resource Snapshot can be imported using the snapshot id, e.g.

    $ pulumi import ionoscloud:index/snapshot:Snapshot mysnapshot snapshot uuid
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    ionoscloud ionos-cloud/terraform-provider-ionoscloud
    License
    Notes
    This Pulumi package is based on the ionoscloud Terraform Provider.
    ionoscloud logo
    ionoscloud 6.7.6 published on Monday, Apr 14, 2025 by ionos-cloud