alicloud.ecs.DedicatedHost
Explore with Pulumi AI
Import
Ecs dedicated host can be imported using the id, e.g.
$ pulumi import alicloud:ecs/dedicatedHost:DedicatedHost default dh-2zedmxxxx
Create DedicatedHost Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new DedicatedHost(name: string, args: DedicatedHostArgs, opts?: CustomResourceOptions);
@overload
def DedicatedHost(resource_name: str,
args: DedicatedHostArgs,
opts: Optional[ResourceOptions] = None)
@overload
def DedicatedHost(resource_name: str,
opts: Optional[ResourceOptions] = None,
dedicated_host_type: Optional[str] = None,
detail_fee: Optional[bool] = None,
zone_id: Optional[str] = None,
description: Optional[str] = None,
auto_renew_period: Optional[int] = None,
cpu_over_commit_ratio: Optional[float] = None,
dedicated_host_cluster_id: Optional[str] = None,
dedicated_host_name: Optional[str] = None,
auto_placement: Optional[str] = None,
auto_renew: Optional[bool] = None,
auto_release_time: Optional[str] = None,
expired_time: Optional[str] = None,
dry_run: Optional[bool] = None,
min_quantity: Optional[int] = None,
network_attributes: Optional[Sequence[DedicatedHostNetworkAttributeArgs]] = None,
payment_type: Optional[str] = None,
resource_group_id: Optional[str] = None,
sale_cycle: Optional[str] = None,
tags: Optional[Mapping[str, str]] = None,
action_on_maintenance: Optional[str] = None)
func NewDedicatedHost(ctx *Context, name string, args DedicatedHostArgs, opts ...ResourceOption) (*DedicatedHost, error)
public DedicatedHost(string name, DedicatedHostArgs args, CustomResourceOptions? opts = null)
public DedicatedHost(String name, DedicatedHostArgs args)
public DedicatedHost(String name, DedicatedHostArgs args, CustomResourceOptions options)
type: alicloud:ecs:DedicatedHost
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 DedicatedHostArgs
- 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 DedicatedHostArgs
- 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 DedicatedHostArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args DedicatedHostArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args DedicatedHostArgs
- 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 alicloudDedicatedHostResource = new AliCloud.Ecs.DedicatedHost("alicloudDedicatedHostResource", new()
{
DedicatedHostType = "string",
DetailFee = false,
ZoneId = "string",
Description = "string",
AutoRenewPeriod = 0,
CpuOverCommitRatio = 0,
DedicatedHostClusterId = "string",
DedicatedHostName = "string",
AutoPlacement = "string",
AutoRenew = false,
AutoReleaseTime = "string",
ExpiredTime = "string",
DryRun = false,
MinQuantity = 0,
NetworkAttributes = new[]
{
new AliCloud.Ecs.Inputs.DedicatedHostNetworkAttributeArgs
{
SlbUdpTimeout = 0,
UdpTimeout = 0,
},
},
PaymentType = "string",
ResourceGroupId = "string",
SaleCycle = "string",
Tags =
{
{ "string", "string" },
},
ActionOnMaintenance = "string",
});
example, err := ecs.NewDedicatedHost(ctx, "alicloudDedicatedHostResource", &ecs.DedicatedHostArgs{
DedicatedHostType: pulumi.String("string"),
DetailFee: pulumi.Bool(false),
ZoneId: pulumi.String("string"),
Description: pulumi.String("string"),
AutoRenewPeriod: pulumi.Int(0),
CpuOverCommitRatio: pulumi.Float64(0),
DedicatedHostClusterId: pulumi.String("string"),
DedicatedHostName: pulumi.String("string"),
AutoPlacement: pulumi.String("string"),
AutoRenew: pulumi.Bool(false),
AutoReleaseTime: pulumi.String("string"),
ExpiredTime: pulumi.String("string"),
DryRun: pulumi.Bool(false),
MinQuantity: pulumi.Int(0),
NetworkAttributes: ecs.DedicatedHostNetworkAttributeArray{
&ecs.DedicatedHostNetworkAttributeArgs{
SlbUdpTimeout: pulumi.Int(0),
UdpTimeout: pulumi.Int(0),
},
},
PaymentType: pulumi.String("string"),
ResourceGroupId: pulumi.String("string"),
SaleCycle: pulumi.String("string"),
Tags: pulumi.StringMap{
"string": pulumi.String("string"),
},
ActionOnMaintenance: pulumi.String("string"),
})
var alicloudDedicatedHostResource = new DedicatedHost("alicloudDedicatedHostResource", DedicatedHostArgs.builder()
.dedicatedHostType("string")
.detailFee(false)
.zoneId("string")
.description("string")
.autoRenewPeriod(0)
.cpuOverCommitRatio(0)
.dedicatedHostClusterId("string")
.dedicatedHostName("string")
.autoPlacement("string")
.autoRenew(false)
.autoReleaseTime("string")
.expiredTime("string")
.dryRun(false)
.minQuantity(0)
.networkAttributes(DedicatedHostNetworkAttributeArgs.builder()
.slbUdpTimeout(0)
.udpTimeout(0)
.build())
.paymentType("string")
.resourceGroupId("string")
.saleCycle("string")
.tags(Map.of("string", "string"))
.actionOnMaintenance("string")
.build());
alicloud_dedicated_host_resource = alicloud.ecs.DedicatedHost("alicloudDedicatedHostResource",
dedicated_host_type="string",
detail_fee=False,
zone_id="string",
description="string",
auto_renew_period=0,
cpu_over_commit_ratio=0,
dedicated_host_cluster_id="string",
dedicated_host_name="string",
auto_placement="string",
auto_renew=False,
auto_release_time="string",
expired_time="string",
dry_run=False,
min_quantity=0,
network_attributes=[{
"slb_udp_timeout": 0,
"udp_timeout": 0,
}],
payment_type="string",
resource_group_id="string",
sale_cycle="string",
tags={
"string": "string",
},
action_on_maintenance="string")
const alicloudDedicatedHostResource = new alicloud.ecs.DedicatedHost("alicloudDedicatedHostResource", {
dedicatedHostType: "string",
detailFee: false,
zoneId: "string",
description: "string",
autoRenewPeriod: 0,
cpuOverCommitRatio: 0,
dedicatedHostClusterId: "string",
dedicatedHostName: "string",
autoPlacement: "string",
autoRenew: false,
autoReleaseTime: "string",
expiredTime: "string",
dryRun: false,
minQuantity: 0,
networkAttributes: [{
slbUdpTimeout: 0,
udpTimeout: 0,
}],
paymentType: "string",
resourceGroupId: "string",
saleCycle: "string",
tags: {
string: "string",
},
actionOnMaintenance: "string",
});
type: alicloud:ecs:DedicatedHost
properties:
actionOnMaintenance: string
autoPlacement: string
autoReleaseTime: string
autoRenew: false
autoRenewPeriod: 0
cpuOverCommitRatio: 0
dedicatedHostClusterId: string
dedicatedHostName: string
dedicatedHostType: string
description: string
detailFee: false
dryRun: false
expiredTime: string
minQuantity: 0
networkAttributes:
- slbUdpTimeout: 0
udpTimeout: 0
paymentType: string
resourceGroupId: string
saleCycle: string
tags:
string: string
zoneId: string
DedicatedHost 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 DedicatedHost resource accepts the following input properties:
- Dedicated
Host stringType - The type of the dedicated host. You can call the DescribeDedicatedHostTypes operation to obtain the most recent list of dedicated host types.
- Action
On stringMaintenance - The policy used to migrate the instances from the dedicated host when the dedicated host fails or needs to be repaired online. Valid values:
Migrate
,Stop
. - Auto
Placement string - Specifies whether to add the dedicated host to the resource pool for automatic deployment. If you do not specify the DedicatedHostId parameter when you create an instance on a dedicated host, Alibaba Cloud automatically selects a dedicated host from the resource pool to host the instance. Valid values:
on
,off
. Default:on
. - Auto
Release stringTime - The automatic release time of the dedicated host. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC+0.
- Auto
Renew bool - Specifies whether to automatically renew the subscription dedicated host.
- Auto
Renew intPeriod - The auto-renewal period of the dedicated host. Unit: months. Valid values:
1
,2
,3
,6
, and12
. takes effect and is required only when the AutoRenew parameter is set to true. - Cpu
Over doubleCommit Ratio - CPU oversold ratio. Only custom specifications g6s, c6s, r6s support setting the CPU oversold ratio.
- Dedicated
Host stringCluster Id - The dedicated host cluster ID to which the dedicated host belongs.
- Dedicated
Host stringName - The name of the dedicated host. The name must be 2 to 128 characters in length. It must start with a letter but cannot start with http:// or https://. It can contain letters, digits, colons (:), underscores (_), and hyphens (-).
- Description string
- The description of the dedicated host. The description must be 2 to 256 characters in length and cannot start with http:// or https://.
- Detail
Fee bool - Specifies whether to return the billing details of the order when the billing method is changed from subscription to pay-as-you-go. Default:
false
. - Dry
Run bool - Specifies whether to only validate the request. Default:
false
. - Expired
Time string - The subscription period of the dedicated host. The Period parameter takes effect and is required only when the ChargeType parameter is set to PrePaid.
- Min
Quantity int - Specify the minimum purchase quantity of a dedicated host.
- Network
Attributes List<Pulumi.Ali Cloud. Ecs. Inputs. Dedicated Host Network Attribute> - dedicated host network parameters. contains the following attributes:
- Payment
Type string - The billing method of the dedicated host. Valid values:
PrePaid
,PostPaid
. Default:PostPaid
. - Resource
Group stringId - The ID of the resource group to which the dedicated host belongs.
- Sale
Cycle string - The unit of the subscription period of the dedicated host.
- Dictionary<string, string>
- A mapping of tags to assign to the resource.
- Zone
Id string - The zone ID of the dedicated host. This parameter is empty by default. If you do not specify this parameter, the system automatically selects a zone.
- Dedicated
Host stringType - The type of the dedicated host. You can call the DescribeDedicatedHostTypes operation to obtain the most recent list of dedicated host types.
- Action
On stringMaintenance - The policy used to migrate the instances from the dedicated host when the dedicated host fails or needs to be repaired online. Valid values:
Migrate
,Stop
. - Auto
Placement string - Specifies whether to add the dedicated host to the resource pool for automatic deployment. If you do not specify the DedicatedHostId parameter when you create an instance on a dedicated host, Alibaba Cloud automatically selects a dedicated host from the resource pool to host the instance. Valid values:
on
,off
. Default:on
. - Auto
Release stringTime - The automatic release time of the dedicated host. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC+0.
- Auto
Renew bool - Specifies whether to automatically renew the subscription dedicated host.
- Auto
Renew intPeriod - The auto-renewal period of the dedicated host. Unit: months. Valid values:
1
,2
,3
,6
, and12
. takes effect and is required only when the AutoRenew parameter is set to true. - Cpu
Over float64Commit Ratio - CPU oversold ratio. Only custom specifications g6s, c6s, r6s support setting the CPU oversold ratio.
- Dedicated
Host stringCluster Id - The dedicated host cluster ID to which the dedicated host belongs.
- Dedicated
Host stringName - The name of the dedicated host. The name must be 2 to 128 characters in length. It must start with a letter but cannot start with http:// or https://. It can contain letters, digits, colons (:), underscores (_), and hyphens (-).
- Description string
- The description of the dedicated host. The description must be 2 to 256 characters in length and cannot start with http:// or https://.
- Detail
Fee bool - Specifies whether to return the billing details of the order when the billing method is changed from subscription to pay-as-you-go. Default:
false
. - Dry
Run bool - Specifies whether to only validate the request. Default:
false
. - Expired
Time string - The subscription period of the dedicated host. The Period parameter takes effect and is required only when the ChargeType parameter is set to PrePaid.
- Min
Quantity int - Specify the minimum purchase quantity of a dedicated host.
- Network
Attributes []DedicatedHost Network Attribute Args - dedicated host network parameters. contains the following attributes:
- Payment
Type string - The billing method of the dedicated host. Valid values:
PrePaid
,PostPaid
. Default:PostPaid
. - Resource
Group stringId - The ID of the resource group to which the dedicated host belongs.
- Sale
Cycle string - The unit of the subscription period of the dedicated host.
- map[string]string
- A mapping of tags to assign to the resource.
- Zone
Id string - The zone ID of the dedicated host. This parameter is empty by default. If you do not specify this parameter, the system automatically selects a zone.
- dedicated
Host StringType - The type of the dedicated host. You can call the DescribeDedicatedHostTypes operation to obtain the most recent list of dedicated host types.
- action
On StringMaintenance - The policy used to migrate the instances from the dedicated host when the dedicated host fails or needs to be repaired online. Valid values:
Migrate
,Stop
. - auto
Placement String - Specifies whether to add the dedicated host to the resource pool for automatic deployment. If you do not specify the DedicatedHostId parameter when you create an instance on a dedicated host, Alibaba Cloud automatically selects a dedicated host from the resource pool to host the instance. Valid values:
on
,off
. Default:on
. - auto
Release StringTime - The automatic release time of the dedicated host. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC+0.
- auto
Renew Boolean - Specifies whether to automatically renew the subscription dedicated host.
- auto
Renew IntegerPeriod - The auto-renewal period of the dedicated host. Unit: months. Valid values:
1
,2
,3
,6
, and12
. takes effect and is required only when the AutoRenew parameter is set to true. - cpu
Over DoubleCommit Ratio - CPU oversold ratio. Only custom specifications g6s, c6s, r6s support setting the CPU oversold ratio.
- dedicated
Host StringCluster Id - The dedicated host cluster ID to which the dedicated host belongs.
- dedicated
Host StringName - The name of the dedicated host. The name must be 2 to 128 characters in length. It must start with a letter but cannot start with http:// or https://. It can contain letters, digits, colons (:), underscores (_), and hyphens (-).
- description String
- The description of the dedicated host. The description must be 2 to 256 characters in length and cannot start with http:// or https://.
- detail
Fee Boolean - Specifies whether to return the billing details of the order when the billing method is changed from subscription to pay-as-you-go. Default:
false
. - dry
Run Boolean - Specifies whether to only validate the request. Default:
false
. - expired
Time String - The subscription period of the dedicated host. The Period parameter takes effect and is required only when the ChargeType parameter is set to PrePaid.
- min
Quantity Integer - Specify the minimum purchase quantity of a dedicated host.
- network
Attributes List<DedicatedHost Network Attribute> - dedicated host network parameters. contains the following attributes:
- payment
Type String - The billing method of the dedicated host. Valid values:
PrePaid
,PostPaid
. Default:PostPaid
. - resource
Group StringId - The ID of the resource group to which the dedicated host belongs.
- sale
Cycle String - The unit of the subscription period of the dedicated host.
- Map<String,String>
- A mapping of tags to assign to the resource.
- zone
Id String - The zone ID of the dedicated host. This parameter is empty by default. If you do not specify this parameter, the system automatically selects a zone.
- dedicated
Host stringType - The type of the dedicated host. You can call the DescribeDedicatedHostTypes operation to obtain the most recent list of dedicated host types.
- action
On stringMaintenance - The policy used to migrate the instances from the dedicated host when the dedicated host fails or needs to be repaired online. Valid values:
Migrate
,Stop
. - auto
Placement string - Specifies whether to add the dedicated host to the resource pool for automatic deployment. If you do not specify the DedicatedHostId parameter when you create an instance on a dedicated host, Alibaba Cloud automatically selects a dedicated host from the resource pool to host the instance. Valid values:
on
,off
. Default:on
. - auto
Release stringTime - The automatic release time of the dedicated host. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC+0.
- auto
Renew boolean - Specifies whether to automatically renew the subscription dedicated host.
- auto
Renew numberPeriod - The auto-renewal period of the dedicated host. Unit: months. Valid values:
1
,2
,3
,6
, and12
. takes effect and is required only when the AutoRenew parameter is set to true. - cpu
Over numberCommit Ratio - CPU oversold ratio. Only custom specifications g6s, c6s, r6s support setting the CPU oversold ratio.
- dedicated
Host stringCluster Id - The dedicated host cluster ID to which the dedicated host belongs.
- dedicated
Host stringName - The name of the dedicated host. The name must be 2 to 128 characters in length. It must start with a letter but cannot start with http:// or https://. It can contain letters, digits, colons (:), underscores (_), and hyphens (-).
- description string
- The description of the dedicated host. The description must be 2 to 256 characters in length and cannot start with http:// or https://.
- detail
Fee boolean - Specifies whether to return the billing details of the order when the billing method is changed from subscription to pay-as-you-go. Default:
false
. - dry
Run boolean - Specifies whether to only validate the request. Default:
false
. - expired
Time string - The subscription period of the dedicated host. The Period parameter takes effect and is required only when the ChargeType parameter is set to PrePaid.
- min
Quantity number - Specify the minimum purchase quantity of a dedicated host.
- network
Attributes DedicatedHost Network Attribute[] - dedicated host network parameters. contains the following attributes:
- payment
Type string - The billing method of the dedicated host. Valid values:
PrePaid
,PostPaid
. Default:PostPaid
. - resource
Group stringId - The ID of the resource group to which the dedicated host belongs.
- sale
Cycle string - The unit of the subscription period of the dedicated host.
- {[key: string]: string}
- A mapping of tags to assign to the resource.
- zone
Id string - The zone ID of the dedicated host. This parameter is empty by default. If you do not specify this parameter, the system automatically selects a zone.
- dedicated_
host_ strtype - The type of the dedicated host. You can call the DescribeDedicatedHostTypes operation to obtain the most recent list of dedicated host types.
- action_
on_ strmaintenance - The policy used to migrate the instances from the dedicated host when the dedicated host fails or needs to be repaired online. Valid values:
Migrate
,Stop
. - auto_
placement str - Specifies whether to add the dedicated host to the resource pool for automatic deployment. If you do not specify the DedicatedHostId parameter when you create an instance on a dedicated host, Alibaba Cloud automatically selects a dedicated host from the resource pool to host the instance. Valid values:
on
,off
. Default:on
. - auto_
release_ strtime - The automatic release time of the dedicated host. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC+0.
- auto_
renew bool - Specifies whether to automatically renew the subscription dedicated host.
- auto_
renew_ intperiod - The auto-renewal period of the dedicated host. Unit: months. Valid values:
1
,2
,3
,6
, and12
. takes effect and is required only when the AutoRenew parameter is set to true. - cpu_
over_ floatcommit_ ratio - CPU oversold ratio. Only custom specifications g6s, c6s, r6s support setting the CPU oversold ratio.
- dedicated_
host_ strcluster_ id - The dedicated host cluster ID to which the dedicated host belongs.
- dedicated_
host_ strname - The name of the dedicated host. The name must be 2 to 128 characters in length. It must start with a letter but cannot start with http:// or https://. It can contain letters, digits, colons (:), underscores (_), and hyphens (-).
- description str
- The description of the dedicated host. The description must be 2 to 256 characters in length and cannot start with http:// or https://.
- detail_
fee bool - Specifies whether to return the billing details of the order when the billing method is changed from subscription to pay-as-you-go. Default:
false
. - dry_
run bool - Specifies whether to only validate the request. Default:
false
. - expired_
time str - The subscription period of the dedicated host. The Period parameter takes effect and is required only when the ChargeType parameter is set to PrePaid.
- min_
quantity int - Specify the minimum purchase quantity of a dedicated host.
- network_
attributes Sequence[DedicatedHost Network Attribute Args] - dedicated host network parameters. contains the following attributes:
- payment_
type str - The billing method of the dedicated host. Valid values:
PrePaid
,PostPaid
. Default:PostPaid
. - resource_
group_ strid - The ID of the resource group to which the dedicated host belongs.
- sale_
cycle str - The unit of the subscription period of the dedicated host.
- Mapping[str, str]
- A mapping of tags to assign to the resource.
- zone_
id str - The zone ID of the dedicated host. This parameter is empty by default. If you do not specify this parameter, the system automatically selects a zone.
- dedicated
Host StringType - The type of the dedicated host. You can call the DescribeDedicatedHostTypes operation to obtain the most recent list of dedicated host types.
- action
On StringMaintenance - The policy used to migrate the instances from the dedicated host when the dedicated host fails or needs to be repaired online. Valid values:
Migrate
,Stop
. - auto
Placement String - Specifies whether to add the dedicated host to the resource pool for automatic deployment. If you do not specify the DedicatedHostId parameter when you create an instance on a dedicated host, Alibaba Cloud automatically selects a dedicated host from the resource pool to host the instance. Valid values:
on
,off
. Default:on
. - auto
Release StringTime - The automatic release time of the dedicated host. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC+0.
- auto
Renew Boolean - Specifies whether to automatically renew the subscription dedicated host.
- auto
Renew NumberPeriod - The auto-renewal period of the dedicated host. Unit: months. Valid values:
1
,2
,3
,6
, and12
. takes effect and is required only when the AutoRenew parameter is set to true. - cpu
Over NumberCommit Ratio - CPU oversold ratio. Only custom specifications g6s, c6s, r6s support setting the CPU oversold ratio.
- dedicated
Host StringCluster Id - The dedicated host cluster ID to which the dedicated host belongs.
- dedicated
Host StringName - The name of the dedicated host. The name must be 2 to 128 characters in length. It must start with a letter but cannot start with http:// or https://. It can contain letters, digits, colons (:), underscores (_), and hyphens (-).
- description String
- The description of the dedicated host. The description must be 2 to 256 characters in length and cannot start with http:// or https://.
- detail
Fee Boolean - Specifies whether to return the billing details of the order when the billing method is changed from subscription to pay-as-you-go. Default:
false
. - dry
Run Boolean - Specifies whether to only validate the request. Default:
false
. - expired
Time String - The subscription period of the dedicated host. The Period parameter takes effect and is required only when the ChargeType parameter is set to PrePaid.
- min
Quantity Number - Specify the minimum purchase quantity of a dedicated host.
- network
Attributes List<Property Map> - dedicated host network parameters. contains the following attributes:
- payment
Type String - The billing method of the dedicated host. Valid values:
PrePaid
,PostPaid
. Default:PostPaid
. - resource
Group StringId - The ID of the resource group to which the dedicated host belongs.
- sale
Cycle String - The unit of the subscription period of the dedicated host.
- Map<String>
- A mapping of tags to assign to the resource.
- zone
Id String - The zone ID of the dedicated host. This parameter is empty by default. If you do not specify this parameter, the system automatically selects a zone.
Outputs
All input properties are implicitly available as output properties. Additionally, the DedicatedHost resource produces the following output properties:
Look up Existing DedicatedHost Resource
Get an existing DedicatedHost 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?: DedicatedHostState, opts?: CustomResourceOptions): DedicatedHost
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
action_on_maintenance: Optional[str] = None,
auto_placement: Optional[str] = None,
auto_release_time: Optional[str] = None,
auto_renew: Optional[bool] = None,
auto_renew_period: Optional[int] = None,
cpu_over_commit_ratio: Optional[float] = None,
dedicated_host_cluster_id: Optional[str] = None,
dedicated_host_name: Optional[str] = None,
dedicated_host_type: Optional[str] = None,
description: Optional[str] = None,
detail_fee: Optional[bool] = None,
dry_run: Optional[bool] = None,
expired_time: Optional[str] = None,
min_quantity: Optional[int] = None,
network_attributes: Optional[Sequence[DedicatedHostNetworkAttributeArgs]] = None,
payment_type: Optional[str] = None,
resource_group_id: Optional[str] = None,
sale_cycle: Optional[str] = None,
status: Optional[str] = None,
tags: Optional[Mapping[str, str]] = None,
zone_id: Optional[str] = None) -> DedicatedHost
func GetDedicatedHost(ctx *Context, name string, id IDInput, state *DedicatedHostState, opts ...ResourceOption) (*DedicatedHost, error)
public static DedicatedHost Get(string name, Input<string> id, DedicatedHostState? state, CustomResourceOptions? opts = null)
public static DedicatedHost get(String name, Output<String> id, DedicatedHostState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
- 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.
- Action
On stringMaintenance - The policy used to migrate the instances from the dedicated host when the dedicated host fails or needs to be repaired online. Valid values:
Migrate
,Stop
. - Auto
Placement string - Specifies whether to add the dedicated host to the resource pool for automatic deployment. If you do not specify the DedicatedHostId parameter when you create an instance on a dedicated host, Alibaba Cloud automatically selects a dedicated host from the resource pool to host the instance. Valid values:
on
,off
. Default:on
. - Auto
Release stringTime - The automatic release time of the dedicated host. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC+0.
- Auto
Renew bool - Specifies whether to automatically renew the subscription dedicated host.
- Auto
Renew intPeriod - The auto-renewal period of the dedicated host. Unit: months. Valid values:
1
,2
,3
,6
, and12
. takes effect and is required only when the AutoRenew parameter is set to true. - Cpu
Over doubleCommit Ratio - CPU oversold ratio. Only custom specifications g6s, c6s, r6s support setting the CPU oversold ratio.
- Dedicated
Host stringCluster Id - The dedicated host cluster ID to which the dedicated host belongs.
- Dedicated
Host stringName - The name of the dedicated host. The name must be 2 to 128 characters in length. It must start with a letter but cannot start with http:// or https://. It can contain letters, digits, colons (:), underscores (_), and hyphens (-).
- Dedicated
Host stringType - The type of the dedicated host. You can call the DescribeDedicatedHostTypes operation to obtain the most recent list of dedicated host types.
- Description string
- The description of the dedicated host. The description must be 2 to 256 characters in length and cannot start with http:// or https://.
- Detail
Fee bool - Specifies whether to return the billing details of the order when the billing method is changed from subscription to pay-as-you-go. Default:
false
. - Dry
Run bool - Specifies whether to only validate the request. Default:
false
. - Expired
Time string - The subscription period of the dedicated host. The Period parameter takes effect and is required only when the ChargeType parameter is set to PrePaid.
- Min
Quantity int - Specify the minimum purchase quantity of a dedicated host.
- Network
Attributes List<Pulumi.Ali Cloud. Ecs. Inputs. Dedicated Host Network Attribute> - dedicated host network parameters. contains the following attributes:
- Payment
Type string - The billing method of the dedicated host. Valid values:
PrePaid
,PostPaid
. Default:PostPaid
. - Resource
Group stringId - The ID of the resource group to which the dedicated host belongs.
- Sale
Cycle string - The unit of the subscription period of the dedicated host.
- Status string
- The status of the dedicated host.
- Dictionary<string, string>
- A mapping of tags to assign to the resource.
- Zone
Id string - The zone ID of the dedicated host. This parameter is empty by default. If you do not specify this parameter, the system automatically selects a zone.
- Action
On stringMaintenance - The policy used to migrate the instances from the dedicated host when the dedicated host fails or needs to be repaired online. Valid values:
Migrate
,Stop
. - Auto
Placement string - Specifies whether to add the dedicated host to the resource pool for automatic deployment. If you do not specify the DedicatedHostId parameter when you create an instance on a dedicated host, Alibaba Cloud automatically selects a dedicated host from the resource pool to host the instance. Valid values:
on
,off
. Default:on
. - Auto
Release stringTime - The automatic release time of the dedicated host. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC+0.
- Auto
Renew bool - Specifies whether to automatically renew the subscription dedicated host.
- Auto
Renew intPeriod - The auto-renewal period of the dedicated host. Unit: months. Valid values:
1
,2
,3
,6
, and12
. takes effect and is required only when the AutoRenew parameter is set to true. - Cpu
Over float64Commit Ratio - CPU oversold ratio. Only custom specifications g6s, c6s, r6s support setting the CPU oversold ratio.
- Dedicated
Host stringCluster Id - The dedicated host cluster ID to which the dedicated host belongs.
- Dedicated
Host stringName - The name of the dedicated host. The name must be 2 to 128 characters in length. It must start with a letter but cannot start with http:// or https://. It can contain letters, digits, colons (:), underscores (_), and hyphens (-).
- Dedicated
Host stringType - The type of the dedicated host. You can call the DescribeDedicatedHostTypes operation to obtain the most recent list of dedicated host types.
- Description string
- The description of the dedicated host. The description must be 2 to 256 characters in length and cannot start with http:// or https://.
- Detail
Fee bool - Specifies whether to return the billing details of the order when the billing method is changed from subscription to pay-as-you-go. Default:
false
. - Dry
Run bool - Specifies whether to only validate the request. Default:
false
. - Expired
Time string - The subscription period of the dedicated host. The Period parameter takes effect and is required only when the ChargeType parameter is set to PrePaid.
- Min
Quantity int - Specify the minimum purchase quantity of a dedicated host.
- Network
Attributes []DedicatedHost Network Attribute Args - dedicated host network parameters. contains the following attributes:
- Payment
Type string - The billing method of the dedicated host. Valid values:
PrePaid
,PostPaid
. Default:PostPaid
. - Resource
Group stringId - The ID of the resource group to which the dedicated host belongs.
- Sale
Cycle string - The unit of the subscription period of the dedicated host.
- Status string
- The status of the dedicated host.
- map[string]string
- A mapping of tags to assign to the resource.
- Zone
Id string - The zone ID of the dedicated host. This parameter is empty by default. If you do not specify this parameter, the system automatically selects a zone.
- action
On StringMaintenance - The policy used to migrate the instances from the dedicated host when the dedicated host fails or needs to be repaired online. Valid values:
Migrate
,Stop
. - auto
Placement String - Specifies whether to add the dedicated host to the resource pool for automatic deployment. If you do not specify the DedicatedHostId parameter when you create an instance on a dedicated host, Alibaba Cloud automatically selects a dedicated host from the resource pool to host the instance. Valid values:
on
,off
. Default:on
. - auto
Release StringTime - The automatic release time of the dedicated host. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC+0.
- auto
Renew Boolean - Specifies whether to automatically renew the subscription dedicated host.
- auto
Renew IntegerPeriod - The auto-renewal period of the dedicated host. Unit: months. Valid values:
1
,2
,3
,6
, and12
. takes effect and is required only when the AutoRenew parameter is set to true. - cpu
Over DoubleCommit Ratio - CPU oversold ratio. Only custom specifications g6s, c6s, r6s support setting the CPU oversold ratio.
- dedicated
Host StringCluster Id - The dedicated host cluster ID to which the dedicated host belongs.
- dedicated
Host StringName - The name of the dedicated host. The name must be 2 to 128 characters in length. It must start with a letter but cannot start with http:// or https://. It can contain letters, digits, colons (:), underscores (_), and hyphens (-).
- dedicated
Host StringType - The type of the dedicated host. You can call the DescribeDedicatedHostTypes operation to obtain the most recent list of dedicated host types.
- description String
- The description of the dedicated host. The description must be 2 to 256 characters in length and cannot start with http:// or https://.
- detail
Fee Boolean - Specifies whether to return the billing details of the order when the billing method is changed from subscription to pay-as-you-go. Default:
false
. - dry
Run Boolean - Specifies whether to only validate the request. Default:
false
. - expired
Time String - The subscription period of the dedicated host. The Period parameter takes effect and is required only when the ChargeType parameter is set to PrePaid.
- min
Quantity Integer - Specify the minimum purchase quantity of a dedicated host.
- network
Attributes List<DedicatedHost Network Attribute> - dedicated host network parameters. contains the following attributes:
- payment
Type String - The billing method of the dedicated host. Valid values:
PrePaid
,PostPaid
. Default:PostPaid
. - resource
Group StringId - The ID of the resource group to which the dedicated host belongs.
- sale
Cycle String - The unit of the subscription period of the dedicated host.
- status String
- The status of the dedicated host.
- Map<String,String>
- A mapping of tags to assign to the resource.
- zone
Id String - The zone ID of the dedicated host. This parameter is empty by default. If you do not specify this parameter, the system automatically selects a zone.
- action
On stringMaintenance - The policy used to migrate the instances from the dedicated host when the dedicated host fails or needs to be repaired online. Valid values:
Migrate
,Stop
. - auto
Placement string - Specifies whether to add the dedicated host to the resource pool for automatic deployment. If you do not specify the DedicatedHostId parameter when you create an instance on a dedicated host, Alibaba Cloud automatically selects a dedicated host from the resource pool to host the instance. Valid values:
on
,off
. Default:on
. - auto
Release stringTime - The automatic release time of the dedicated host. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC+0.
- auto
Renew boolean - Specifies whether to automatically renew the subscription dedicated host.
- auto
Renew numberPeriod - The auto-renewal period of the dedicated host. Unit: months. Valid values:
1
,2
,3
,6
, and12
. takes effect and is required only when the AutoRenew parameter is set to true. - cpu
Over numberCommit Ratio - CPU oversold ratio. Only custom specifications g6s, c6s, r6s support setting the CPU oversold ratio.
- dedicated
Host stringCluster Id - The dedicated host cluster ID to which the dedicated host belongs.
- dedicated
Host stringName - The name of the dedicated host. The name must be 2 to 128 characters in length. It must start with a letter but cannot start with http:// or https://. It can contain letters, digits, colons (:), underscores (_), and hyphens (-).
- dedicated
Host stringType - The type of the dedicated host. You can call the DescribeDedicatedHostTypes operation to obtain the most recent list of dedicated host types.
- description string
- The description of the dedicated host. The description must be 2 to 256 characters in length and cannot start with http:// or https://.
- detail
Fee boolean - Specifies whether to return the billing details of the order when the billing method is changed from subscription to pay-as-you-go. Default:
false
. - dry
Run boolean - Specifies whether to only validate the request. Default:
false
. - expired
Time string - The subscription period of the dedicated host. The Period parameter takes effect and is required only when the ChargeType parameter is set to PrePaid.
- min
Quantity number - Specify the minimum purchase quantity of a dedicated host.
- network
Attributes DedicatedHost Network Attribute[] - dedicated host network parameters. contains the following attributes:
- payment
Type string - The billing method of the dedicated host. Valid values:
PrePaid
,PostPaid
. Default:PostPaid
. - resource
Group stringId - The ID of the resource group to which the dedicated host belongs.
- sale
Cycle string - The unit of the subscription period of the dedicated host.
- status string
- The status of the dedicated host.
- {[key: string]: string}
- A mapping of tags to assign to the resource.
- zone
Id string - The zone ID of the dedicated host. This parameter is empty by default. If you do not specify this parameter, the system automatically selects a zone.
- action_
on_ strmaintenance - The policy used to migrate the instances from the dedicated host when the dedicated host fails or needs to be repaired online. Valid values:
Migrate
,Stop
. - auto_
placement str - Specifies whether to add the dedicated host to the resource pool for automatic deployment. If you do not specify the DedicatedHostId parameter when you create an instance on a dedicated host, Alibaba Cloud automatically selects a dedicated host from the resource pool to host the instance. Valid values:
on
,off
. Default:on
. - auto_
release_ strtime - The automatic release time of the dedicated host. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC+0.
- auto_
renew bool - Specifies whether to automatically renew the subscription dedicated host.
- auto_
renew_ intperiod - The auto-renewal period of the dedicated host. Unit: months. Valid values:
1
,2
,3
,6
, and12
. takes effect and is required only when the AutoRenew parameter is set to true. - cpu_
over_ floatcommit_ ratio - CPU oversold ratio. Only custom specifications g6s, c6s, r6s support setting the CPU oversold ratio.
- dedicated_
host_ strcluster_ id - The dedicated host cluster ID to which the dedicated host belongs.
- dedicated_
host_ strname - The name of the dedicated host. The name must be 2 to 128 characters in length. It must start with a letter but cannot start with http:// or https://. It can contain letters, digits, colons (:), underscores (_), and hyphens (-).
- dedicated_
host_ strtype - The type of the dedicated host. You can call the DescribeDedicatedHostTypes operation to obtain the most recent list of dedicated host types.
- description str
- The description of the dedicated host. The description must be 2 to 256 characters in length and cannot start with http:// or https://.
- detail_
fee bool - Specifies whether to return the billing details of the order when the billing method is changed from subscription to pay-as-you-go. Default:
false
. - dry_
run bool - Specifies whether to only validate the request. Default:
false
. - expired_
time str - The subscription period of the dedicated host. The Period parameter takes effect and is required only when the ChargeType parameter is set to PrePaid.
- min_
quantity int - Specify the minimum purchase quantity of a dedicated host.
- network_
attributes Sequence[DedicatedHost Network Attribute Args] - dedicated host network parameters. contains the following attributes:
- payment_
type str - The billing method of the dedicated host. Valid values:
PrePaid
,PostPaid
. Default:PostPaid
. - resource_
group_ strid - The ID of the resource group to which the dedicated host belongs.
- sale_
cycle str - The unit of the subscription period of the dedicated host.
- status str
- The status of the dedicated host.
- Mapping[str, str]
- A mapping of tags to assign to the resource.
- zone_
id str - The zone ID of the dedicated host. This parameter is empty by default. If you do not specify this parameter, the system automatically selects a zone.
- action
On StringMaintenance - The policy used to migrate the instances from the dedicated host when the dedicated host fails or needs to be repaired online. Valid values:
Migrate
,Stop
. - auto
Placement String - Specifies whether to add the dedicated host to the resource pool for automatic deployment. If you do not specify the DedicatedHostId parameter when you create an instance on a dedicated host, Alibaba Cloud automatically selects a dedicated host from the resource pool to host the instance. Valid values:
on
,off
. Default:on
. - auto
Release StringTime - The automatic release time of the dedicated host. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC+0.
- auto
Renew Boolean - Specifies whether to automatically renew the subscription dedicated host.
- auto
Renew NumberPeriod - The auto-renewal period of the dedicated host. Unit: months. Valid values:
1
,2
,3
,6
, and12
. takes effect and is required only when the AutoRenew parameter is set to true. - cpu
Over NumberCommit Ratio - CPU oversold ratio. Only custom specifications g6s, c6s, r6s support setting the CPU oversold ratio.
- dedicated
Host StringCluster Id - The dedicated host cluster ID to which the dedicated host belongs.
- dedicated
Host StringName - The name of the dedicated host. The name must be 2 to 128 characters in length. It must start with a letter but cannot start with http:// or https://. It can contain letters, digits, colons (:), underscores (_), and hyphens (-).
- dedicated
Host StringType - The type of the dedicated host. You can call the DescribeDedicatedHostTypes operation to obtain the most recent list of dedicated host types.
- description String
- The description of the dedicated host. The description must be 2 to 256 characters in length and cannot start with http:// or https://.
- detail
Fee Boolean - Specifies whether to return the billing details of the order when the billing method is changed from subscription to pay-as-you-go. Default:
false
. - dry
Run Boolean - Specifies whether to only validate the request. Default:
false
. - expired
Time String - The subscription period of the dedicated host. The Period parameter takes effect and is required only when the ChargeType parameter is set to PrePaid.
- min
Quantity Number - Specify the minimum purchase quantity of a dedicated host.
- network
Attributes List<Property Map> - dedicated host network parameters. contains the following attributes:
- payment
Type String - The billing method of the dedicated host. Valid values:
PrePaid
,PostPaid
. Default:PostPaid
. - resource
Group StringId - The ID of the resource group to which the dedicated host belongs.
- sale
Cycle String - The unit of the subscription period of the dedicated host.
- status String
- The status of the dedicated host.
- Map<String>
- A mapping of tags to assign to the resource.
- zone
Id String - The zone ID of the dedicated host. This parameter is empty by default. If you do not specify this parameter, the system automatically selects a zone.
Supporting Types
DedicatedHostNetworkAttribute, DedicatedHostNetworkAttributeArgs
- Slb
Udp intTimeout - The timeout period for a UDP session between Server Load Balancer (SLB) and the dedicated host. Unit: seconds. Valid values: 15 to 310.
- Udp
Timeout int - The timeout period for a UDP session between a user and an Alibaba Cloud service on the dedicated host. Unit: seconds. Valid values: 15 to 310.
- Slb
Udp intTimeout - The timeout period for a UDP session between Server Load Balancer (SLB) and the dedicated host. Unit: seconds. Valid values: 15 to 310.
- Udp
Timeout int - The timeout period for a UDP session between a user and an Alibaba Cloud service on the dedicated host. Unit: seconds. Valid values: 15 to 310.
- slb
Udp IntegerTimeout - The timeout period for a UDP session between Server Load Balancer (SLB) and the dedicated host. Unit: seconds. Valid values: 15 to 310.
- udp
Timeout Integer - The timeout period for a UDP session between a user and an Alibaba Cloud service on the dedicated host. Unit: seconds. Valid values: 15 to 310.
- slb
Udp numberTimeout - The timeout period for a UDP session between Server Load Balancer (SLB) and the dedicated host. Unit: seconds. Valid values: 15 to 310.
- udp
Timeout number - The timeout period for a UDP session between a user and an Alibaba Cloud service on the dedicated host. Unit: seconds. Valid values: 15 to 310.
- slb_
udp_ inttimeout - The timeout period for a UDP session between Server Load Balancer (SLB) and the dedicated host. Unit: seconds. Valid values: 15 to 310.
- udp_
timeout int - The timeout period for a UDP session between a user and an Alibaba Cloud service on the dedicated host. Unit: seconds. Valid values: 15 to 310.
- slb
Udp NumberTimeout - The timeout period for a UDP session between Server Load Balancer (SLB) and the dedicated host. Unit: seconds. Valid values: 15 to 310.
- udp
Timeout Number - The timeout period for a UDP session between a user and an Alibaba Cloud service on the dedicated host. Unit: seconds. Valid values: 15 to 310.
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
alicloud
Terraform Provider.