1. Packages
  2. Volcengine
  3. API Docs
  4. ebs
  5. SnapshotGroup
Volcengine v0.0.27 published on Tuesday, Dec 10, 2024 by Volcengine

volcengine.ebs.SnapshotGroup

Explore with Pulumi AI

Provides a resource to manage ebs snapshot group

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as volcengine from "@pulumi/volcengine";
import * as volcengine from "@volcengine/pulumi";

const fooZones = volcengine.ecs.Zones({});
const fooVpc = new volcengine.vpc.Vpc("fooVpc", {
    vpcName: "acc-test-vpc",
    cidrBlock: "172.16.0.0/16",
});
const fooSubnet = new volcengine.vpc.Subnet("fooSubnet", {
    subnetName: "acc-test-subnet",
    cidrBlock: "172.16.0.0/24",
    zoneId: fooZones.then(fooZones => fooZones.zones?.[0]?.id),
    vpcId: fooVpc.id,
});
const fooSecurityGroup = new volcengine.vpc.SecurityGroup("fooSecurityGroup", {
    securityGroupName: "acc-test-security-group",
    vpcId: fooVpc.id,
});
const fooImages = volcengine.ecs.Images({
    osType: "Linux",
    visibility: "public",
    instanceTypeId: "ecs.g3il.large",
});
const fooInstance = new volcengine.ecs.Instance("fooInstance", {
    instanceName: "acc-test-ecs",
    description: "acc-test",
    hostName: "tf-acc-test",
    imageId: fooImages.then(fooImages => fooImages.images?.[0]?.imageId),
    instanceType: "ecs.g3il.large",
    password: "93f0cb0614Aab12",
    instanceChargeType: "PostPaid",
    systemVolumeType: "ESSD_PL0",
    systemVolumeSize: 40,
    subnetId: fooSubnet.id,
    securityGroupIds: [fooSecurityGroup.id],
    projectName: "default",
    tags: [{
        key: "k1",
        value: "v1",
    }],
});
const fooVolume = new volcengine.ebs.Volume("fooVolume", {
    volumeName: "acc-test-volume",
    volumeType: "ESSD_PL0",
    description: "acc-test",
    kind: "data",
    size: 500,
    zoneId: fooZones.then(fooZones => fooZones.zones?.[0]?.id),
    volumeChargeType: "PostPaid",
    projectName: "default",
});
const fooVolumeAttach = new volcengine.ebs.VolumeAttach("fooVolumeAttach", {
    instanceId: fooInstance.id,
    volumeId: fooVolume.id,
});
const fooSnapshotGroup = new volcengine.ebs.SnapshotGroup("fooSnapshotGroup", {
    volumeIds: [
        fooInstance.systemVolumeId,
        fooVolume.id,
    ],
    instanceId: fooInstance.id,
    description: "acc-test",
    projectName: "default",
    tags: [{
        key: "k1",
        value: "v1",
    }],
}, {
    dependsOn: [fooVolumeAttach],
});
Copy
import pulumi
import pulumi_volcengine as volcengine

foo_zones = volcengine.ecs.zones()
foo_vpc = volcengine.vpc.Vpc("fooVpc",
    vpc_name="acc-test-vpc",
    cidr_block="172.16.0.0/16")
foo_subnet = volcengine.vpc.Subnet("fooSubnet",
    subnet_name="acc-test-subnet",
    cidr_block="172.16.0.0/24",
    zone_id=foo_zones.zones[0].id,
    vpc_id=foo_vpc.id)
foo_security_group = volcengine.vpc.SecurityGroup("fooSecurityGroup",
    security_group_name="acc-test-security-group",
    vpc_id=foo_vpc.id)
foo_images = volcengine.ecs.images(os_type="Linux",
    visibility="public",
    instance_type_id="ecs.g3il.large")
foo_instance = volcengine.ecs.Instance("fooInstance",
    instance_name="acc-test-ecs",
    description="acc-test",
    host_name="tf-acc-test",
    image_id=foo_images.images[0].image_id,
    instance_type="ecs.g3il.large",
    password="93f0cb0614Aab12",
    instance_charge_type="PostPaid",
    system_volume_type="ESSD_PL0",
    system_volume_size=40,
    subnet_id=foo_subnet.id,
    security_group_ids=[foo_security_group.id],
    project_name="default",
    tags=[volcengine.ecs.InstanceTagArgs(
        key="k1",
        value="v1",
    )])
foo_volume = volcengine.ebs.Volume("fooVolume",
    volume_name="acc-test-volume",
    volume_type="ESSD_PL0",
    description="acc-test",
    kind="data",
    size=500,
    zone_id=foo_zones.zones[0].id,
    volume_charge_type="PostPaid",
    project_name="default")
foo_volume_attach = volcengine.ebs.VolumeAttach("fooVolumeAttach",
    instance_id=foo_instance.id,
    volume_id=foo_volume.id)
foo_snapshot_group = volcengine.ebs.SnapshotGroup("fooSnapshotGroup",
    volume_ids=[
        foo_instance.system_volume_id,
        foo_volume.id,
    ],
    instance_id=foo_instance.id,
    description="acc-test",
    project_name="default",
    tags=[volcengine.ebs.SnapshotGroupTagArgs(
        key="k1",
        value="v1",
    )],
    opts=pulumi.ResourceOptions(depends_on=[foo_volume_attach]))
Copy
package main

import (
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
	"github.com/volcengine/pulumi-volcengine/sdk/go/volcengine/ebs"
	"github.com/volcengine/pulumi-volcengine/sdk/go/volcengine/ecs"
	"github.com/volcengine/pulumi-volcengine/sdk/go/volcengine/vpc"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		fooZones, err := ecs.Zones(ctx, nil, nil)
		if err != nil {
			return err
		}
		fooVpc, err := vpc.NewVpc(ctx, "fooVpc", &vpc.VpcArgs{
			VpcName:   pulumi.String("acc-test-vpc"),
			CidrBlock: pulumi.String("172.16.0.0/16"),
		})
		if err != nil {
			return err
		}
		fooSubnet, err := vpc.NewSubnet(ctx, "fooSubnet", &vpc.SubnetArgs{
			SubnetName: pulumi.String("acc-test-subnet"),
			CidrBlock:  pulumi.String("172.16.0.0/24"),
			ZoneId:     pulumi.String(fooZones.Zones[0].Id),
			VpcId:      fooVpc.ID(),
		})
		if err != nil {
			return err
		}
		fooSecurityGroup, err := vpc.NewSecurityGroup(ctx, "fooSecurityGroup", &vpc.SecurityGroupArgs{
			SecurityGroupName: pulumi.String("acc-test-security-group"),
			VpcId:             fooVpc.ID(),
		})
		if err != nil {
			return err
		}
		fooImages, err := ecs.Images(ctx, &ecs.ImagesArgs{
			OsType:         pulumi.StringRef("Linux"),
			Visibility:     pulumi.StringRef("public"),
			InstanceTypeId: pulumi.StringRef("ecs.g3il.large"),
		}, nil)
		if err != nil {
			return err
		}
		fooInstance, err := ecs.NewInstance(ctx, "fooInstance", &ecs.InstanceArgs{
			InstanceName:       pulumi.String("acc-test-ecs"),
			Description:        pulumi.String("acc-test"),
			HostName:           pulumi.String("tf-acc-test"),
			ImageId:            pulumi.String(fooImages.Images[0].ImageId),
			InstanceType:       pulumi.String("ecs.g3il.large"),
			Password:           pulumi.String("93f0cb0614Aab12"),
			InstanceChargeType: pulumi.String("PostPaid"),
			SystemVolumeType:   pulumi.String("ESSD_PL0"),
			SystemVolumeSize:   pulumi.Int(40),
			SubnetId:           fooSubnet.ID(),
			SecurityGroupIds: pulumi.StringArray{
				fooSecurityGroup.ID(),
			},
			ProjectName: pulumi.String("default"),
			Tags: ecs.InstanceTagArray{
				&ecs.InstanceTagArgs{
					Key:   pulumi.String("k1"),
					Value: pulumi.String("v1"),
				},
			},
		})
		if err != nil {
			return err
		}
		fooVolume, err := ebs.NewVolume(ctx, "fooVolume", &ebs.VolumeArgs{
			VolumeName:       pulumi.String("acc-test-volume"),
			VolumeType:       pulumi.String("ESSD_PL0"),
			Description:      pulumi.String("acc-test"),
			Kind:             pulumi.String("data"),
			Size:             pulumi.Int(500),
			ZoneId:           pulumi.String(fooZones.Zones[0].Id),
			VolumeChargeType: pulumi.String("PostPaid"),
			ProjectName:      pulumi.String("default"),
		})
		if err != nil {
			return err
		}
		fooVolumeAttach, err := ebs.NewVolumeAttach(ctx, "fooVolumeAttach", &ebs.VolumeAttachArgs{
			InstanceId: fooInstance.ID(),
			VolumeId:   fooVolume.ID(),
		})
		if err != nil {
			return err
		}
		_, err = ebs.NewSnapshotGroup(ctx, "fooSnapshotGroup", &ebs.SnapshotGroupArgs{
			VolumeIds: pulumi.StringArray{
				fooInstance.SystemVolumeId,
				fooVolume.ID(),
			},
			InstanceId:  fooInstance.ID(),
			Description: pulumi.String("acc-test"),
			ProjectName: pulumi.String("default"),
			Tags: ebs.SnapshotGroupTagArray{
				&ebs.SnapshotGroupTagArgs{
					Key:   pulumi.String("k1"),
					Value: pulumi.String("v1"),
				},
			},
		}, pulumi.DependsOn([]pulumi.Resource{
			fooVolumeAttach,
		}))
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Volcengine = Pulumi.Volcengine;

return await Deployment.RunAsync(() => 
{
    var fooZones = Volcengine.Ecs.Zones.Invoke();

    var fooVpc = new Volcengine.Vpc.Vpc("fooVpc", new()
    {
        VpcName = "acc-test-vpc",
        CidrBlock = "172.16.0.0/16",
    });

    var fooSubnet = new Volcengine.Vpc.Subnet("fooSubnet", new()
    {
        SubnetName = "acc-test-subnet",
        CidrBlock = "172.16.0.0/24",
        ZoneId = fooZones.Apply(zonesResult => zonesResult.Zones[0]?.Id),
        VpcId = fooVpc.Id,
    });

    var fooSecurityGroup = new Volcengine.Vpc.SecurityGroup("fooSecurityGroup", new()
    {
        SecurityGroupName = "acc-test-security-group",
        VpcId = fooVpc.Id,
    });

    var fooImages = Volcengine.Ecs.Images.Invoke(new()
    {
        OsType = "Linux",
        Visibility = "public",
        InstanceTypeId = "ecs.g3il.large",
    });

    var fooInstance = new Volcengine.Ecs.Instance("fooInstance", new()
    {
        InstanceName = "acc-test-ecs",
        Description = "acc-test",
        HostName = "tf-acc-test",
        ImageId = fooImages.Apply(imagesResult => imagesResult.Images[0]?.ImageId),
        InstanceType = "ecs.g3il.large",
        Password = "93f0cb0614Aab12",
        InstanceChargeType = "PostPaid",
        SystemVolumeType = "ESSD_PL0",
        SystemVolumeSize = 40,
        SubnetId = fooSubnet.Id,
        SecurityGroupIds = new[]
        {
            fooSecurityGroup.Id,
        },
        ProjectName = "default",
        Tags = new[]
        {
            new Volcengine.Ecs.Inputs.InstanceTagArgs
            {
                Key = "k1",
                Value = "v1",
            },
        },
    });

    var fooVolume = new Volcengine.Ebs.Volume("fooVolume", new()
    {
        VolumeName = "acc-test-volume",
        VolumeType = "ESSD_PL0",
        Description = "acc-test",
        Kind = "data",
        Size = 500,
        ZoneId = fooZones.Apply(zonesResult => zonesResult.Zones[0]?.Id),
        VolumeChargeType = "PostPaid",
        ProjectName = "default",
    });

    var fooVolumeAttach = new Volcengine.Ebs.VolumeAttach("fooVolumeAttach", new()
    {
        InstanceId = fooInstance.Id,
        VolumeId = fooVolume.Id,
    });

    var fooSnapshotGroup = new Volcengine.Ebs.SnapshotGroup("fooSnapshotGroup", new()
    {
        VolumeIds = new[]
        {
            fooInstance.SystemVolumeId,
            fooVolume.Id,
        },
        InstanceId = fooInstance.Id,
        Description = "acc-test",
        ProjectName = "default",
        Tags = new[]
        {
            new Volcengine.Ebs.Inputs.SnapshotGroupTagArgs
            {
                Key = "k1",
                Value = "v1",
            },
        },
    }, new CustomResourceOptions
    {
        DependsOn =
        {
            fooVolumeAttach,
        },
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.volcengine.ecs.EcsFunctions;
import com.pulumi.volcengine.ecs.inputs.ZonesArgs;
import com.pulumi.volcengine.vpc.Vpc;
import com.pulumi.volcengine.vpc.VpcArgs;
import com.pulumi.volcengine.vpc.Subnet;
import com.pulumi.volcengine.vpc.SubnetArgs;
import com.pulumi.volcengine.vpc.SecurityGroup;
import com.pulumi.volcengine.vpc.SecurityGroupArgs;
import com.pulumi.volcengine.ecs.inputs.ImagesArgs;
import com.pulumi.volcengine.ecs.Instance;
import com.pulumi.volcengine.ecs.InstanceArgs;
import com.pulumi.volcengine.ecs.inputs.InstanceTagArgs;
import com.pulumi.volcengine.ebs.Volume;
import com.pulumi.volcengine.ebs.VolumeArgs;
import com.pulumi.volcengine.ebs.VolumeAttach;
import com.pulumi.volcengine.ebs.VolumeAttachArgs;
import com.pulumi.volcengine.ebs.SnapshotGroup;
import com.pulumi.volcengine.ebs.SnapshotGroupArgs;
import com.pulumi.volcengine.ebs.inputs.SnapshotGroupTagArgs;
import com.pulumi.resources.CustomResourceOptions;
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 fooZones = EcsFunctions.Zones();

        var fooVpc = new Vpc("fooVpc", VpcArgs.builder()        
            .vpcName("acc-test-vpc")
            .cidrBlock("172.16.0.0/16")
            .build());

        var fooSubnet = new Subnet("fooSubnet", SubnetArgs.builder()        
            .subnetName("acc-test-subnet")
            .cidrBlock("172.16.0.0/24")
            .zoneId(fooZones.applyValue(zonesResult -> zonesResult.zones()[0].id()))
            .vpcId(fooVpc.id())
            .build());

        var fooSecurityGroup = new SecurityGroup("fooSecurityGroup", SecurityGroupArgs.builder()        
            .securityGroupName("acc-test-security-group")
            .vpcId(fooVpc.id())
            .build());

        final var fooImages = EcsFunctions.Images(ImagesArgs.builder()
            .osType("Linux")
            .visibility("public")
            .instanceTypeId("ecs.g3il.large")
            .build());

        var fooInstance = new Instance("fooInstance", InstanceArgs.builder()        
            .instanceName("acc-test-ecs")
            .description("acc-test")
            .hostName("tf-acc-test")
            .imageId(fooImages.applyValue(imagesResult -> imagesResult.images()[0].imageId()))
            .instanceType("ecs.g3il.large")
            .password("93f0cb0614Aab12")
            .instanceChargeType("PostPaid")
            .systemVolumeType("ESSD_PL0")
            .systemVolumeSize(40)
            .subnetId(fooSubnet.id())
            .securityGroupIds(fooSecurityGroup.id())
            .projectName("default")
            .tags(InstanceTagArgs.builder()
                .key("k1")
                .value("v1")
                .build())
            .build());

        var fooVolume = new Volume("fooVolume", VolumeArgs.builder()        
            .volumeName("acc-test-volume")
            .volumeType("ESSD_PL0")
            .description("acc-test")
            .kind("data")
            .size(500)
            .zoneId(fooZones.applyValue(zonesResult -> zonesResult.zones()[0].id()))
            .volumeChargeType("PostPaid")
            .projectName("default")
            .build());

        var fooVolumeAttach = new VolumeAttach("fooVolumeAttach", VolumeAttachArgs.builder()        
            .instanceId(fooInstance.id())
            .volumeId(fooVolume.id())
            .build());

        var fooSnapshotGroup = new SnapshotGroup("fooSnapshotGroup", SnapshotGroupArgs.builder()        
            .volumeIds(            
                fooInstance.systemVolumeId(),
                fooVolume.id())
            .instanceId(fooInstance.id())
            .description("acc-test")
            .projectName("default")
            .tags(SnapshotGroupTagArgs.builder()
                .key("k1")
                .value("v1")
                .build())
            .build(), CustomResourceOptions.builder()
                .dependsOn(fooVolumeAttach)
                .build());

    }
}
Copy
resources:
  fooVpc:
    type: volcengine:vpc:Vpc
    properties:
      vpcName: acc-test-vpc
      cidrBlock: 172.16.0.0/16
  fooSubnet:
    type: volcengine:vpc:Subnet
    properties:
      subnetName: acc-test-subnet
      cidrBlock: 172.16.0.0/24
      zoneId: ${fooZones.zones[0].id}
      vpcId: ${fooVpc.id}
  fooSecurityGroup:
    type: volcengine:vpc:SecurityGroup
    properties:
      securityGroupName: acc-test-security-group
      vpcId: ${fooVpc.id}
  fooInstance:
    type: volcengine:ecs:Instance
    properties:
      instanceName: acc-test-ecs
      description: acc-test
      hostName: tf-acc-test
      imageId: ${fooImages.images[0].imageId}
      instanceType: ecs.g3il.large
      password: 93f0cb0614Aab12
      instanceChargeType: PostPaid
      systemVolumeType: ESSD_PL0
      systemVolumeSize: 40
      subnetId: ${fooSubnet.id}
      securityGroupIds:
        - ${fooSecurityGroup.id}
      projectName: default
      tags:
        - key: k1
          value: v1
  fooVolume:
    type: volcengine:ebs:Volume
    properties:
      volumeName: acc-test-volume
      volumeType: ESSD_PL0
      description: acc-test
      kind: data
      size: 500
      zoneId: ${fooZones.zones[0].id}
      volumeChargeType: PostPaid
      projectName: default
  fooVolumeAttach:
    type: volcengine:ebs:VolumeAttach
    properties:
      instanceId: ${fooInstance.id}
      volumeId: ${fooVolume.id}
  fooSnapshotGroup:
    type: volcengine:ebs:SnapshotGroup
    properties:
      volumeIds:
        - ${fooInstance.systemVolumeId}
        - ${fooVolume.id}
      instanceId: ${fooInstance.id}
      description: acc-test
      projectName: default
      tags:
        - key: k1
          value: v1
    options:
      dependson:
        - ${fooVolumeAttach}
variables:
  fooZones:
    fn::invoke:
      Function: volcengine:ecs:Zones
      Arguments: {}
  fooImages:
    fn::invoke:
      Function: volcengine:ecs:Images
      Arguments:
        osType: Linux
        visibility: public
        instanceTypeId: ecs.g3il.large
Copy

Create SnapshotGroup Resource

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

Constructor syntax

new SnapshotGroup(name: string, args: SnapshotGroupArgs, opts?: CustomResourceOptions);
@overload
def SnapshotGroup(resource_name: str,
                  args: SnapshotGroupArgs,
                  opts: Optional[ResourceOptions] = None)

@overload
def SnapshotGroup(resource_name: str,
                  opts: Optional[ResourceOptions] = None,
                  volume_ids: Optional[Sequence[str]] = None,
                  description: Optional[str] = None,
                  instance_id: Optional[str] = None,
                  name: Optional[str] = None,
                  project_name: Optional[str] = None,
                  tags: Optional[Sequence[SnapshotGroupTagArgs]] = None)
func NewSnapshotGroup(ctx *Context, name string, args SnapshotGroupArgs, opts ...ResourceOption) (*SnapshotGroup, error)
public SnapshotGroup(string name, SnapshotGroupArgs args, CustomResourceOptions? opts = null)
public SnapshotGroup(String name, SnapshotGroupArgs args)
public SnapshotGroup(String name, SnapshotGroupArgs args, CustomResourceOptions options)
type: volcengine:ebs:SnapshotGroup
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args This property is required. SnapshotGroupArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. SnapshotGroupArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args This property is required. SnapshotGroupArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. SnapshotGroupArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. SnapshotGroupArgs
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 snapshotGroupResource = new Volcengine.Ebs.SnapshotGroup("snapshotGroupResource", new()
{
    VolumeIds = new[]
    {
        "string",
    },
    Description = "string",
    InstanceId = "string",
    Name = "string",
    ProjectName = "string",
    Tags = new[]
    {
        new Volcengine.Ebs.Inputs.SnapshotGroupTagArgs
        {
            Key = "string",
            Value = "string",
        },
    },
});
Copy
example, err := ebs.NewSnapshotGroup(ctx, "snapshotGroupResource", &ebs.SnapshotGroupArgs{
	VolumeIds: pulumi.StringArray{
		pulumi.String("string"),
	},
	Description: pulumi.String("string"),
	InstanceId:  pulumi.String("string"),
	Name:        pulumi.String("string"),
	ProjectName: pulumi.String("string"),
	Tags: ebs.SnapshotGroupTagArray{
		&ebs.SnapshotGroupTagArgs{
			Key:   pulumi.String("string"),
			Value: pulumi.String("string"),
		},
	},
})
Copy
var snapshotGroupResource = new SnapshotGroup("snapshotGroupResource", SnapshotGroupArgs.builder()
    .volumeIds("string")
    .description("string")
    .instanceId("string")
    .name("string")
    .projectName("string")
    .tags(SnapshotGroupTagArgs.builder()
        .key("string")
        .value("string")
        .build())
    .build());
Copy
snapshot_group_resource = volcengine.ebs.SnapshotGroup("snapshotGroupResource",
    volume_ids=["string"],
    description="string",
    instance_id="string",
    name="string",
    project_name="string",
    tags=[{
        "key": "string",
        "value": "string",
    }])
Copy
const snapshotGroupResource = new volcengine.ebs.SnapshotGroup("snapshotGroupResource", {
    volumeIds: ["string"],
    description: "string",
    instanceId: "string",
    name: "string",
    projectName: "string",
    tags: [{
        key: "string",
        value: "string",
    }],
});
Copy
type: volcengine:ebs:SnapshotGroup
properties:
    description: string
    instanceId: string
    name: string
    projectName: string
    tags:
        - key: string
          value: string
    volumeIds:
        - string
Copy

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

VolumeIds
This property is required.
Changes to this property will trigger replacement.
List<string>
The volume id of the snapshot group. The status of the volume must be attached.If multiple volumes are specified, they need to be attached to the same ECS instance.
Description string
The instance id of the snapshot group.
InstanceId Changes to this property will trigger replacement. string
The instance id of the snapshot group.
Name string
The name of the snapshot group.
ProjectName string
The project name of the snapshot group.
Tags List<SnapshotGroupTag>
Tags.
VolumeIds
This property is required.
Changes to this property will trigger replacement.
[]string
The volume id of the snapshot group. The status of the volume must be attached.If multiple volumes are specified, they need to be attached to the same ECS instance.
Description string
The instance id of the snapshot group.
InstanceId Changes to this property will trigger replacement. string
The instance id of the snapshot group.
Name string
The name of the snapshot group.
ProjectName string
The project name of the snapshot group.
Tags []SnapshotGroupTagArgs
Tags.
volumeIds
This property is required.
Changes to this property will trigger replacement.
List<String>
The volume id of the snapshot group. The status of the volume must be attached.If multiple volumes are specified, they need to be attached to the same ECS instance.
description String
The instance id of the snapshot group.
instanceId Changes to this property will trigger replacement. String
The instance id of the snapshot group.
name String
The name of the snapshot group.
projectName String
The project name of the snapshot group.
tags List<SnapshotGroupTag>
Tags.
volumeIds
This property is required.
Changes to this property will trigger replacement.
string[]
The volume id of the snapshot group. The status of the volume must be attached.If multiple volumes are specified, they need to be attached to the same ECS instance.
description string
The instance id of the snapshot group.
instanceId Changes to this property will trigger replacement. string
The instance id of the snapshot group.
name string
The name of the snapshot group.
projectName string
The project name of the snapshot group.
tags SnapshotGroupTag[]
Tags.
volume_ids
This property is required.
Changes to this property will trigger replacement.
Sequence[str]
The volume id of the snapshot group. The status of the volume must be attached.If multiple volumes are specified, they need to be attached to the same ECS instance.
description str
The instance id of the snapshot group.
instance_id Changes to this property will trigger replacement. str
The instance id of the snapshot group.
name str
The name of the snapshot group.
project_name str
The project name of the snapshot group.
tags Sequence[SnapshotGroupTagArgs]
Tags.
volumeIds
This property is required.
Changes to this property will trigger replacement.
List<String>
The volume id of the snapshot group. The status of the volume must be attached.If multiple volumes are specified, they need to be attached to the same ECS instance.
description String
The instance id of the snapshot group.
instanceId Changes to this property will trigger replacement. String
The instance id of the snapshot group.
name String
The name of the snapshot group.
projectName String
The project name of the snapshot group.
tags List<Property Map>
Tags.

Outputs

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

CreationTime string
The creation time of the snapshot group.
Id string
The provider-assigned unique ID for this managed resource.
ImageId string
The image id of the snapshot group.
Status string
The status of the snapshot group.
CreationTime string
The creation time of the snapshot group.
Id string
The provider-assigned unique ID for this managed resource.
ImageId string
The image id of the snapshot group.
Status string
The status of the snapshot group.
creationTime String
The creation time of the snapshot group.
id String
The provider-assigned unique ID for this managed resource.
imageId String
The image id of the snapshot group.
status String
The status of the snapshot group.
creationTime string
The creation time of the snapshot group.
id string
The provider-assigned unique ID for this managed resource.
imageId string
The image id of the snapshot group.
status string
The status of the snapshot group.
creation_time str
The creation time of the snapshot group.
id str
The provider-assigned unique ID for this managed resource.
image_id str
The image id of the snapshot group.
status str
The status of the snapshot group.
creationTime String
The creation time of the snapshot group.
id String
The provider-assigned unique ID for this managed resource.
imageId String
The image id of the snapshot group.
status String
The status of the snapshot group.

Look up Existing SnapshotGroup Resource

Get an existing SnapshotGroup 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?: SnapshotGroupState, opts?: CustomResourceOptions): SnapshotGroup
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        creation_time: Optional[str] = None,
        description: Optional[str] = None,
        image_id: Optional[str] = None,
        instance_id: Optional[str] = None,
        name: Optional[str] = None,
        project_name: Optional[str] = None,
        status: Optional[str] = None,
        tags: Optional[Sequence[SnapshotGroupTagArgs]] = None,
        volume_ids: Optional[Sequence[str]] = None) -> SnapshotGroup
func GetSnapshotGroup(ctx *Context, name string, id IDInput, state *SnapshotGroupState, opts ...ResourceOption) (*SnapshotGroup, error)
public static SnapshotGroup Get(string name, Input<string> id, SnapshotGroupState? state, CustomResourceOptions? opts = null)
public static SnapshotGroup get(String name, Output<String> id, SnapshotGroupState state, CustomResourceOptions options)
resources:  _:    type: volcengine:ebs:SnapshotGroup    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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:
CreationTime string
The creation time of the snapshot group.
Description string
The instance id of the snapshot group.
ImageId string
The image id of the snapshot group.
InstanceId Changes to this property will trigger replacement. string
The instance id of the snapshot group.
Name string
The name of the snapshot group.
ProjectName string
The project name of the snapshot group.
Status string
The status of the snapshot group.
Tags List<SnapshotGroupTag>
Tags.
VolumeIds Changes to this property will trigger replacement. List<string>
The volume id of the snapshot group. The status of the volume must be attached.If multiple volumes are specified, they need to be attached to the same ECS instance.
CreationTime string
The creation time of the snapshot group.
Description string
The instance id of the snapshot group.
ImageId string
The image id of the snapshot group.
InstanceId Changes to this property will trigger replacement. string
The instance id of the snapshot group.
Name string
The name of the snapshot group.
ProjectName string
The project name of the snapshot group.
Status string
The status of the snapshot group.
Tags []SnapshotGroupTagArgs
Tags.
VolumeIds Changes to this property will trigger replacement. []string
The volume id of the snapshot group. The status of the volume must be attached.If multiple volumes are specified, they need to be attached to the same ECS instance.
creationTime String
The creation time of the snapshot group.
description String
The instance id of the snapshot group.
imageId String
The image id of the snapshot group.
instanceId Changes to this property will trigger replacement. String
The instance id of the snapshot group.
name String
The name of the snapshot group.
projectName String
The project name of the snapshot group.
status String
The status of the snapshot group.
tags List<SnapshotGroupTag>
Tags.
volumeIds Changes to this property will trigger replacement. List<String>
The volume id of the snapshot group. The status of the volume must be attached.If multiple volumes are specified, they need to be attached to the same ECS instance.
creationTime string
The creation time of the snapshot group.
description string
The instance id of the snapshot group.
imageId string
The image id of the snapshot group.
instanceId Changes to this property will trigger replacement. string
The instance id of the snapshot group.
name string
The name of the snapshot group.
projectName string
The project name of the snapshot group.
status string
The status of the snapshot group.
tags SnapshotGroupTag[]
Tags.
volumeIds Changes to this property will trigger replacement. string[]
The volume id of the snapshot group. The status of the volume must be attached.If multiple volumes are specified, they need to be attached to the same ECS instance.
creation_time str
The creation time of the snapshot group.
description str
The instance id of the snapshot group.
image_id str
The image id of the snapshot group.
instance_id Changes to this property will trigger replacement. str
The instance id of the snapshot group.
name str
The name of the snapshot group.
project_name str
The project name of the snapshot group.
status str
The status of the snapshot group.
tags Sequence[SnapshotGroupTagArgs]
Tags.
volume_ids Changes to this property will trigger replacement. Sequence[str]
The volume id of the snapshot group. The status of the volume must be attached.If multiple volumes are specified, they need to be attached to the same ECS instance.
creationTime String
The creation time of the snapshot group.
description String
The instance id of the snapshot group.
imageId String
The image id of the snapshot group.
instanceId Changes to this property will trigger replacement. String
The instance id of the snapshot group.
name String
The name of the snapshot group.
projectName String
The project name of the snapshot group.
status String
The status of the snapshot group.
tags List<Property Map>
Tags.
volumeIds Changes to this property will trigger replacement. List<String>
The volume id of the snapshot group. The status of the volume must be attached.If multiple volumes are specified, they need to be attached to the same ECS instance.

Supporting Types

SnapshotGroupTag
, SnapshotGroupTagArgs

Key This property is required. string
The Key of Tags.
Value This property is required. string
The Value of Tags.
Key This property is required. string
The Key of Tags.
Value This property is required. string
The Value of Tags.
key This property is required. String
The Key of Tags.
value This property is required. String
The Value of Tags.
key This property is required. string
The Key of Tags.
value This property is required. string
The Value of Tags.
key This property is required. str
The Key of Tags.
value This property is required. str
The Value of Tags.
key This property is required. String
The Key of Tags.
value This property is required. String
The Value of Tags.

Import

EbsSnapshotGroup can be imported using the id, e.g.

$ pulumi import volcengine:ebs/snapshotGroup:SnapshotGroup default resource_id
Copy

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

Package Details

Repository
volcengine volcengine/pulumi-volcengine
License
Apache-2.0
Notes
This Pulumi package is based on the volcengine Terraform Provider.