alicloud.ecs.AutoProvisioningGroup
Explore with Pulumi AI
Provides a ECS auto provisioning group resource which is a solution that uses preemptive instances and pay_as_you_go instances to rapidly deploy clusters.
NOTE: Available in 1.79.0+
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
const config = new pulumi.Config();
const name = config.get("name") || "auto_provisioning_group";
const default = alicloud.getZones({
availableDiskCategory: "cloud_efficiency",
availableResourceCreation: "VSwitch",
});
const defaultNetwork = new alicloud.vpc.Network("default", {
vpcName: name,
cidrBlock: "172.16.0.0/16",
});
const defaultSwitch = new alicloud.vpc.Switch("default", {
vpcId: defaultNetwork.id,
cidrBlock: "172.16.0.0/24",
zoneId: _default.then(_default => _default.zones?.[0]?.id),
vswitchName: name,
});
const defaultSecurityGroup = new alicloud.ecs.SecurityGroup("default", {
name: name,
vpcId: defaultNetwork.id,
});
const defaultGetImages = alicloud.ecs.getImages({
nameRegex: "^ubuntu_18.*64",
mostRecent: true,
owners: "system",
});
const template = new alicloud.ecs.EcsLaunchTemplate("template", {
name: name,
imageId: defaultGetImages.then(defaultGetImages => defaultGetImages.images?.[0]?.id),
instanceType: "ecs.n1.tiny",
securityGroupId: defaultSecurityGroup.id,
});
const defaultAutoProvisioningGroup = new alicloud.ecs.AutoProvisioningGroup("default", {
launchTemplateId: template.id,
totalTargetCapacity: "4",
payAsYouGoTargetCapacity: "1",
spotTargetCapacity: "2",
launchTemplateConfigs: [{
instanceType: "ecs.n1.small",
vswitchId: defaultSwitch.id,
weightedCapacity: "2",
maxPrice: "2",
}],
});
import pulumi
import pulumi_alicloud as alicloud
config = pulumi.Config()
name = config.get("name")
if name is None:
name = "auto_provisioning_group"
default = alicloud.get_zones(available_disk_category="cloud_efficiency",
available_resource_creation="VSwitch")
default_network = alicloud.vpc.Network("default",
vpc_name=name,
cidr_block="172.16.0.0/16")
default_switch = alicloud.vpc.Switch("default",
vpc_id=default_network.id,
cidr_block="172.16.0.0/24",
zone_id=default.zones[0].id,
vswitch_name=name)
default_security_group = alicloud.ecs.SecurityGroup("default",
name=name,
vpc_id=default_network.id)
default_get_images = alicloud.ecs.get_images(name_regex="^ubuntu_18.*64",
most_recent=True,
owners="system")
template = alicloud.ecs.EcsLaunchTemplate("template",
name=name,
image_id=default_get_images.images[0].id,
instance_type="ecs.n1.tiny",
security_group_id=default_security_group.id)
default_auto_provisioning_group = alicloud.ecs.AutoProvisioningGroup("default",
launch_template_id=template.id,
total_target_capacity="4",
pay_as_you_go_target_capacity="1",
spot_target_capacity="2",
launch_template_configs=[alicloud.ecs.AutoProvisioningGroupLaunchTemplateConfigArgs(
instance_type="ecs.n1.small",
vswitch_id=default_switch.id,
weighted_capacity="2",
max_price="2",
)])
package main
import (
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud"
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/ecs"
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/vpc"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
cfg := config.New(ctx, "")
name := "auto_provisioning_group"
if param := cfg.Get("name"); param != "" {
name = param
}
_default, err := alicloud.GetZones(ctx, &alicloud.GetZonesArgs{
AvailableDiskCategory: pulumi.StringRef("cloud_efficiency"),
AvailableResourceCreation: pulumi.StringRef("VSwitch"),
}, nil)
if err != nil {
return err
}
defaultNetwork, err := vpc.NewNetwork(ctx, "default", &vpc.NetworkArgs{
VpcName: pulumi.String(name),
CidrBlock: pulumi.String("172.16.0.0/16"),
})
if err != nil {
return err
}
defaultSwitch, err := vpc.NewSwitch(ctx, "default", &vpc.SwitchArgs{
VpcId: defaultNetwork.ID(),
CidrBlock: pulumi.String("172.16.0.0/24"),
ZoneId: pulumi.String(_default.Zones[0].Id),
VswitchName: pulumi.String(name),
})
if err != nil {
return err
}
defaultSecurityGroup, err := ecs.NewSecurityGroup(ctx, "default", &ecs.SecurityGroupArgs{
Name: pulumi.String(name),
VpcId: defaultNetwork.ID(),
})
if err != nil {
return err
}
defaultGetImages, err := ecs.GetImages(ctx, &ecs.GetImagesArgs{
NameRegex: pulumi.StringRef("^ubuntu_18.*64"),
MostRecent: pulumi.BoolRef(true),
Owners: pulumi.StringRef("system"),
}, nil)
if err != nil {
return err
}
template, err := ecs.NewEcsLaunchTemplate(ctx, "template", &ecs.EcsLaunchTemplateArgs{
Name: pulumi.String(name),
ImageId: pulumi.String(defaultGetImages.Images[0].Id),
InstanceType: pulumi.String("ecs.n1.tiny"),
SecurityGroupId: defaultSecurityGroup.ID(),
})
if err != nil {
return err
}
_, err = ecs.NewAutoProvisioningGroup(ctx, "default", &ecs.AutoProvisioningGroupArgs{
LaunchTemplateId: template.ID(),
TotalTargetCapacity: pulumi.String("4"),
PayAsYouGoTargetCapacity: pulumi.String("1"),
SpotTargetCapacity: pulumi.String("2"),
LaunchTemplateConfigs: ecs.AutoProvisioningGroupLaunchTemplateConfigArray{
&ecs.AutoProvisioningGroupLaunchTemplateConfigArgs{
InstanceType: pulumi.String("ecs.n1.small"),
VswitchId: defaultSwitch.ID(),
WeightedCapacity: pulumi.String("2"),
MaxPrice: pulumi.String("2"),
},
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
return await Deployment.RunAsync(() =>
{
var config = new Config();
var name = config.Get("name") ?? "auto_provisioning_group";
var @default = AliCloud.GetZones.Invoke(new()
{
AvailableDiskCategory = "cloud_efficiency",
AvailableResourceCreation = "VSwitch",
});
var defaultNetwork = new AliCloud.Vpc.Network("default", new()
{
VpcName = name,
CidrBlock = "172.16.0.0/16",
});
var defaultSwitch = new AliCloud.Vpc.Switch("default", new()
{
VpcId = defaultNetwork.Id,
CidrBlock = "172.16.0.0/24",
ZoneId = @default.Apply(@default => @default.Apply(getZonesResult => getZonesResult.Zones[0]?.Id)),
VswitchName = name,
});
var defaultSecurityGroup = new AliCloud.Ecs.SecurityGroup("default", new()
{
Name = name,
VpcId = defaultNetwork.Id,
});
var defaultGetImages = AliCloud.Ecs.GetImages.Invoke(new()
{
NameRegex = "^ubuntu_18.*64",
MostRecent = true,
Owners = "system",
});
var template = new AliCloud.Ecs.EcsLaunchTemplate("template", new()
{
Name = name,
ImageId = defaultGetImages.Apply(getImagesResult => getImagesResult.Images[0]?.Id),
InstanceType = "ecs.n1.tiny",
SecurityGroupId = defaultSecurityGroup.Id,
});
var defaultAutoProvisioningGroup = new AliCloud.Ecs.AutoProvisioningGroup("default", new()
{
LaunchTemplateId = template.Id,
TotalTargetCapacity = "4",
PayAsYouGoTargetCapacity = "1",
SpotTargetCapacity = "2",
LaunchTemplateConfigs = new[]
{
new AliCloud.Ecs.Inputs.AutoProvisioningGroupLaunchTemplateConfigArgs
{
InstanceType = "ecs.n1.small",
VswitchId = defaultSwitch.Id,
WeightedCapacity = "2",
MaxPrice = "2",
},
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.AlicloudFunctions;
import com.pulumi.alicloud.inputs.GetZonesArgs;
import com.pulumi.alicloud.vpc.Network;
import com.pulumi.alicloud.vpc.NetworkArgs;
import com.pulumi.alicloud.vpc.Switch;
import com.pulumi.alicloud.vpc.SwitchArgs;
import com.pulumi.alicloud.ecs.SecurityGroup;
import com.pulumi.alicloud.ecs.SecurityGroupArgs;
import com.pulumi.alicloud.ecs.EcsFunctions;
import com.pulumi.alicloud.ecs.inputs.GetImagesArgs;
import com.pulumi.alicloud.ecs.EcsLaunchTemplate;
import com.pulumi.alicloud.ecs.EcsLaunchTemplateArgs;
import com.pulumi.alicloud.ecs.AutoProvisioningGroup;
import com.pulumi.alicloud.ecs.AutoProvisioningGroupArgs;
import com.pulumi.alicloud.ecs.inputs.AutoProvisioningGroupLaunchTemplateConfigArgs;
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 config = ctx.config();
final var name = config.get("name").orElse("auto_provisioning_group");
final var default = AlicloudFunctions.getZones(GetZonesArgs.builder()
.availableDiskCategory("cloud_efficiency")
.availableResourceCreation("VSwitch")
.build());
var defaultNetwork = new Network("defaultNetwork", NetworkArgs.builder()
.vpcName(name)
.cidrBlock("172.16.0.0/16")
.build());
var defaultSwitch = new Switch("defaultSwitch", SwitchArgs.builder()
.vpcId(defaultNetwork.id())
.cidrBlock("172.16.0.0/24")
.zoneId(default_.zones()[0].id())
.vswitchName(name)
.build());
var defaultSecurityGroup = new SecurityGroup("defaultSecurityGroup", SecurityGroupArgs.builder()
.name(name)
.vpcId(defaultNetwork.id())
.build());
final var defaultGetImages = EcsFunctions.getImages(GetImagesArgs.builder()
.nameRegex("^ubuntu_18.*64")
.mostRecent(true)
.owners("system")
.build());
var template = new EcsLaunchTemplate("template", EcsLaunchTemplateArgs.builder()
.name(name)
.imageId(defaultGetImages.applyValue(getImagesResult -> getImagesResult.images()[0].id()))
.instanceType("ecs.n1.tiny")
.securityGroupId(defaultSecurityGroup.id())
.build());
var defaultAutoProvisioningGroup = new AutoProvisioningGroup("defaultAutoProvisioningGroup", AutoProvisioningGroupArgs.builder()
.launchTemplateId(template.id())
.totalTargetCapacity("4")
.payAsYouGoTargetCapacity("1")
.spotTargetCapacity("2")
.launchTemplateConfigs(AutoProvisioningGroupLaunchTemplateConfigArgs.builder()
.instanceType("ecs.n1.small")
.vswitchId(defaultSwitch.id())
.weightedCapacity("2")
.maxPrice("2")
.build())
.build());
}
}
configuration:
name:
type: string
default: auto_provisioning_group
resources:
defaultNetwork:
type: alicloud:vpc:Network
name: default
properties:
vpcName: ${name}
cidrBlock: 172.16.0.0/16
defaultSwitch:
type: alicloud:vpc:Switch
name: default
properties:
vpcId: ${defaultNetwork.id}
cidrBlock: 172.16.0.0/24
zoneId: ${default.zones[0].id}
vswitchName: ${name}
defaultAutoProvisioningGroup:
type: alicloud:ecs:AutoProvisioningGroup
name: default
properties:
launchTemplateId: ${template.id}
totalTargetCapacity: '4'
payAsYouGoTargetCapacity: '1'
spotTargetCapacity: '2'
launchTemplateConfigs:
- instanceType: ecs.n1.small
vswitchId: ${defaultSwitch.id}
weightedCapacity: '2'
maxPrice: '2'
template:
type: alicloud:ecs:EcsLaunchTemplate
properties:
name: ${name}
imageId: ${defaultGetImages.images[0].id}
instanceType: ecs.n1.tiny
securityGroupId: ${defaultSecurityGroup.id}
defaultSecurityGroup:
type: alicloud:ecs:SecurityGroup
name: default
properties:
name: ${name}
vpcId: ${defaultNetwork.id}
variables:
default:
fn::invoke:
Function: alicloud:getZones
Arguments:
availableDiskCategory: cloud_efficiency
availableResourceCreation: VSwitch
defaultGetImages:
fn::invoke:
Function: alicloud:ecs:getImages
Arguments:
nameRegex: ^ubuntu_18.*64
mostRecent: true
owners: system
Create AutoProvisioningGroup Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new AutoProvisioningGroup(name: string, args: AutoProvisioningGroupArgs, opts?: CustomResourceOptions);
@overload
def AutoProvisioningGroup(resource_name: str,
args: AutoProvisioningGroupArgs,
opts: Optional[ResourceOptions] = None)
@overload
def AutoProvisioningGroup(resource_name: str,
opts: Optional[ResourceOptions] = None,
launch_template_configs: Optional[Sequence[AutoProvisioningGroupLaunchTemplateConfigArgs]] = None,
total_target_capacity: Optional[str] = None,
launch_template_id: Optional[str] = None,
pay_as_you_go_target_capacity: Optional[str] = None,
spot_instance_interruption_behavior: Optional[str] = None,
description: Optional[str] = None,
default_target_capacity_type: Optional[str] = None,
launch_template_version: Optional[str] = None,
max_spot_price: Optional[float] = None,
pay_as_you_go_allocation_strategy: Optional[str] = None,
auto_provisioning_group_name: Optional[str] = None,
spot_allocation_strategy: Optional[str] = None,
excess_capacity_termination_policy: Optional[str] = None,
spot_instance_pools_to_use_count: Optional[int] = None,
spot_target_capacity: Optional[str] = None,
terminate_instances: Optional[bool] = None,
terminate_instances_with_expiration: Optional[bool] = None,
auto_provisioning_group_type: Optional[str] = None,
valid_from: Optional[str] = None,
valid_until: Optional[str] = None)
func NewAutoProvisioningGroup(ctx *Context, name string, args AutoProvisioningGroupArgs, opts ...ResourceOption) (*AutoProvisioningGroup, error)
public AutoProvisioningGroup(string name, AutoProvisioningGroupArgs args, CustomResourceOptions? opts = null)
public AutoProvisioningGroup(String name, AutoProvisioningGroupArgs args)
public AutoProvisioningGroup(String name, AutoProvisioningGroupArgs args, CustomResourceOptions options)
type: alicloud:ecs:AutoProvisioningGroup
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 AutoProvisioningGroupArgs
- 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 AutoProvisioningGroupArgs
- 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 AutoProvisioningGroupArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args AutoProvisioningGroupArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args AutoProvisioningGroupArgs
- 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 autoProvisioningGroupResource = new AliCloud.Ecs.AutoProvisioningGroup("autoProvisioningGroupResource", new()
{
LaunchTemplateConfigs = new[]
{
new AliCloud.Ecs.Inputs.AutoProvisioningGroupLaunchTemplateConfigArgs
{
MaxPrice = "string",
VswitchId = "string",
WeightedCapacity = "string",
InstanceType = "string",
Priority = "string",
},
},
TotalTargetCapacity = "string",
LaunchTemplateId = "string",
PayAsYouGoTargetCapacity = "string",
SpotInstanceInterruptionBehavior = "string",
Description = "string",
DefaultTargetCapacityType = "string",
LaunchTemplateVersion = "string",
MaxSpotPrice = 0,
PayAsYouGoAllocationStrategy = "string",
AutoProvisioningGroupName = "string",
SpotAllocationStrategy = "string",
ExcessCapacityTerminationPolicy = "string",
SpotInstancePoolsToUseCount = 0,
SpotTargetCapacity = "string",
TerminateInstances = false,
TerminateInstancesWithExpiration = false,
AutoProvisioningGroupType = "string",
ValidFrom = "string",
ValidUntil = "string",
});
example, err := ecs.NewAutoProvisioningGroup(ctx, "autoProvisioningGroupResource", &ecs.AutoProvisioningGroupArgs{
LaunchTemplateConfigs: ecs.AutoProvisioningGroupLaunchTemplateConfigArray{
&ecs.AutoProvisioningGroupLaunchTemplateConfigArgs{
MaxPrice: pulumi.String("string"),
VswitchId: pulumi.String("string"),
WeightedCapacity: pulumi.String("string"),
InstanceType: pulumi.String("string"),
Priority: pulumi.String("string"),
},
},
TotalTargetCapacity: pulumi.String("string"),
LaunchTemplateId: pulumi.String("string"),
PayAsYouGoTargetCapacity: pulumi.String("string"),
SpotInstanceInterruptionBehavior: pulumi.String("string"),
Description: pulumi.String("string"),
DefaultTargetCapacityType: pulumi.String("string"),
LaunchTemplateVersion: pulumi.String("string"),
MaxSpotPrice: pulumi.Float64(0),
PayAsYouGoAllocationStrategy: pulumi.String("string"),
AutoProvisioningGroupName: pulumi.String("string"),
SpotAllocationStrategy: pulumi.String("string"),
ExcessCapacityTerminationPolicy: pulumi.String("string"),
SpotInstancePoolsToUseCount: pulumi.Int(0),
SpotTargetCapacity: pulumi.String("string"),
TerminateInstances: pulumi.Bool(false),
TerminateInstancesWithExpiration: pulumi.Bool(false),
AutoProvisioningGroupType: pulumi.String("string"),
ValidFrom: pulumi.String("string"),
ValidUntil: pulumi.String("string"),
})
var autoProvisioningGroupResource = new AutoProvisioningGroup("autoProvisioningGroupResource", AutoProvisioningGroupArgs.builder()
.launchTemplateConfigs(AutoProvisioningGroupLaunchTemplateConfigArgs.builder()
.maxPrice("string")
.vswitchId("string")
.weightedCapacity("string")
.instanceType("string")
.priority("string")
.build())
.totalTargetCapacity("string")
.launchTemplateId("string")
.payAsYouGoTargetCapacity("string")
.spotInstanceInterruptionBehavior("string")
.description("string")
.defaultTargetCapacityType("string")
.launchTemplateVersion("string")
.maxSpotPrice(0)
.payAsYouGoAllocationStrategy("string")
.autoProvisioningGroupName("string")
.spotAllocationStrategy("string")
.excessCapacityTerminationPolicy("string")
.spotInstancePoolsToUseCount(0)
.spotTargetCapacity("string")
.terminateInstances(false)
.terminateInstancesWithExpiration(false)
.autoProvisioningGroupType("string")
.validFrom("string")
.validUntil("string")
.build());
auto_provisioning_group_resource = alicloud.ecs.AutoProvisioningGroup("autoProvisioningGroupResource",
launch_template_configs=[alicloud.ecs.AutoProvisioningGroupLaunchTemplateConfigArgs(
max_price="string",
vswitch_id="string",
weighted_capacity="string",
instance_type="string",
priority="string",
)],
total_target_capacity="string",
launch_template_id="string",
pay_as_you_go_target_capacity="string",
spot_instance_interruption_behavior="string",
description="string",
default_target_capacity_type="string",
launch_template_version="string",
max_spot_price=0,
pay_as_you_go_allocation_strategy="string",
auto_provisioning_group_name="string",
spot_allocation_strategy="string",
excess_capacity_termination_policy="string",
spot_instance_pools_to_use_count=0,
spot_target_capacity="string",
terminate_instances=False,
terminate_instances_with_expiration=False,
auto_provisioning_group_type="string",
valid_from="string",
valid_until="string")
const autoProvisioningGroupResource = new alicloud.ecs.AutoProvisioningGroup("autoProvisioningGroupResource", {
launchTemplateConfigs: [{
maxPrice: "string",
vswitchId: "string",
weightedCapacity: "string",
instanceType: "string",
priority: "string",
}],
totalTargetCapacity: "string",
launchTemplateId: "string",
payAsYouGoTargetCapacity: "string",
spotInstanceInterruptionBehavior: "string",
description: "string",
defaultTargetCapacityType: "string",
launchTemplateVersion: "string",
maxSpotPrice: 0,
payAsYouGoAllocationStrategy: "string",
autoProvisioningGroupName: "string",
spotAllocationStrategy: "string",
excessCapacityTerminationPolicy: "string",
spotInstancePoolsToUseCount: 0,
spotTargetCapacity: "string",
terminateInstances: false,
terminateInstancesWithExpiration: false,
autoProvisioningGroupType: "string",
validFrom: "string",
validUntil: "string",
});
type: alicloud:ecs:AutoProvisioningGroup
properties:
autoProvisioningGroupName: string
autoProvisioningGroupType: string
defaultTargetCapacityType: string
description: string
excessCapacityTerminationPolicy: string
launchTemplateConfigs:
- instanceType: string
maxPrice: string
priority: string
vswitchId: string
weightedCapacity: string
launchTemplateId: string
launchTemplateVersion: string
maxSpotPrice: 0
payAsYouGoAllocationStrategy: string
payAsYouGoTargetCapacity: string
spotAllocationStrategy: string
spotInstanceInterruptionBehavior: string
spotInstancePoolsToUseCount: 0
spotTargetCapacity: string
terminateInstances: false
terminateInstancesWithExpiration: false
totalTargetCapacity: string
validFrom: string
validUntil: string
AutoProvisioningGroup Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
The AutoProvisioningGroup resource accepts the following input properties:
- Launch
Template List<Pulumi.Configs Ali Cloud. Ecs. Inputs. Auto Provisioning Group Launch Template Config> - DataDisk mappings to attach to ecs instance. See
block-config
below for details. - Launch
Template stringId - The ID of the instance launch template associated with the auto provisioning group.
- Total
Target stringCapacity - The total target capacity of the auto provisioning group. The target capacity consists of the following three parts:PayAsYouGoTargetCapacity,SpotTargetCapacity and the supplemental capacity besides PayAsYouGoTargetCapacity and SpotTargetCapacity.
- Auto
Provisioning stringGroup Name - The name of the auto provisioning group to be created. It 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 (-)
- Auto
Provisioning stringGroup Type - The type of the auto provisioning group. Valid values:
request
andmaintain
,Default value:maintain
. - Default
Target stringCapacity Type - The type of supplemental instances. When the total value of
PayAsYouGoTargetCapacity
andSpotTargetCapacity
is smaller than the value of TotalTargetCapacity, the auto provisioning group will create instances of the specified type to meet the capacity requirements. Valid values:PayAsYouGo
: Pay-as-you-go instances;Spot
: Preemptible instances, Default value:Spot
. - Description string
- The description of the auto provisioning group.
- Excess
Capacity stringTermination Policy - The shutdown policy for excess preemptible instances followed when the capacity of the auto provisioning group exceeds the target capacity. Valid values:
no-termination
andtermination
,Default value:no-termination
. - Launch
Template stringVersion - The version of the instance launch template associated with the auto provisioning group.
- Max
Spot doublePrice - The global maximum price for preemptible instances in the auto provisioning group. If both the
MaxSpotPrice
andLaunchTemplateConfig.N.MaxPrice
parameters are specified, the maximum price is the lower value of the two. - Pay
As stringYou Go Allocation Strategy - The scale-out policy for pay-as-you-go instances. Valid values:
lowest-price
andprioritized
,Default value:lowest-price
. - Pay
As stringYou Go Target Capacity - The target capacity of pay-as-you-go instances in the auto provisioning group.
- Spot
Allocation stringStrategy - The scale-out policy for preemptible instances. Valid values:
lowest-price
anddiversified
,Default value:lowest-price
. - Spot
Instance stringInterruption Behavior - The default behavior after preemptible instances are shut down. Valid values:
stop
andterminate
,Default value:stop
. - Spot
Instance intPools To Use Count - This parameter takes effect when the
SpotAllocationStrategy
parameter is set tolowest-price
. The auto provisioning group selects instance types of the lowest cost to create instances. - Spot
Target stringCapacity - The target capacity of preemptible instances in the auto provisioning group.
- Terminate
Instances bool - Specifies whether to release instances of the auto provisioning group. Valid values:
false
andtrue
, default value:false
. - Terminate
Instances boolWith Expiration - The shutdown policy for preemptible instances when the auto provisioning group expires. Valid values:
false
andtrue
, default value:false
. - Valid
From string - The time when the auto provisioning group is started. The period of time between this point in time and the point in time specified by the
valid_until
parameter is the effective time period of the auto provisioning group.By default, an auto provisioning group is immediately started after creation. - Valid
Until string - The time when the auto provisioning group expires. The period of time between this point in time and the point in time specified by the
valid_from
parameter is the effective time period of the auto provisioning group.By default, an auto provisioning group never expires.
- Launch
Template []AutoConfigs Provisioning Group Launch Template Config Args - DataDisk mappings to attach to ecs instance. See
block-config
below for details. - Launch
Template stringId - The ID of the instance launch template associated with the auto provisioning group.
- Total
Target stringCapacity - The total target capacity of the auto provisioning group. The target capacity consists of the following three parts:PayAsYouGoTargetCapacity,SpotTargetCapacity and the supplemental capacity besides PayAsYouGoTargetCapacity and SpotTargetCapacity.
- Auto
Provisioning stringGroup Name - The name of the auto provisioning group to be created. It 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 (-)
- Auto
Provisioning stringGroup Type - The type of the auto provisioning group. Valid values:
request
andmaintain
,Default value:maintain
. - Default
Target stringCapacity Type - The type of supplemental instances. When the total value of
PayAsYouGoTargetCapacity
andSpotTargetCapacity
is smaller than the value of TotalTargetCapacity, the auto provisioning group will create instances of the specified type to meet the capacity requirements. Valid values:PayAsYouGo
: Pay-as-you-go instances;Spot
: Preemptible instances, Default value:Spot
. - Description string
- The description of the auto provisioning group.
- Excess
Capacity stringTermination Policy - The shutdown policy for excess preemptible instances followed when the capacity of the auto provisioning group exceeds the target capacity. Valid values:
no-termination
andtermination
,Default value:no-termination
. - Launch
Template stringVersion - The version of the instance launch template associated with the auto provisioning group.
- Max
Spot float64Price - The global maximum price for preemptible instances in the auto provisioning group. If both the
MaxSpotPrice
andLaunchTemplateConfig.N.MaxPrice
parameters are specified, the maximum price is the lower value of the two. - Pay
As stringYou Go Allocation Strategy - The scale-out policy for pay-as-you-go instances. Valid values:
lowest-price
andprioritized
,Default value:lowest-price
. - Pay
As stringYou Go Target Capacity - The target capacity of pay-as-you-go instances in the auto provisioning group.
- Spot
Allocation stringStrategy - The scale-out policy for preemptible instances. Valid values:
lowest-price
anddiversified
,Default value:lowest-price
. - Spot
Instance stringInterruption Behavior - The default behavior after preemptible instances are shut down. Valid values:
stop
andterminate
,Default value:stop
. - Spot
Instance intPools To Use Count - This parameter takes effect when the
SpotAllocationStrategy
parameter is set tolowest-price
. The auto provisioning group selects instance types of the lowest cost to create instances. - Spot
Target stringCapacity - The target capacity of preemptible instances in the auto provisioning group.
- Terminate
Instances bool - Specifies whether to release instances of the auto provisioning group. Valid values:
false
andtrue
, default value:false
. - Terminate
Instances boolWith Expiration - The shutdown policy for preemptible instances when the auto provisioning group expires. Valid values:
false
andtrue
, default value:false
. - Valid
From string - The time when the auto provisioning group is started. The period of time between this point in time and the point in time specified by the
valid_until
parameter is the effective time period of the auto provisioning group.By default, an auto provisioning group is immediately started after creation. - Valid
Until string - The time when the auto provisioning group expires. The period of time between this point in time and the point in time specified by the
valid_from
parameter is the effective time period of the auto provisioning group.By default, an auto provisioning group never expires.
- launch
Template List<AutoConfigs Provisioning Group Launch Template Config> - DataDisk mappings to attach to ecs instance. See
block-config
below for details. - launch
Template StringId - The ID of the instance launch template associated with the auto provisioning group.
- total
Target StringCapacity - The total target capacity of the auto provisioning group. The target capacity consists of the following three parts:PayAsYouGoTargetCapacity,SpotTargetCapacity and the supplemental capacity besides PayAsYouGoTargetCapacity and SpotTargetCapacity.
- auto
Provisioning StringGroup Name - The name of the auto provisioning group to be created. It 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 (-)
- auto
Provisioning StringGroup Type - The type of the auto provisioning group. Valid values:
request
andmaintain
,Default value:maintain
. - default
Target StringCapacity Type - The type of supplemental instances. When the total value of
PayAsYouGoTargetCapacity
andSpotTargetCapacity
is smaller than the value of TotalTargetCapacity, the auto provisioning group will create instances of the specified type to meet the capacity requirements. Valid values:PayAsYouGo
: Pay-as-you-go instances;Spot
: Preemptible instances, Default value:Spot
. - description String
- The description of the auto provisioning group.
- excess
Capacity StringTermination Policy - The shutdown policy for excess preemptible instances followed when the capacity of the auto provisioning group exceeds the target capacity. Valid values:
no-termination
andtermination
,Default value:no-termination
. - launch
Template StringVersion - The version of the instance launch template associated with the auto provisioning group.
- max
Spot DoublePrice - The global maximum price for preemptible instances in the auto provisioning group. If both the
MaxSpotPrice
andLaunchTemplateConfig.N.MaxPrice
parameters are specified, the maximum price is the lower value of the two. - pay
As StringYou Go Allocation Strategy - The scale-out policy for pay-as-you-go instances. Valid values:
lowest-price
andprioritized
,Default value:lowest-price
. - pay
As StringYou Go Target Capacity - The target capacity of pay-as-you-go instances in the auto provisioning group.
- spot
Allocation StringStrategy - The scale-out policy for preemptible instances. Valid values:
lowest-price
anddiversified
,Default value:lowest-price
. - spot
Instance StringInterruption Behavior - The default behavior after preemptible instances are shut down. Valid values:
stop
andterminate
,Default value:stop
. - spot
Instance IntegerPools To Use Count - This parameter takes effect when the
SpotAllocationStrategy
parameter is set tolowest-price
. The auto provisioning group selects instance types of the lowest cost to create instances. - spot
Target StringCapacity - The target capacity of preemptible instances in the auto provisioning group.
- terminate
Instances Boolean - Specifies whether to release instances of the auto provisioning group. Valid values:
false
andtrue
, default value:false
. - terminate
Instances BooleanWith Expiration - The shutdown policy for preemptible instances when the auto provisioning group expires. Valid values:
false
andtrue
, default value:false
. - valid
From String - The time when the auto provisioning group is started. The period of time between this point in time and the point in time specified by the
valid_until
parameter is the effective time period of the auto provisioning group.By default, an auto provisioning group is immediately started after creation. - valid
Until String - The time when the auto provisioning group expires. The period of time between this point in time and the point in time specified by the
valid_from
parameter is the effective time period of the auto provisioning group.By default, an auto provisioning group never expires.
- launch
Template AutoConfigs Provisioning Group Launch Template Config[] - DataDisk mappings to attach to ecs instance. See
block-config
below for details. - launch
Template stringId - The ID of the instance launch template associated with the auto provisioning group.
- total
Target stringCapacity - The total target capacity of the auto provisioning group. The target capacity consists of the following three parts:PayAsYouGoTargetCapacity,SpotTargetCapacity and the supplemental capacity besides PayAsYouGoTargetCapacity and SpotTargetCapacity.
- auto
Provisioning stringGroup Name - The name of the auto provisioning group to be created. It 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 (-)
- auto
Provisioning stringGroup Type - The type of the auto provisioning group. Valid values:
request
andmaintain
,Default value:maintain
. - default
Target stringCapacity Type - The type of supplemental instances. When the total value of
PayAsYouGoTargetCapacity
andSpotTargetCapacity
is smaller than the value of TotalTargetCapacity, the auto provisioning group will create instances of the specified type to meet the capacity requirements. Valid values:PayAsYouGo
: Pay-as-you-go instances;Spot
: Preemptible instances, Default value:Spot
. - description string
- The description of the auto provisioning group.
- excess
Capacity stringTermination Policy - The shutdown policy for excess preemptible instances followed when the capacity of the auto provisioning group exceeds the target capacity. Valid values:
no-termination
andtermination
,Default value:no-termination
. - launch
Template stringVersion - The version of the instance launch template associated with the auto provisioning group.
- max
Spot numberPrice - The global maximum price for preemptible instances in the auto provisioning group. If both the
MaxSpotPrice
andLaunchTemplateConfig.N.MaxPrice
parameters are specified, the maximum price is the lower value of the two. - pay
As stringYou Go Allocation Strategy - The scale-out policy for pay-as-you-go instances. Valid values:
lowest-price
andprioritized
,Default value:lowest-price
. - pay
As stringYou Go Target Capacity - The target capacity of pay-as-you-go instances in the auto provisioning group.
- spot
Allocation stringStrategy - The scale-out policy for preemptible instances. Valid values:
lowest-price
anddiversified
,Default value:lowest-price
. - spot
Instance stringInterruption Behavior - The default behavior after preemptible instances are shut down. Valid values:
stop
andterminate
,Default value:stop
. - spot
Instance numberPools To Use Count - This parameter takes effect when the
SpotAllocationStrategy
parameter is set tolowest-price
. The auto provisioning group selects instance types of the lowest cost to create instances. - spot
Target stringCapacity - The target capacity of preemptible instances in the auto provisioning group.
- terminate
Instances boolean - Specifies whether to release instances of the auto provisioning group. Valid values:
false
andtrue
, default value:false
. - terminate
Instances booleanWith Expiration - The shutdown policy for preemptible instances when the auto provisioning group expires. Valid values:
false
andtrue
, default value:false
. - valid
From string - The time when the auto provisioning group is started. The period of time between this point in time and the point in time specified by the
valid_until
parameter is the effective time period of the auto provisioning group.By default, an auto provisioning group is immediately started after creation. - valid
Until string - The time when the auto provisioning group expires. The period of time between this point in time and the point in time specified by the
valid_from
parameter is the effective time period of the auto provisioning group.By default, an auto provisioning group never expires.
- launch_
template_ Sequence[Autoconfigs Provisioning Group Launch Template Config Args] - DataDisk mappings to attach to ecs instance. See
block-config
below for details. - launch_
template_ strid - The ID of the instance launch template associated with the auto provisioning group.
- total_
target_ strcapacity - The total target capacity of the auto provisioning group. The target capacity consists of the following three parts:PayAsYouGoTargetCapacity,SpotTargetCapacity and the supplemental capacity besides PayAsYouGoTargetCapacity and SpotTargetCapacity.
- auto_
provisioning_ strgroup_ name - The name of the auto provisioning group to be created. It 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 (-)
- auto_
provisioning_ strgroup_ type - The type of the auto provisioning group. Valid values:
request
andmaintain
,Default value:maintain
. - default_
target_ strcapacity_ type - The type of supplemental instances. When the total value of
PayAsYouGoTargetCapacity
andSpotTargetCapacity
is smaller than the value of TotalTargetCapacity, the auto provisioning group will create instances of the specified type to meet the capacity requirements. Valid values:PayAsYouGo
: Pay-as-you-go instances;Spot
: Preemptible instances, Default value:Spot
. - description str
- The description of the auto provisioning group.
- excess_
capacity_ strtermination_ policy - The shutdown policy for excess preemptible instances followed when the capacity of the auto provisioning group exceeds the target capacity. Valid values:
no-termination
andtermination
,Default value:no-termination
. - launch_
template_ strversion - The version of the instance launch template associated with the auto provisioning group.
- max_
spot_ floatprice - The global maximum price for preemptible instances in the auto provisioning group. If both the
MaxSpotPrice
andLaunchTemplateConfig.N.MaxPrice
parameters are specified, the maximum price is the lower value of the two. - pay_
as_ stryou_ go_ allocation_ strategy - The scale-out policy for pay-as-you-go instances. Valid values:
lowest-price
andprioritized
,Default value:lowest-price
. - pay_
as_ stryou_ go_ target_ capacity - The target capacity of pay-as-you-go instances in the auto provisioning group.
- spot_
allocation_ strstrategy - The scale-out policy for preemptible instances. Valid values:
lowest-price
anddiversified
,Default value:lowest-price
. - spot_
instance_ strinterruption_ behavior - The default behavior after preemptible instances are shut down. Valid values:
stop
andterminate
,Default value:stop
. - spot_
instance_ intpools_ to_ use_ count - This parameter takes effect when the
SpotAllocationStrategy
parameter is set tolowest-price
. The auto provisioning group selects instance types of the lowest cost to create instances. - spot_
target_ strcapacity - The target capacity of preemptible instances in the auto provisioning group.
- terminate_
instances bool - Specifies whether to release instances of the auto provisioning group. Valid values:
false
andtrue
, default value:false
. - terminate_
instances_ boolwith_ expiration - The shutdown policy for preemptible instances when the auto provisioning group expires. Valid values:
false
andtrue
, default value:false
. - valid_
from str - The time when the auto provisioning group is started. The period of time between this point in time and the point in time specified by the
valid_until
parameter is the effective time period of the auto provisioning group.By default, an auto provisioning group is immediately started after creation. - valid_
until str - The time when the auto provisioning group expires. The period of time between this point in time and the point in time specified by the
valid_from
parameter is the effective time period of the auto provisioning group.By default, an auto provisioning group never expires.
- launch
Template List<Property Map>Configs - DataDisk mappings to attach to ecs instance. See
block-config
below for details. - launch
Template StringId - The ID of the instance launch template associated with the auto provisioning group.
- total
Target StringCapacity - The total target capacity of the auto provisioning group. The target capacity consists of the following three parts:PayAsYouGoTargetCapacity,SpotTargetCapacity and the supplemental capacity besides PayAsYouGoTargetCapacity and SpotTargetCapacity.
- auto
Provisioning StringGroup Name - The name of the auto provisioning group to be created. It 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 (-)
- auto
Provisioning StringGroup Type - The type of the auto provisioning group. Valid values:
request
andmaintain
,Default value:maintain
. - default
Target StringCapacity Type - The type of supplemental instances. When the total value of
PayAsYouGoTargetCapacity
andSpotTargetCapacity
is smaller than the value of TotalTargetCapacity, the auto provisioning group will create instances of the specified type to meet the capacity requirements. Valid values:PayAsYouGo
: Pay-as-you-go instances;Spot
: Preemptible instances, Default value:Spot
. - description String
- The description of the auto provisioning group.
- excess
Capacity StringTermination Policy - The shutdown policy for excess preemptible instances followed when the capacity of the auto provisioning group exceeds the target capacity. Valid values:
no-termination
andtermination
,Default value:no-termination
. - launch
Template StringVersion - The version of the instance launch template associated with the auto provisioning group.
- max
Spot NumberPrice - The global maximum price for preemptible instances in the auto provisioning group. If both the
MaxSpotPrice
andLaunchTemplateConfig.N.MaxPrice
parameters are specified, the maximum price is the lower value of the two. - pay
As StringYou Go Allocation Strategy - The scale-out policy for pay-as-you-go instances. Valid values:
lowest-price
andprioritized
,Default value:lowest-price
. - pay
As StringYou Go Target Capacity - The target capacity of pay-as-you-go instances in the auto provisioning group.
- spot
Allocation StringStrategy - The scale-out policy for preemptible instances. Valid values:
lowest-price
anddiversified
,Default value:lowest-price
. - spot
Instance StringInterruption Behavior - The default behavior after preemptible instances are shut down. Valid values:
stop
andterminate
,Default value:stop
. - spot
Instance NumberPools To Use Count - This parameter takes effect when the
SpotAllocationStrategy
parameter is set tolowest-price
. The auto provisioning group selects instance types of the lowest cost to create instances. - spot
Target StringCapacity - The target capacity of preemptible instances in the auto provisioning group.
- terminate
Instances Boolean - Specifies whether to release instances of the auto provisioning group. Valid values:
false
andtrue
, default value:false
. - terminate
Instances BooleanWith Expiration - The shutdown policy for preemptible instances when the auto provisioning group expires. Valid values:
false
andtrue
, default value:false
. - valid
From String - The time when the auto provisioning group is started. The period of time between this point in time and the point in time specified by the
valid_until
parameter is the effective time period of the auto provisioning group.By default, an auto provisioning group is immediately started after creation. - valid
Until String - The time when the auto provisioning group expires. The period of time between this point in time and the point in time specified by the
valid_from
parameter is the effective time period of the auto provisioning group.By default, an auto provisioning group never expires.
Outputs
All input properties are implicitly available as output properties. Additionally, the AutoProvisioningGroup resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing AutoProvisioningGroup Resource
Get an existing AutoProvisioningGroup 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?: AutoProvisioningGroupState, opts?: CustomResourceOptions): AutoProvisioningGroup
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
auto_provisioning_group_name: Optional[str] = None,
auto_provisioning_group_type: Optional[str] = None,
default_target_capacity_type: Optional[str] = None,
description: Optional[str] = None,
excess_capacity_termination_policy: Optional[str] = None,
launch_template_configs: Optional[Sequence[AutoProvisioningGroupLaunchTemplateConfigArgs]] = None,
launch_template_id: Optional[str] = None,
launch_template_version: Optional[str] = None,
max_spot_price: Optional[float] = None,
pay_as_you_go_allocation_strategy: Optional[str] = None,
pay_as_you_go_target_capacity: Optional[str] = None,
spot_allocation_strategy: Optional[str] = None,
spot_instance_interruption_behavior: Optional[str] = None,
spot_instance_pools_to_use_count: Optional[int] = None,
spot_target_capacity: Optional[str] = None,
terminate_instances: Optional[bool] = None,
terminate_instances_with_expiration: Optional[bool] = None,
total_target_capacity: Optional[str] = None,
valid_from: Optional[str] = None,
valid_until: Optional[str] = None) -> AutoProvisioningGroup
func GetAutoProvisioningGroup(ctx *Context, name string, id IDInput, state *AutoProvisioningGroupState, opts ...ResourceOption) (*AutoProvisioningGroup, error)
public static AutoProvisioningGroup Get(string name, Input<string> id, AutoProvisioningGroupState? state, CustomResourceOptions? opts = null)
public static AutoProvisioningGroup get(String name, Output<String> id, AutoProvisioningGroupState 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.
- Auto
Provisioning stringGroup Name - The name of the auto provisioning group to be created. It 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 (-)
- Auto
Provisioning stringGroup Type - The type of the auto provisioning group. Valid values:
request
andmaintain
,Default value:maintain
. - Default
Target stringCapacity Type - The type of supplemental instances. When the total value of
PayAsYouGoTargetCapacity
andSpotTargetCapacity
is smaller than the value of TotalTargetCapacity, the auto provisioning group will create instances of the specified type to meet the capacity requirements. Valid values:PayAsYouGo
: Pay-as-you-go instances;Spot
: Preemptible instances, Default value:Spot
. - Description string
- The description of the auto provisioning group.
- Excess
Capacity stringTermination Policy - The shutdown policy for excess preemptible instances followed when the capacity of the auto provisioning group exceeds the target capacity. Valid values:
no-termination
andtermination
,Default value:no-termination
. - Launch
Template List<Pulumi.Configs Ali Cloud. Ecs. Inputs. Auto Provisioning Group Launch Template Config> - DataDisk mappings to attach to ecs instance. See
block-config
below for details. - Launch
Template stringId - The ID of the instance launch template associated with the auto provisioning group.
- Launch
Template stringVersion - The version of the instance launch template associated with the auto provisioning group.
- Max
Spot doublePrice - The global maximum price for preemptible instances in the auto provisioning group. If both the
MaxSpotPrice
andLaunchTemplateConfig.N.MaxPrice
parameters are specified, the maximum price is the lower value of the two. - Pay
As stringYou Go Allocation Strategy - The scale-out policy for pay-as-you-go instances. Valid values:
lowest-price
andprioritized
,Default value:lowest-price
. - Pay
As stringYou Go Target Capacity - The target capacity of pay-as-you-go instances in the auto provisioning group.
- Spot
Allocation stringStrategy - The scale-out policy for preemptible instances. Valid values:
lowest-price
anddiversified
,Default value:lowest-price
. - Spot
Instance stringInterruption Behavior - The default behavior after preemptible instances are shut down. Valid values:
stop
andterminate
,Default value:stop
. - Spot
Instance intPools To Use Count - This parameter takes effect when the
SpotAllocationStrategy
parameter is set tolowest-price
. The auto provisioning group selects instance types of the lowest cost to create instances. - Spot
Target stringCapacity - The target capacity of preemptible instances in the auto provisioning group.
- Terminate
Instances bool - Specifies whether to release instances of the auto provisioning group. Valid values:
false
andtrue
, default value:false
. - Terminate
Instances boolWith Expiration - The shutdown policy for preemptible instances when the auto provisioning group expires. Valid values:
false
andtrue
, default value:false
. - Total
Target stringCapacity - The total target capacity of the auto provisioning group. The target capacity consists of the following three parts:PayAsYouGoTargetCapacity,SpotTargetCapacity and the supplemental capacity besides PayAsYouGoTargetCapacity and SpotTargetCapacity.
- Valid
From string - The time when the auto provisioning group is started. The period of time between this point in time and the point in time specified by the
valid_until
parameter is the effective time period of the auto provisioning group.By default, an auto provisioning group is immediately started after creation. - Valid
Until string - The time when the auto provisioning group expires. The period of time between this point in time and the point in time specified by the
valid_from
parameter is the effective time period of the auto provisioning group.By default, an auto provisioning group never expires.
- Auto
Provisioning stringGroup Name - The name of the auto provisioning group to be created. It 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 (-)
- Auto
Provisioning stringGroup Type - The type of the auto provisioning group. Valid values:
request
andmaintain
,Default value:maintain
. - Default
Target stringCapacity Type - The type of supplemental instances. When the total value of
PayAsYouGoTargetCapacity
andSpotTargetCapacity
is smaller than the value of TotalTargetCapacity, the auto provisioning group will create instances of the specified type to meet the capacity requirements. Valid values:PayAsYouGo
: Pay-as-you-go instances;Spot
: Preemptible instances, Default value:Spot
. - Description string
- The description of the auto provisioning group.
- Excess
Capacity stringTermination Policy - The shutdown policy for excess preemptible instances followed when the capacity of the auto provisioning group exceeds the target capacity. Valid values:
no-termination
andtermination
,Default value:no-termination
. - Launch
Template []AutoConfigs Provisioning Group Launch Template Config Args - DataDisk mappings to attach to ecs instance. See
block-config
below for details. - Launch
Template stringId - The ID of the instance launch template associated with the auto provisioning group.
- Launch
Template stringVersion - The version of the instance launch template associated with the auto provisioning group.
- Max
Spot float64Price - The global maximum price for preemptible instances in the auto provisioning group. If both the
MaxSpotPrice
andLaunchTemplateConfig.N.MaxPrice
parameters are specified, the maximum price is the lower value of the two. - Pay
As stringYou Go Allocation Strategy - The scale-out policy for pay-as-you-go instances. Valid values:
lowest-price
andprioritized
,Default value:lowest-price
. - Pay
As stringYou Go Target Capacity - The target capacity of pay-as-you-go instances in the auto provisioning group.
- Spot
Allocation stringStrategy - The scale-out policy for preemptible instances. Valid values:
lowest-price
anddiversified
,Default value:lowest-price
. - Spot
Instance stringInterruption Behavior - The default behavior after preemptible instances are shut down. Valid values:
stop
andterminate
,Default value:stop
. - Spot
Instance intPools To Use Count - This parameter takes effect when the
SpotAllocationStrategy
parameter is set tolowest-price
. The auto provisioning group selects instance types of the lowest cost to create instances. - Spot
Target stringCapacity - The target capacity of preemptible instances in the auto provisioning group.
- Terminate
Instances bool - Specifies whether to release instances of the auto provisioning group. Valid values:
false
andtrue
, default value:false
. - Terminate
Instances boolWith Expiration - The shutdown policy for preemptible instances when the auto provisioning group expires. Valid values:
false
andtrue
, default value:false
. - Total
Target stringCapacity - The total target capacity of the auto provisioning group. The target capacity consists of the following three parts:PayAsYouGoTargetCapacity,SpotTargetCapacity and the supplemental capacity besides PayAsYouGoTargetCapacity and SpotTargetCapacity.
- Valid
From string - The time when the auto provisioning group is started. The period of time between this point in time and the point in time specified by the
valid_until
parameter is the effective time period of the auto provisioning group.By default, an auto provisioning group is immediately started after creation. - Valid
Until string - The time when the auto provisioning group expires. The period of time between this point in time and the point in time specified by the
valid_from
parameter is the effective time period of the auto provisioning group.By default, an auto provisioning group never expires.
- auto
Provisioning StringGroup Name - The name of the auto provisioning group to be created. It 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 (-)
- auto
Provisioning StringGroup Type - The type of the auto provisioning group. Valid values:
request
andmaintain
,Default value:maintain
. - default
Target StringCapacity Type - The type of supplemental instances. When the total value of
PayAsYouGoTargetCapacity
andSpotTargetCapacity
is smaller than the value of TotalTargetCapacity, the auto provisioning group will create instances of the specified type to meet the capacity requirements. Valid values:PayAsYouGo
: Pay-as-you-go instances;Spot
: Preemptible instances, Default value:Spot
. - description String
- The description of the auto provisioning group.
- excess
Capacity StringTermination Policy - The shutdown policy for excess preemptible instances followed when the capacity of the auto provisioning group exceeds the target capacity. Valid values:
no-termination
andtermination
,Default value:no-termination
. - launch
Template List<AutoConfigs Provisioning Group Launch Template Config> - DataDisk mappings to attach to ecs instance. See
block-config
below for details. - launch
Template StringId - The ID of the instance launch template associated with the auto provisioning group.
- launch
Template StringVersion - The version of the instance launch template associated with the auto provisioning group.
- max
Spot DoublePrice - The global maximum price for preemptible instances in the auto provisioning group. If both the
MaxSpotPrice
andLaunchTemplateConfig.N.MaxPrice
parameters are specified, the maximum price is the lower value of the two. - pay
As StringYou Go Allocation Strategy - The scale-out policy for pay-as-you-go instances. Valid values:
lowest-price
andprioritized
,Default value:lowest-price
. - pay
As StringYou Go Target Capacity - The target capacity of pay-as-you-go instances in the auto provisioning group.
- spot
Allocation StringStrategy - The scale-out policy for preemptible instances. Valid values:
lowest-price
anddiversified
,Default value:lowest-price
. - spot
Instance StringInterruption Behavior - The default behavior after preemptible instances are shut down. Valid values:
stop
andterminate
,Default value:stop
. - spot
Instance IntegerPools To Use Count - This parameter takes effect when the
SpotAllocationStrategy
parameter is set tolowest-price
. The auto provisioning group selects instance types of the lowest cost to create instances. - spot
Target StringCapacity - The target capacity of preemptible instances in the auto provisioning group.
- terminate
Instances Boolean - Specifies whether to release instances of the auto provisioning group. Valid values:
false
andtrue
, default value:false
. - terminate
Instances BooleanWith Expiration - The shutdown policy for preemptible instances when the auto provisioning group expires. Valid values:
false
andtrue
, default value:false
. - total
Target StringCapacity - The total target capacity of the auto provisioning group. The target capacity consists of the following three parts:PayAsYouGoTargetCapacity,SpotTargetCapacity and the supplemental capacity besides PayAsYouGoTargetCapacity and SpotTargetCapacity.
- valid
From String - The time when the auto provisioning group is started. The period of time between this point in time and the point in time specified by the
valid_until
parameter is the effective time period of the auto provisioning group.By default, an auto provisioning group is immediately started after creation. - valid
Until String - The time when the auto provisioning group expires. The period of time between this point in time and the point in time specified by the
valid_from
parameter is the effective time period of the auto provisioning group.By default, an auto provisioning group never expires.
- auto
Provisioning stringGroup Name - The name of the auto provisioning group to be created. It 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 (-)
- auto
Provisioning stringGroup Type - The type of the auto provisioning group. Valid values:
request
andmaintain
,Default value:maintain
. - default
Target stringCapacity Type - The type of supplemental instances. When the total value of
PayAsYouGoTargetCapacity
andSpotTargetCapacity
is smaller than the value of TotalTargetCapacity, the auto provisioning group will create instances of the specified type to meet the capacity requirements. Valid values:PayAsYouGo
: Pay-as-you-go instances;Spot
: Preemptible instances, Default value:Spot
. - description string
- The description of the auto provisioning group.
- excess
Capacity stringTermination Policy - The shutdown policy for excess preemptible instances followed when the capacity of the auto provisioning group exceeds the target capacity. Valid values:
no-termination
andtermination
,Default value:no-termination
. - launch
Template AutoConfigs Provisioning Group Launch Template Config[] - DataDisk mappings to attach to ecs instance. See
block-config
below for details. - launch
Template stringId - The ID of the instance launch template associated with the auto provisioning group.
- launch
Template stringVersion - The version of the instance launch template associated with the auto provisioning group.
- max
Spot numberPrice - The global maximum price for preemptible instances in the auto provisioning group. If both the
MaxSpotPrice
andLaunchTemplateConfig.N.MaxPrice
parameters are specified, the maximum price is the lower value of the two. - pay
As stringYou Go Allocation Strategy - The scale-out policy for pay-as-you-go instances. Valid values:
lowest-price
andprioritized
,Default value:lowest-price
. - pay
As stringYou Go Target Capacity - The target capacity of pay-as-you-go instances in the auto provisioning group.
- spot
Allocation stringStrategy - The scale-out policy for preemptible instances. Valid values:
lowest-price
anddiversified
,Default value:lowest-price
. - spot
Instance stringInterruption Behavior - The default behavior after preemptible instances are shut down. Valid values:
stop
andterminate
,Default value:stop
. - spot
Instance numberPools To Use Count - This parameter takes effect when the
SpotAllocationStrategy
parameter is set tolowest-price
. The auto provisioning group selects instance types of the lowest cost to create instances. - spot
Target stringCapacity - The target capacity of preemptible instances in the auto provisioning group.
- terminate
Instances boolean - Specifies whether to release instances of the auto provisioning group. Valid values:
false
andtrue
, default value:false
. - terminate
Instances booleanWith Expiration - The shutdown policy for preemptible instances when the auto provisioning group expires. Valid values:
false
andtrue
, default value:false
. - total
Target stringCapacity - The total target capacity of the auto provisioning group. The target capacity consists of the following three parts:PayAsYouGoTargetCapacity,SpotTargetCapacity and the supplemental capacity besides PayAsYouGoTargetCapacity and SpotTargetCapacity.
- valid
From string - The time when the auto provisioning group is started. The period of time between this point in time and the point in time specified by the
valid_until
parameter is the effective time period of the auto provisioning group.By default, an auto provisioning group is immediately started after creation. - valid
Until string - The time when the auto provisioning group expires. The period of time between this point in time and the point in time specified by the
valid_from
parameter is the effective time period of the auto provisioning group.By default, an auto provisioning group never expires.
- auto_
provisioning_ strgroup_ name - The name of the auto provisioning group to be created. It 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 (-)
- auto_
provisioning_ strgroup_ type - The type of the auto provisioning group. Valid values:
request
andmaintain
,Default value:maintain
. - default_
target_ strcapacity_ type - The type of supplemental instances. When the total value of
PayAsYouGoTargetCapacity
andSpotTargetCapacity
is smaller than the value of TotalTargetCapacity, the auto provisioning group will create instances of the specified type to meet the capacity requirements. Valid values:PayAsYouGo
: Pay-as-you-go instances;Spot
: Preemptible instances, Default value:Spot
. - description str
- The description of the auto provisioning group.
- excess_
capacity_ strtermination_ policy - The shutdown policy for excess preemptible instances followed when the capacity of the auto provisioning group exceeds the target capacity. Valid values:
no-termination
andtermination
,Default value:no-termination
. - launch_
template_ Sequence[Autoconfigs Provisioning Group Launch Template Config Args] - DataDisk mappings to attach to ecs instance. See
block-config
below for details. - launch_
template_ strid - The ID of the instance launch template associated with the auto provisioning group.
- launch_
template_ strversion - The version of the instance launch template associated with the auto provisioning group.
- max_
spot_ floatprice - The global maximum price for preemptible instances in the auto provisioning group. If both the
MaxSpotPrice
andLaunchTemplateConfig.N.MaxPrice
parameters are specified, the maximum price is the lower value of the two. - pay_
as_ stryou_ go_ allocation_ strategy - The scale-out policy for pay-as-you-go instances. Valid values:
lowest-price
andprioritized
,Default value:lowest-price
. - pay_
as_ stryou_ go_ target_ capacity - The target capacity of pay-as-you-go instances in the auto provisioning group.
- spot_
allocation_ strstrategy - The scale-out policy for preemptible instances. Valid values:
lowest-price
anddiversified
,Default value:lowest-price
. - spot_
instance_ strinterruption_ behavior - The default behavior after preemptible instances are shut down. Valid values:
stop
andterminate
,Default value:stop
. - spot_
instance_ intpools_ to_ use_ count - This parameter takes effect when the
SpotAllocationStrategy
parameter is set tolowest-price
. The auto provisioning group selects instance types of the lowest cost to create instances. - spot_
target_ strcapacity - The target capacity of preemptible instances in the auto provisioning group.
- terminate_
instances bool - Specifies whether to release instances of the auto provisioning group. Valid values:
false
andtrue
, default value:false
. - terminate_
instances_ boolwith_ expiration - The shutdown policy for preemptible instances when the auto provisioning group expires. Valid values:
false
andtrue
, default value:false
. - total_
target_ strcapacity - The total target capacity of the auto provisioning group. The target capacity consists of the following three parts:PayAsYouGoTargetCapacity,SpotTargetCapacity and the supplemental capacity besides PayAsYouGoTargetCapacity and SpotTargetCapacity.
- valid_
from str - The time when the auto provisioning group is started. The period of time between this point in time and the point in time specified by the
valid_until
parameter is the effective time period of the auto provisioning group.By default, an auto provisioning group is immediately started after creation. - valid_
until str - The time when the auto provisioning group expires. The period of time between this point in time and the point in time specified by the
valid_from
parameter is the effective time period of the auto provisioning group.By default, an auto provisioning group never expires.
- auto
Provisioning StringGroup Name - The name of the auto provisioning group to be created. It 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 (-)
- auto
Provisioning StringGroup Type - The type of the auto provisioning group. Valid values:
request
andmaintain
,Default value:maintain
. - default
Target StringCapacity Type - The type of supplemental instances. When the total value of
PayAsYouGoTargetCapacity
andSpotTargetCapacity
is smaller than the value of TotalTargetCapacity, the auto provisioning group will create instances of the specified type to meet the capacity requirements. Valid values:PayAsYouGo
: Pay-as-you-go instances;Spot
: Preemptible instances, Default value:Spot
. - description String
- The description of the auto provisioning group.
- excess
Capacity StringTermination Policy - The shutdown policy for excess preemptible instances followed when the capacity of the auto provisioning group exceeds the target capacity. Valid values:
no-termination
andtermination
,Default value:no-termination
. - launch
Template List<Property Map>Configs - DataDisk mappings to attach to ecs instance. See
block-config
below for details. - launch
Template StringId - The ID of the instance launch template associated with the auto provisioning group.
- launch
Template StringVersion - The version of the instance launch template associated with the auto provisioning group.
- max
Spot NumberPrice - The global maximum price for preemptible instances in the auto provisioning group. If both the
MaxSpotPrice
andLaunchTemplateConfig.N.MaxPrice
parameters are specified, the maximum price is the lower value of the two. - pay
As StringYou Go Allocation Strategy - The scale-out policy for pay-as-you-go instances. Valid values:
lowest-price
andprioritized
,Default value:lowest-price
. - pay
As StringYou Go Target Capacity - The target capacity of pay-as-you-go instances in the auto provisioning group.
- spot
Allocation StringStrategy - The scale-out policy for preemptible instances. Valid values:
lowest-price
anddiversified
,Default value:lowest-price
. - spot
Instance StringInterruption Behavior - The default behavior after preemptible instances are shut down. Valid values:
stop
andterminate
,Default value:stop
. - spot
Instance NumberPools To Use Count - This parameter takes effect when the
SpotAllocationStrategy
parameter is set tolowest-price
. The auto provisioning group selects instance types of the lowest cost to create instances. - spot
Target StringCapacity - The target capacity of preemptible instances in the auto provisioning group.
- terminate
Instances Boolean - Specifies whether to release instances of the auto provisioning group. Valid values:
false
andtrue
, default value:false
. - terminate
Instances BooleanWith Expiration - The shutdown policy for preemptible instances when the auto provisioning group expires. Valid values:
false
andtrue
, default value:false
. - total
Target StringCapacity - The total target capacity of the auto provisioning group. The target capacity consists of the following three parts:PayAsYouGoTargetCapacity,SpotTargetCapacity and the supplemental capacity besides PayAsYouGoTargetCapacity and SpotTargetCapacity.
- valid
From String - The time when the auto provisioning group is started. The period of time between this point in time and the point in time specified by the
valid_until
parameter is the effective time period of the auto provisioning group.By default, an auto provisioning group is immediately started after creation. - valid
Until String - The time when the auto provisioning group expires. The period of time between this point in time and the point in time specified by the
valid_from
parameter is the effective time period of the auto provisioning group.By default, an auto provisioning group never expires.
Supporting Types
AutoProvisioningGroupLaunchTemplateConfig, AutoProvisioningGroupLaunchTemplateConfigArgs
- Max
Price string - Vswitch
Id string - Weighted
Capacity string - Instance
Type string - Priority string
- Max
Price string - Vswitch
Id string - Weighted
Capacity string - Instance
Type string - Priority string
- max
Price String - vswitch
Id String - weighted
Capacity String - instance
Type String - priority String
- max
Price string - vswitch
Id string - weighted
Capacity string - instance
Type string - priority string
- max_
price str - vswitch_
id str - weighted_
capacity str - instance_
type str - priority str
- max
Price String - vswitch
Id String - weighted
Capacity String - instance
Type String - priority String
Import
ECS auto provisioning group can be imported using the id, e.g.
$ pulumi import alicloud:ecs/autoProvisioningGroup:AutoProvisioningGroup example asg-abc123456
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
alicloud
Terraform Provider.