ucloud.Disk
Explore with Pulumi AI
Provides a Cloud Disk resource.
Note If the disk have attached to the instance and reboot_instance_for_resizing is not set to false, the instance will reboot automatically to make the change take effect when update the
disk_size
by default.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as ucloud from "@pulumi/ucloud";
const _default = ucloud.getZones({});
// Create cloud disk
const example = new ucloud.Disk("example", {
availabilityZone: _default.then(_default => _default.zones?.[0]?.id),
diskSize: 10,
});
import pulumi
import pulumi_ucloud as ucloud
default = ucloud.get_zones()
# Create cloud disk
example = ucloud.Disk("example",
availability_zone=default.zones[0].id,
disk_size=10)
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/ucloud/ucloud"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_default, err := ucloud.GetZones(ctx, &ucloud.GetZonesArgs{}, nil)
if err != nil {
return err
}
// Create cloud disk
_, err = ucloud.NewDisk(ctx, "example", &ucloud.DiskArgs{
AvailabilityZone: pulumi.String(_default.Zones[0].Id),
DiskSize: pulumi.Float64(10),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Ucloud = Pulumi.Ucloud;
return await Deployment.RunAsync(() =>
{
var @default = Ucloud.GetZones.Invoke();
// Create cloud disk
var example = new Ucloud.Disk("example", new()
{
AvailabilityZone = @default.Apply(@default => @default.Apply(getZonesResult => getZonesResult.Zones[0]?.Id)),
DiskSize = 10,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.ucloud.UcloudFunctions;
import com.pulumi.ucloud.inputs.GetZonesArgs;
import com.pulumi.ucloud.Disk;
import com.pulumi.ucloud.DiskArgs;
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 default = UcloudFunctions.getZones();
// Create cloud disk
var example = new Disk("example", DiskArgs.builder()
.availabilityZone(default_.zones()[0].id())
.diskSize(10)
.build());
}
}
resources:
# Create cloud disk
example:
type: ucloud:Disk
properties:
availabilityZone: ${default.zones[0].id}
diskSize: 10
variables:
default:
fn::invoke:
function: ucloud:getZones
arguments: {}
Create Disk Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Disk(name: string, args: DiskArgs, opts?: CustomResourceOptions);
@overload
def Disk(resource_name: str,
args: DiskArgs,
opts: Optional[ResourceOptions] = None)
@overload
def Disk(resource_name: str,
opts: Optional[ResourceOptions] = None,
availability_zone: Optional[str] = None,
disk_size: Optional[float] = None,
charge_type: Optional[str] = None,
disk_id: Optional[str] = None,
disk_type: Optional[str] = None,
duration: Optional[float] = None,
name: Optional[str] = None,
rdma_cluster_id: Optional[str] = None,
reboot_instance_for_resizing: Optional[bool] = None,
tag: Optional[str] = None)
func NewDisk(ctx *Context, name string, args DiskArgs, opts ...ResourceOption) (*Disk, error)
public Disk(string name, DiskArgs args, CustomResourceOptions? opts = null)
type: ucloud:Disk
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 DiskArgs
- 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 DiskArgs
- 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 DiskArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args DiskArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args DiskArgs
- 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 diskResource = new Ucloud.Disk("diskResource", new()
{
AvailabilityZone = "string",
DiskSize = 0,
ChargeType = "string",
DiskId = "string",
DiskType = "string",
Duration = 0,
Name = "string",
RdmaClusterId = "string",
RebootInstanceForResizing = false,
Tag = "string",
});
example, err := ucloud.NewDisk(ctx, "diskResource", &ucloud.DiskArgs{
AvailabilityZone: pulumi.String("string"),
DiskSize: pulumi.Float64(0),
ChargeType: pulumi.String("string"),
DiskId: pulumi.String("string"),
DiskType: pulumi.String("string"),
Duration: pulumi.Float64(0),
Name: pulumi.String("string"),
RdmaClusterId: pulumi.String("string"),
RebootInstanceForResizing: pulumi.Bool(false),
Tag: pulumi.String("string"),
})
var diskResource = new Disk("diskResource", DiskArgs.builder()
.availabilityZone("string")
.diskSize(0)
.chargeType("string")
.diskId("string")
.diskType("string")
.duration(0)
.name("string")
.rdmaClusterId("string")
.rebootInstanceForResizing(false)
.tag("string")
.build());
disk_resource = ucloud.Disk("diskResource",
availability_zone="string",
disk_size=0,
charge_type="string",
disk_id="string",
disk_type="string",
duration=0,
name="string",
rdma_cluster_id="string",
reboot_instance_for_resizing=False,
tag="string")
const diskResource = new ucloud.Disk("diskResource", {
availabilityZone: "string",
diskSize: 0,
chargeType: "string",
diskId: "string",
diskType: "string",
duration: 0,
name: "string",
rdmaClusterId: "string",
rebootInstanceForResizing: false,
tag: "string",
});
type: ucloud:Disk
properties:
availabilityZone: string
chargeType: string
diskId: string
diskSize: 0
diskType: string
duration: 0
name: string
rdmaClusterId: string
rebootInstanceForResizing: false
tag: string
Disk 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 Disk resource accepts the following input properties:
- Availability
Zone string - Availability zone where cloud disk is located. Such as: "cn-bj2-02". You may refer to list of availability zone.
- Disk
Size double - The size of disk. Purchase the size of disk in GB. 20-8000 for a cloud disk, 20-8000 for SSD cloud disk . If the disk have attached to the instance, the instance will reboot automatically to make the change take effect when update the
disk_size
. - Charge
Type string - Charge type of disk. Possible values are:
year
as pay by year,month
as pay by month,dynamic
as pay by hour. (Default:month
). - Disk
Id string - The ID of the resource disk.
- Disk
Type string - The type of disk. Possible values are:
data_disk
as cloud disk,ssd_data_disk
as ssd cloud disk,rssd_data_disk
as RDMA-SSD cloud disk.(Default:data_disk
). - Duration double
- The duration that you will buy the resource. (Default:
1
). It is not required whendynamic
(pay by hour), the value is0
whenmonth
(pay by month) and the disk will be vaild till the last day of that month. - Name string
- Rdma
Cluster stringId - The RDMA Cluster ID of disk. It is mandatory if your disk type is
rssd_data_disk
and must be set to the same value as the UHost instance to attach to. If you don't specifiy this attribute while you are intended to use RSSD, the UHost instance creation has little chance to succeed. So make sure you set this attribute to the value you get from the response of UHost instance creation. For disk type other thanrssd_data_disk
, this attribute is ignored. - Reboot
Instance boolFor Resizing - Whether the attached instance of the disk will be rebooted automatically to make the change take effect when update the
disk_size
. (Default:"true"
). - Tag string
- A tag assigned to VPC, which contains at most 63 characters and only support Chinese, English, numbers, '-', '_', and '.'. If it is not filled in or a empty string is filled in, then default tag will be assigned. (Default:
Default
).
- Availability
Zone string - Availability zone where cloud disk is located. Such as: "cn-bj2-02". You may refer to list of availability zone.
- Disk
Size float64 - The size of disk. Purchase the size of disk in GB. 20-8000 for a cloud disk, 20-8000 for SSD cloud disk . If the disk have attached to the instance, the instance will reboot automatically to make the change take effect when update the
disk_size
. - Charge
Type string - Charge type of disk. Possible values are:
year
as pay by year,month
as pay by month,dynamic
as pay by hour. (Default:month
). - Disk
Id string - The ID of the resource disk.
- Disk
Type string - The type of disk. Possible values are:
data_disk
as cloud disk,ssd_data_disk
as ssd cloud disk,rssd_data_disk
as RDMA-SSD cloud disk.(Default:data_disk
). - Duration float64
- The duration that you will buy the resource. (Default:
1
). It is not required whendynamic
(pay by hour), the value is0
whenmonth
(pay by month) and the disk will be vaild till the last day of that month. - Name string
- Rdma
Cluster stringId - The RDMA Cluster ID of disk. It is mandatory if your disk type is
rssd_data_disk
and must be set to the same value as the UHost instance to attach to. If you don't specifiy this attribute while you are intended to use RSSD, the UHost instance creation has little chance to succeed. So make sure you set this attribute to the value you get from the response of UHost instance creation. For disk type other thanrssd_data_disk
, this attribute is ignored. - Reboot
Instance boolFor Resizing - Whether the attached instance of the disk will be rebooted automatically to make the change take effect when update the
disk_size
. (Default:"true"
). - Tag string
- A tag assigned to VPC, which contains at most 63 characters and only support Chinese, English, numbers, '-', '_', and '.'. If it is not filled in or a empty string is filled in, then default tag will be assigned. (Default:
Default
).
- availability
Zone String - Availability zone where cloud disk is located. Such as: "cn-bj2-02". You may refer to list of availability zone.
- disk
Size Double - The size of disk. Purchase the size of disk in GB. 20-8000 for a cloud disk, 20-8000 for SSD cloud disk . If the disk have attached to the instance, the instance will reboot automatically to make the change take effect when update the
disk_size
. - charge
Type String - Charge type of disk. Possible values are:
year
as pay by year,month
as pay by month,dynamic
as pay by hour. (Default:month
). - disk
Id String - The ID of the resource disk.
- disk
Type String - The type of disk. Possible values are:
data_disk
as cloud disk,ssd_data_disk
as ssd cloud disk,rssd_data_disk
as RDMA-SSD cloud disk.(Default:data_disk
). - duration Double
- The duration that you will buy the resource. (Default:
1
). It is not required whendynamic
(pay by hour), the value is0
whenmonth
(pay by month) and the disk will be vaild till the last day of that month. - name String
- rdma
Cluster StringId - The RDMA Cluster ID of disk. It is mandatory if your disk type is
rssd_data_disk
and must be set to the same value as the UHost instance to attach to. If you don't specifiy this attribute while you are intended to use RSSD, the UHost instance creation has little chance to succeed. So make sure you set this attribute to the value you get from the response of UHost instance creation. For disk type other thanrssd_data_disk
, this attribute is ignored. - reboot
Instance BooleanFor Resizing - Whether the attached instance of the disk will be rebooted automatically to make the change take effect when update the
disk_size
. (Default:"true"
). - tag String
- A tag assigned to VPC, which contains at most 63 characters and only support Chinese, English, numbers, '-', '_', and '.'. If it is not filled in or a empty string is filled in, then default tag will be assigned. (Default:
Default
).
- availability
Zone string - Availability zone where cloud disk is located. Such as: "cn-bj2-02". You may refer to list of availability zone.
- disk
Size number - The size of disk. Purchase the size of disk in GB. 20-8000 for a cloud disk, 20-8000 for SSD cloud disk . If the disk have attached to the instance, the instance will reboot automatically to make the change take effect when update the
disk_size
. - charge
Type string - Charge type of disk. Possible values are:
year
as pay by year,month
as pay by month,dynamic
as pay by hour. (Default:month
). - disk
Id string - The ID of the resource disk.
- disk
Type string - The type of disk. Possible values are:
data_disk
as cloud disk,ssd_data_disk
as ssd cloud disk,rssd_data_disk
as RDMA-SSD cloud disk.(Default:data_disk
). - duration number
- The duration that you will buy the resource. (Default:
1
). It is not required whendynamic
(pay by hour), the value is0
whenmonth
(pay by month) and the disk will be vaild till the last day of that month. - name string
- rdma
Cluster stringId - The RDMA Cluster ID of disk. It is mandatory if your disk type is
rssd_data_disk
and must be set to the same value as the UHost instance to attach to. If you don't specifiy this attribute while you are intended to use RSSD, the UHost instance creation has little chance to succeed. So make sure you set this attribute to the value you get from the response of UHost instance creation. For disk type other thanrssd_data_disk
, this attribute is ignored. - reboot
Instance booleanFor Resizing - Whether the attached instance of the disk will be rebooted automatically to make the change take effect when update the
disk_size
. (Default:"true"
). - tag string
- A tag assigned to VPC, which contains at most 63 characters and only support Chinese, English, numbers, '-', '_', and '.'. If it is not filled in or a empty string is filled in, then default tag will be assigned. (Default:
Default
).
- availability_
zone str - Availability zone where cloud disk is located. Such as: "cn-bj2-02". You may refer to list of availability zone.
- disk_
size float - The size of disk. Purchase the size of disk in GB. 20-8000 for a cloud disk, 20-8000 for SSD cloud disk . If the disk have attached to the instance, the instance will reboot automatically to make the change take effect when update the
disk_size
. - charge_
type str - Charge type of disk. Possible values are:
year
as pay by year,month
as pay by month,dynamic
as pay by hour. (Default:month
). - disk_
id str - The ID of the resource disk.
- disk_
type str - The type of disk. Possible values are:
data_disk
as cloud disk,ssd_data_disk
as ssd cloud disk,rssd_data_disk
as RDMA-SSD cloud disk.(Default:data_disk
). - duration float
- The duration that you will buy the resource. (Default:
1
). It is not required whendynamic
(pay by hour), the value is0
whenmonth
(pay by month) and the disk will be vaild till the last day of that month. - name str
- rdma_
cluster_ strid - The RDMA Cluster ID of disk. It is mandatory if your disk type is
rssd_data_disk
and must be set to the same value as the UHost instance to attach to. If you don't specifiy this attribute while you are intended to use RSSD, the UHost instance creation has little chance to succeed. So make sure you set this attribute to the value you get from the response of UHost instance creation. For disk type other thanrssd_data_disk
, this attribute is ignored. - reboot_
instance_ boolfor_ resizing - Whether the attached instance of the disk will be rebooted automatically to make the change take effect when update the
disk_size
. (Default:"true"
). - tag str
- A tag assigned to VPC, which contains at most 63 characters and only support Chinese, English, numbers, '-', '_', and '.'. If it is not filled in or a empty string is filled in, then default tag will be assigned. (Default:
Default
).
- availability
Zone String - Availability zone where cloud disk is located. Such as: "cn-bj2-02". You may refer to list of availability zone.
- disk
Size Number - The size of disk. Purchase the size of disk in GB. 20-8000 for a cloud disk, 20-8000 for SSD cloud disk . If the disk have attached to the instance, the instance will reboot automatically to make the change take effect when update the
disk_size
. - charge
Type String - Charge type of disk. Possible values are:
year
as pay by year,month
as pay by month,dynamic
as pay by hour. (Default:month
). - disk
Id String - The ID of the resource disk.
- disk
Type String - The type of disk. Possible values are:
data_disk
as cloud disk,ssd_data_disk
as ssd cloud disk,rssd_data_disk
as RDMA-SSD cloud disk.(Default:data_disk
). - duration Number
- The duration that you will buy the resource. (Default:
1
). It is not required whendynamic
(pay by hour), the value is0
whenmonth
(pay by month) and the disk will be vaild till the last day of that month. - name String
- rdma
Cluster StringId - The RDMA Cluster ID of disk. It is mandatory if your disk type is
rssd_data_disk
and must be set to the same value as the UHost instance to attach to. If you don't specifiy this attribute while you are intended to use RSSD, the UHost instance creation has little chance to succeed. So make sure you set this attribute to the value you get from the response of UHost instance creation. For disk type other thanrssd_data_disk
, this attribute is ignored. - reboot
Instance BooleanFor Resizing - Whether the attached instance of the disk will be rebooted automatically to make the change take effect when update the
disk_size
. (Default:"true"
). - tag String
- A tag assigned to VPC, which contains at most 63 characters and only support Chinese, English, numbers, '-', '_', and '.'. If it is not filled in or a empty string is filled in, then default tag will be assigned. (Default:
Default
).
Outputs
All input properties are implicitly available as output properties. Additionally, the Disk resource produces the following output properties:
- Create
Time string - The time of creation of disk, formatted in RFC3339 time string.
- Expire
Time string - The expiration time of disk, formatted in RFC3339 time string.
- Id string
- The provider-assigned unique ID for this managed resource.
- Status string
- The status of disk. Possible values are:
Available
,InUse
,Detaching
,Initializating
,Failed
,Cloning
,Restoring
,RestoreFailed
.
- Create
Time string - The time of creation of disk, formatted in RFC3339 time string.
- Expire
Time string - The expiration time of disk, formatted in RFC3339 time string.
- Id string
- The provider-assigned unique ID for this managed resource.
- Status string
- The status of disk. Possible values are:
Available
,InUse
,Detaching
,Initializating
,Failed
,Cloning
,Restoring
,RestoreFailed
.
- create
Time String - The time of creation of disk, formatted in RFC3339 time string.
- expire
Time String - The expiration time of disk, formatted in RFC3339 time string.
- id String
- The provider-assigned unique ID for this managed resource.
- status String
- The status of disk. Possible values are:
Available
,InUse
,Detaching
,Initializating
,Failed
,Cloning
,Restoring
,RestoreFailed
.
- create
Time string - The time of creation of disk, formatted in RFC3339 time string.
- expire
Time string - The expiration time of disk, formatted in RFC3339 time string.
- id string
- The provider-assigned unique ID for this managed resource.
- status string
- The status of disk. Possible values are:
Available
,InUse
,Detaching
,Initializating
,Failed
,Cloning
,Restoring
,RestoreFailed
.
- create_
time str - The time of creation of disk, formatted in RFC3339 time string.
- expire_
time str - The expiration time of disk, formatted in RFC3339 time string.
- id str
- The provider-assigned unique ID for this managed resource.
- status str
- The status of disk. Possible values are:
Available
,InUse
,Detaching
,Initializating
,Failed
,Cloning
,Restoring
,RestoreFailed
.
- create
Time String - The time of creation of disk, formatted in RFC3339 time string.
- expire
Time String - The expiration time of disk, formatted in RFC3339 time string.
- id String
- The provider-assigned unique ID for this managed resource.
- status String
- The status of disk. Possible values are:
Available
,InUse
,Detaching
,Initializating
,Failed
,Cloning
,Restoring
,RestoreFailed
.
Look up Existing Disk Resource
Get an existing Disk 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?: DiskState, opts?: CustomResourceOptions): Disk
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
availability_zone: Optional[str] = None,
charge_type: Optional[str] = None,
create_time: Optional[str] = None,
disk_id: Optional[str] = None,
disk_size: Optional[float] = None,
disk_type: Optional[str] = None,
duration: Optional[float] = None,
expire_time: Optional[str] = None,
name: Optional[str] = None,
rdma_cluster_id: Optional[str] = None,
reboot_instance_for_resizing: Optional[bool] = None,
status: Optional[str] = None,
tag: Optional[str] = None) -> Disk
func GetDisk(ctx *Context, name string, id IDInput, state *DiskState, opts ...ResourceOption) (*Disk, error)
public static Disk Get(string name, Input<string> id, DiskState? state, CustomResourceOptions? opts = null)
public static Disk get(String name, Output<String> id, DiskState state, CustomResourceOptions options)
resources: _: type: ucloud:Disk 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.
- Availability
Zone string - Availability zone where cloud disk is located. Such as: "cn-bj2-02". You may refer to list of availability zone.
- Charge
Type string - Charge type of disk. Possible values are:
year
as pay by year,month
as pay by month,dynamic
as pay by hour. (Default:month
). - Create
Time string - The time of creation of disk, formatted in RFC3339 time string.
- Disk
Id string - The ID of the resource disk.
- Disk
Size double - The size of disk. Purchase the size of disk in GB. 20-8000 for a cloud disk, 20-8000 for SSD cloud disk . If the disk have attached to the instance, the instance will reboot automatically to make the change take effect when update the
disk_size
. - Disk
Type string - The type of disk. Possible values are:
data_disk
as cloud disk,ssd_data_disk
as ssd cloud disk,rssd_data_disk
as RDMA-SSD cloud disk.(Default:data_disk
). - Duration double
- The duration that you will buy the resource. (Default:
1
). It is not required whendynamic
(pay by hour), the value is0
whenmonth
(pay by month) and the disk will be vaild till the last day of that month. - Expire
Time string - The expiration time of disk, formatted in RFC3339 time string.
- Name string
- Rdma
Cluster stringId - The RDMA Cluster ID of disk. It is mandatory if your disk type is
rssd_data_disk
and must be set to the same value as the UHost instance to attach to. If you don't specifiy this attribute while you are intended to use RSSD, the UHost instance creation has little chance to succeed. So make sure you set this attribute to the value you get from the response of UHost instance creation. For disk type other thanrssd_data_disk
, this attribute is ignored. - Reboot
Instance boolFor Resizing - Whether the attached instance of the disk will be rebooted automatically to make the change take effect when update the
disk_size
. (Default:"true"
). - Status string
- The status of disk. Possible values are:
Available
,InUse
,Detaching
,Initializating
,Failed
,Cloning
,Restoring
,RestoreFailed
. - Tag string
- A tag assigned to VPC, which contains at most 63 characters and only support Chinese, English, numbers, '-', '_', and '.'. If it is not filled in or a empty string is filled in, then default tag will be assigned. (Default:
Default
).
- Availability
Zone string - Availability zone where cloud disk is located. Such as: "cn-bj2-02". You may refer to list of availability zone.
- Charge
Type string - Charge type of disk. Possible values are:
year
as pay by year,month
as pay by month,dynamic
as pay by hour. (Default:month
). - Create
Time string - The time of creation of disk, formatted in RFC3339 time string.
- Disk
Id string - The ID of the resource disk.
- Disk
Size float64 - The size of disk. Purchase the size of disk in GB. 20-8000 for a cloud disk, 20-8000 for SSD cloud disk . If the disk have attached to the instance, the instance will reboot automatically to make the change take effect when update the
disk_size
. - Disk
Type string - The type of disk. Possible values are:
data_disk
as cloud disk,ssd_data_disk
as ssd cloud disk,rssd_data_disk
as RDMA-SSD cloud disk.(Default:data_disk
). - Duration float64
- The duration that you will buy the resource. (Default:
1
). It is not required whendynamic
(pay by hour), the value is0
whenmonth
(pay by month) and the disk will be vaild till the last day of that month. - Expire
Time string - The expiration time of disk, formatted in RFC3339 time string.
- Name string
- Rdma
Cluster stringId - The RDMA Cluster ID of disk. It is mandatory if your disk type is
rssd_data_disk
and must be set to the same value as the UHost instance to attach to. If you don't specifiy this attribute while you are intended to use RSSD, the UHost instance creation has little chance to succeed. So make sure you set this attribute to the value you get from the response of UHost instance creation. For disk type other thanrssd_data_disk
, this attribute is ignored. - Reboot
Instance boolFor Resizing - Whether the attached instance of the disk will be rebooted automatically to make the change take effect when update the
disk_size
. (Default:"true"
). - Status string
- The status of disk. Possible values are:
Available
,InUse
,Detaching
,Initializating
,Failed
,Cloning
,Restoring
,RestoreFailed
. - Tag string
- A tag assigned to VPC, which contains at most 63 characters and only support Chinese, English, numbers, '-', '_', and '.'. If it is not filled in or a empty string is filled in, then default tag will be assigned. (Default:
Default
).
- availability
Zone String - Availability zone where cloud disk is located. Such as: "cn-bj2-02". You may refer to list of availability zone.
- charge
Type String - Charge type of disk. Possible values are:
year
as pay by year,month
as pay by month,dynamic
as pay by hour. (Default:month
). - create
Time String - The time of creation of disk, formatted in RFC3339 time string.
- disk
Id String - The ID of the resource disk.
- disk
Size Double - The size of disk. Purchase the size of disk in GB. 20-8000 for a cloud disk, 20-8000 for SSD cloud disk . If the disk have attached to the instance, the instance will reboot automatically to make the change take effect when update the
disk_size
. - disk
Type String - The type of disk. Possible values are:
data_disk
as cloud disk,ssd_data_disk
as ssd cloud disk,rssd_data_disk
as RDMA-SSD cloud disk.(Default:data_disk
). - duration Double
- The duration that you will buy the resource. (Default:
1
). It is not required whendynamic
(pay by hour), the value is0
whenmonth
(pay by month) and the disk will be vaild till the last day of that month. - expire
Time String - The expiration time of disk, formatted in RFC3339 time string.
- name String
- rdma
Cluster StringId - The RDMA Cluster ID of disk. It is mandatory if your disk type is
rssd_data_disk
and must be set to the same value as the UHost instance to attach to. If you don't specifiy this attribute while you are intended to use RSSD, the UHost instance creation has little chance to succeed. So make sure you set this attribute to the value you get from the response of UHost instance creation. For disk type other thanrssd_data_disk
, this attribute is ignored. - reboot
Instance BooleanFor Resizing - Whether the attached instance of the disk will be rebooted automatically to make the change take effect when update the
disk_size
. (Default:"true"
). - status String
- The status of disk. Possible values are:
Available
,InUse
,Detaching
,Initializating
,Failed
,Cloning
,Restoring
,RestoreFailed
. - tag String
- A tag assigned to VPC, which contains at most 63 characters and only support Chinese, English, numbers, '-', '_', and '.'. If it is not filled in or a empty string is filled in, then default tag will be assigned. (Default:
Default
).
- availability
Zone string - Availability zone where cloud disk is located. Such as: "cn-bj2-02". You may refer to list of availability zone.
- charge
Type string - Charge type of disk. Possible values are:
year
as pay by year,month
as pay by month,dynamic
as pay by hour. (Default:month
). - create
Time string - The time of creation of disk, formatted in RFC3339 time string.
- disk
Id string - The ID of the resource disk.
- disk
Size number - The size of disk. Purchase the size of disk in GB. 20-8000 for a cloud disk, 20-8000 for SSD cloud disk . If the disk have attached to the instance, the instance will reboot automatically to make the change take effect when update the
disk_size
. - disk
Type string - The type of disk. Possible values are:
data_disk
as cloud disk,ssd_data_disk
as ssd cloud disk,rssd_data_disk
as RDMA-SSD cloud disk.(Default:data_disk
). - duration number
- The duration that you will buy the resource. (Default:
1
). It is not required whendynamic
(pay by hour), the value is0
whenmonth
(pay by month) and the disk will be vaild till the last day of that month. - expire
Time string - The expiration time of disk, formatted in RFC3339 time string.
- name string
- rdma
Cluster stringId - The RDMA Cluster ID of disk. It is mandatory if your disk type is
rssd_data_disk
and must be set to the same value as the UHost instance to attach to. If you don't specifiy this attribute while you are intended to use RSSD, the UHost instance creation has little chance to succeed. So make sure you set this attribute to the value you get from the response of UHost instance creation. For disk type other thanrssd_data_disk
, this attribute is ignored. - reboot
Instance booleanFor Resizing - Whether the attached instance of the disk will be rebooted automatically to make the change take effect when update the
disk_size
. (Default:"true"
). - status string
- The status of disk. Possible values are:
Available
,InUse
,Detaching
,Initializating
,Failed
,Cloning
,Restoring
,RestoreFailed
. - tag string
- A tag assigned to VPC, which contains at most 63 characters and only support Chinese, English, numbers, '-', '_', and '.'. If it is not filled in or a empty string is filled in, then default tag will be assigned. (Default:
Default
).
- availability_
zone str - Availability zone where cloud disk is located. Such as: "cn-bj2-02". You may refer to list of availability zone.
- charge_
type str - Charge type of disk. Possible values are:
year
as pay by year,month
as pay by month,dynamic
as pay by hour. (Default:month
). - create_
time str - The time of creation of disk, formatted in RFC3339 time string.
- disk_
id str - The ID of the resource disk.
- disk_
size float - The size of disk. Purchase the size of disk in GB. 20-8000 for a cloud disk, 20-8000 for SSD cloud disk . If the disk have attached to the instance, the instance will reboot automatically to make the change take effect when update the
disk_size
. - disk_
type str - The type of disk. Possible values are:
data_disk
as cloud disk,ssd_data_disk
as ssd cloud disk,rssd_data_disk
as RDMA-SSD cloud disk.(Default:data_disk
). - duration float
- The duration that you will buy the resource. (Default:
1
). It is not required whendynamic
(pay by hour), the value is0
whenmonth
(pay by month) and the disk will be vaild till the last day of that month. - expire_
time str - The expiration time of disk, formatted in RFC3339 time string.
- name str
- rdma_
cluster_ strid - The RDMA Cluster ID of disk. It is mandatory if your disk type is
rssd_data_disk
and must be set to the same value as the UHost instance to attach to. If you don't specifiy this attribute while you are intended to use RSSD, the UHost instance creation has little chance to succeed. So make sure you set this attribute to the value you get from the response of UHost instance creation. For disk type other thanrssd_data_disk
, this attribute is ignored. - reboot_
instance_ boolfor_ resizing - Whether the attached instance of the disk will be rebooted automatically to make the change take effect when update the
disk_size
. (Default:"true"
). - status str
- The status of disk. Possible values are:
Available
,InUse
,Detaching
,Initializating
,Failed
,Cloning
,Restoring
,RestoreFailed
. - tag str
- A tag assigned to VPC, which contains at most 63 characters and only support Chinese, English, numbers, '-', '_', and '.'. If it is not filled in or a empty string is filled in, then default tag will be assigned. (Default:
Default
).
- availability
Zone String - Availability zone where cloud disk is located. Such as: "cn-bj2-02". You may refer to list of availability zone.
- charge
Type String - Charge type of disk. Possible values are:
year
as pay by year,month
as pay by month,dynamic
as pay by hour. (Default:month
). - create
Time String - The time of creation of disk, formatted in RFC3339 time string.
- disk
Id String - The ID of the resource disk.
- disk
Size Number - The size of disk. Purchase the size of disk in GB. 20-8000 for a cloud disk, 20-8000 for SSD cloud disk . If the disk have attached to the instance, the instance will reboot automatically to make the change take effect when update the
disk_size
. - disk
Type String - The type of disk. Possible values are:
data_disk
as cloud disk,ssd_data_disk
as ssd cloud disk,rssd_data_disk
as RDMA-SSD cloud disk.(Default:data_disk
). - duration Number
- The duration that you will buy the resource. (Default:
1
). It is not required whendynamic
(pay by hour), the value is0
whenmonth
(pay by month) and the disk will be vaild till the last day of that month. - expire
Time String - The expiration time of disk, formatted in RFC3339 time string.
- name String
- rdma
Cluster StringId - The RDMA Cluster ID of disk. It is mandatory if your disk type is
rssd_data_disk
and must be set to the same value as the UHost instance to attach to. If you don't specifiy this attribute while you are intended to use RSSD, the UHost instance creation has little chance to succeed. So make sure you set this attribute to the value you get from the response of UHost instance creation. For disk type other thanrssd_data_disk
, this attribute is ignored. - reboot
Instance BooleanFor Resizing - Whether the attached instance of the disk will be rebooted automatically to make the change take effect when update the
disk_size
. (Default:"true"
). - status String
- The status of disk. Possible values are:
Available
,InUse
,Detaching
,Initializating
,Failed
,Cloning
,Restoring
,RestoreFailed
. - tag String
- A tag assigned to VPC, which contains at most 63 characters and only support Chinese, English, numbers, '-', '_', and '.'. If it is not filled in or a empty string is filled in, then default tag will be assigned. (Default:
Default
).
Import
Disk can be imported using the id
, e.g.
$ pulumi import ucloud:index/disk:Disk example bsm-abcdefg
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- ucloud ucloud/terraform-provider-ucloud
- License
- Notes
- This Pulumi package is based on the
ucloud
Terraform Provider.