Fleet

Provides a resource to manage EC2 Fleets.

Example Usage

using Pulumi;
using Aws = Pulumi.Aws;

class MyStack : Stack
{
    public MyStack()
    {
        var example = new Aws.Ec2.Fleet("example", new Aws.Ec2.FleetArgs
        {
            LaunchTemplateConfig = new Aws.Ec2.Inputs.FleetLaunchTemplateConfigArgs
            {
                LaunchTemplateSpecification = new Aws.Ec2.Inputs.FleetLaunchTemplateConfigLaunchTemplateSpecificationArgs
                {
                    LaunchTemplateId = aws_launch_template.Example.Id,
                    Version = aws_launch_template.Example.Latest_version,
                },
            },
            TargetCapacitySpecification = new Aws.Ec2.Inputs.FleetTargetCapacitySpecificationArgs
            {
                DefaultTargetCapacityType = "spot",
                TotalTargetCapacity = 5,
            },
        });
    }

}
package main

import (
	"github.com/pulumi/pulumi-aws/sdk/v4/go/aws/ec2"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := ec2.NewFleet(ctx, "example", &ec2.FleetArgs{
			LaunchTemplateConfig: &ec2.FleetLaunchTemplateConfigArgs{
				LaunchTemplateSpecification: &ec2.FleetLaunchTemplateConfigLaunchTemplateSpecificationArgs{
					LaunchTemplateId: pulumi.Any(aws_launch_template.Example.Id),
					Version:          pulumi.Any(aws_launch_template.Example.Latest_version),
				},
			},
			TargetCapacitySpecification: &ec2.FleetTargetCapacitySpecificationArgs{
				DefaultTargetCapacityType: pulumi.String("spot"),
				TotalTargetCapacity:       pulumi.Int(5),
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}
import pulumi
import pulumi_aws as aws

example = aws.ec2.Fleet("example",
    launch_template_config=aws.ec2.FleetLaunchTemplateConfigArgs(
        launch_template_specification=aws.ec2.FleetLaunchTemplateConfigLaunchTemplateSpecificationArgs(
            launch_template_id=aws_launch_template["example"]["id"],
            version=aws_launch_template["example"]["latest_version"],
        ),
    ),
    target_capacity_specification=aws.ec2.FleetTargetCapacitySpecificationArgs(
        default_target_capacity_type="spot",
        total_target_capacity=5,
    ))
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";

const example = new aws.ec2.Fleet("example", {
    launchTemplateConfig: {
        launchTemplateSpecification: {
            launchTemplateId: aws_launch_template.example.id,
            version: aws_launch_template.example.latest_version,
        },
    },
    targetCapacitySpecification: {
        defaultTargetCapacityType: "spot",
        totalTargetCapacity: 5,
    },
});

Create a Fleet Resource

new Fleet(name: string, args: FleetArgs, opts?: CustomResourceOptions);
@overload
def Fleet(resource_name: str,
          opts: Optional[ResourceOptions] = None,
          excess_capacity_termination_policy: Optional[str] = None,
          launch_template_config: Optional[FleetLaunchTemplateConfigArgs] = None,
          on_demand_options: Optional[FleetOnDemandOptionsArgs] = None,
          replace_unhealthy_instances: Optional[bool] = None,
          spot_options: Optional[FleetSpotOptionsArgs] = None,
          tags: Optional[Mapping[str, str]] = None,
          tags_all: Optional[Mapping[str, str]] = None,
          target_capacity_specification: Optional[FleetTargetCapacitySpecificationArgs] = None,
          terminate_instances: Optional[bool] = None,
          terminate_instances_with_expiration: Optional[bool] = None,
          type: Optional[str] = None)
@overload
def Fleet(resource_name: str,
          args: FleetArgs,
          opts: Optional[ResourceOptions] = None)
func NewFleet(ctx *Context, name string, args FleetArgs, opts ...ResourceOption) (*Fleet, error)
public Fleet(string name, FleetArgs args, CustomResourceOptions? opts = null)
name string
The unique name of the resource.
args FleetArgs
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 FleetArgs
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 FleetArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args FleetArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.

Fleet Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Programming Model docs.

Inputs

The Fleet resource accepts the following input properties:

LaunchTemplateConfig FleetLaunchTemplateConfigArgs
Nested argument containing EC2 Launch Template configurations. Defined below.
TargetCapacitySpecification FleetTargetCapacitySpecificationArgs
Nested argument containing target capacity configurations. Defined below.
ExcessCapacityTerminationPolicy string
Whether running instances should be terminated if the total target capacity of the EC2 Fleet is decreased below the current size of the EC2. Valid values: no-termination, termination. Defaults to termination.
OnDemandOptions FleetOnDemandOptionsArgs
Nested argument containing On-Demand configurations. Defined below.
ReplaceUnhealthyInstances bool
Whether EC2 Fleet should replace unhealthy instances. Defaults to false.
SpotOptions FleetSpotOptionsArgs
Nested argument containing Spot configurations. Defined below.
Tags Dictionary<string, string>
TagsAll Dictionary<string, string>
TerminateInstances bool
Whether to terminate instances for an EC2 Fleet if it is deleted successfully. Defaults to false.
TerminateInstancesWithExpiration bool
Whether running instances should be terminated when the EC2 Fleet expires. Defaults to false.
Type string
The type of request. Indicates whether the EC2 Fleet only requests the target capacity, or also attempts to maintain it. Valid values: maintain, request. Defaults to maintain.
LaunchTemplateConfig FleetLaunchTemplateConfig
Nested argument containing EC2 Launch Template configurations. Defined below.
TargetCapacitySpecification FleetTargetCapacitySpecification
Nested argument containing target capacity configurations. Defined below.
ExcessCapacityTerminationPolicy string
Whether running instances should be terminated if the total target capacity of the EC2 Fleet is decreased below the current size of the EC2. Valid values: no-termination, termination. Defaults to termination.
OnDemandOptions FleetOnDemandOptions
Nested argument containing On-Demand configurations. Defined below.
ReplaceUnhealthyInstances bool
Whether EC2 Fleet should replace unhealthy instances. Defaults to false.
SpotOptions FleetSpotOptions
Nested argument containing Spot configurations. Defined below.
Tags map[string]string
TagsAll map[string]string
TerminateInstances bool
Whether to terminate instances for an EC2 Fleet if it is deleted successfully. Defaults to false.
TerminateInstancesWithExpiration bool
Whether running instances should be terminated when the EC2 Fleet expires. Defaults to false.
Type string
The type of request. Indicates whether the EC2 Fleet only requests the target capacity, or also attempts to maintain it. Valid values: maintain, request. Defaults to maintain.
launchTemplateConfig FleetLaunchTemplateConfigArgs
Nested argument containing EC2 Launch Template configurations. Defined below.
targetCapacitySpecification FleetTargetCapacitySpecificationArgs
Nested argument containing target capacity configurations. Defined below.
excessCapacityTerminationPolicy string
Whether running instances should be terminated if the total target capacity of the EC2 Fleet is decreased below the current size of the EC2. Valid values: no-termination, termination. Defaults to termination.
onDemandOptions FleetOnDemandOptionsArgs
Nested argument containing On-Demand configurations. Defined below.
replaceUnhealthyInstances boolean
Whether EC2 Fleet should replace unhealthy instances. Defaults to false.
spotOptions FleetSpotOptionsArgs
Nested argument containing Spot configurations. Defined below.
tags {[key: string]: string}
tagsAll {[key: string]: string}
terminateInstances boolean
Whether to terminate instances for an EC2 Fleet if it is deleted successfully. Defaults to false.
terminateInstancesWithExpiration boolean
Whether running instances should be terminated when the EC2 Fleet expires. Defaults to false.
type string
The type of request. Indicates whether the EC2 Fleet only requests the target capacity, or also attempts to maintain it. Valid values: maintain, request. Defaults to maintain.
launch_template_config FleetLaunchTemplateConfigArgs
Nested argument containing EC2 Launch Template configurations. Defined below.
target_capacity_specification FleetTargetCapacitySpecificationArgs
Nested argument containing target capacity configurations. Defined below.
excess_capacity_termination_policy str
Whether running instances should be terminated if the total target capacity of the EC2 Fleet is decreased below the current size of the EC2. Valid values: no-termination, termination. Defaults to termination.
on_demand_options FleetOnDemandOptionsArgs
Nested argument containing On-Demand configurations. Defined below.
replace_unhealthy_instances bool
Whether EC2 Fleet should replace unhealthy instances. Defaults to false.
spot_options FleetSpotOptionsArgs
Nested argument containing Spot configurations. Defined below.
tags Mapping[str, str]
tags_all Mapping[str, str]
terminate_instances bool
Whether to terminate instances for an EC2 Fleet if it is deleted successfully. Defaults to false.
terminate_instances_with_expiration bool
Whether running instances should be terminated when the EC2 Fleet expires. Defaults to false.
type str
The type of request. Indicates whether the EC2 Fleet only requests the target capacity, or also attempts to maintain it. Valid values: maintain, request. Defaults to maintain.

Outputs

All input properties are implicitly available as output properties. Additionally, the Fleet 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 str
The provider-assigned unique ID for this managed resource.

Look up an Existing Fleet Resource

Get an existing Fleet 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?: FleetState, opts?: CustomResourceOptions): Fleet
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        excess_capacity_termination_policy: Optional[str] = None,
        launch_template_config: Optional[FleetLaunchTemplateConfigArgs] = None,
        on_demand_options: Optional[FleetOnDemandOptionsArgs] = None,
        replace_unhealthy_instances: Optional[bool] = None,
        spot_options: Optional[FleetSpotOptionsArgs] = None,
        tags: Optional[Mapping[str, str]] = None,
        tags_all: Optional[Mapping[str, str]] = None,
        target_capacity_specification: Optional[FleetTargetCapacitySpecificationArgs] = None,
        terminate_instances: Optional[bool] = None,
        terminate_instances_with_expiration: Optional[bool] = None,
        type: Optional[str] = None) -> Fleet
func GetFleet(ctx *Context, name string, id IDInput, state *FleetState, opts ...ResourceOption) (*Fleet, error)
public static Fleet Get(string name, Input<string> id, FleetState? state, CustomResourceOptions? opts = null)
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.

The following state arguments are supported:

ExcessCapacityTerminationPolicy string
Whether running instances should be terminated if the total target capacity of the EC2 Fleet is decreased below the current size of the EC2. Valid values: no-termination, termination. Defaults to termination.
LaunchTemplateConfig FleetLaunchTemplateConfigArgs
Nested argument containing EC2 Launch Template configurations. Defined below.
OnDemandOptions FleetOnDemandOptionsArgs
Nested argument containing On-Demand configurations. Defined below.
ReplaceUnhealthyInstances bool
Whether EC2 Fleet should replace unhealthy instances. Defaults to false.
SpotOptions FleetSpotOptionsArgs
Nested argument containing Spot configurations. Defined below.
Tags Dictionary<string, string>
TagsAll Dictionary<string, string>
TargetCapacitySpecification FleetTargetCapacitySpecificationArgs
Nested argument containing target capacity configurations. Defined below.
TerminateInstances bool
Whether to terminate instances for an EC2 Fleet if it is deleted successfully. Defaults to false.
TerminateInstancesWithExpiration bool
Whether running instances should be terminated when the EC2 Fleet expires. Defaults to false.
Type string
The type of request. Indicates whether the EC2 Fleet only requests the target capacity, or also attempts to maintain it. Valid values: maintain, request. Defaults to maintain.
ExcessCapacityTerminationPolicy string
Whether running instances should be terminated if the total target capacity of the EC2 Fleet is decreased below the current size of the EC2. Valid values: no-termination, termination. Defaults to termination.
LaunchTemplateConfig FleetLaunchTemplateConfig
Nested argument containing EC2 Launch Template configurations. Defined below.
OnDemandOptions FleetOnDemandOptions
Nested argument containing On-Demand configurations. Defined below.
ReplaceUnhealthyInstances bool
Whether EC2 Fleet should replace unhealthy instances. Defaults to false.
SpotOptions FleetSpotOptions
Nested argument containing Spot configurations. Defined below.
Tags map[string]string
TagsAll map[string]string
TargetCapacitySpecification FleetTargetCapacitySpecification
Nested argument containing target capacity configurations. Defined below.
TerminateInstances bool
Whether to terminate instances for an EC2 Fleet if it is deleted successfully. Defaults to false.
TerminateInstancesWithExpiration bool
Whether running instances should be terminated when the EC2 Fleet expires. Defaults to false.
Type string
The type of request. Indicates whether the EC2 Fleet only requests the target capacity, or also attempts to maintain it. Valid values: maintain, request. Defaults to maintain.
excessCapacityTerminationPolicy string
Whether running instances should be terminated if the total target capacity of the EC2 Fleet is decreased below the current size of the EC2. Valid values: no-termination, termination. Defaults to termination.
launchTemplateConfig FleetLaunchTemplateConfigArgs
Nested argument containing EC2 Launch Template configurations. Defined below.
onDemandOptions FleetOnDemandOptionsArgs
Nested argument containing On-Demand configurations. Defined below.
replaceUnhealthyInstances boolean
Whether EC2 Fleet should replace unhealthy instances. Defaults to false.
spotOptions FleetSpotOptionsArgs
Nested argument containing Spot configurations. Defined below.
tags {[key: string]: string}
tagsAll {[key: string]: string}
targetCapacitySpecification FleetTargetCapacitySpecificationArgs
Nested argument containing target capacity configurations. Defined below.
terminateInstances boolean
Whether to terminate instances for an EC2 Fleet if it is deleted successfully. Defaults to false.
terminateInstancesWithExpiration boolean
Whether running instances should be terminated when the EC2 Fleet expires. Defaults to false.
type string
The type of request. Indicates whether the EC2 Fleet only requests the target capacity, or also attempts to maintain it. Valid values: maintain, request. Defaults to maintain.
excess_capacity_termination_policy str
Whether running instances should be terminated if the total target capacity of the EC2 Fleet is decreased below the current size of the EC2. Valid values: no-termination, termination. Defaults to termination.
launch_template_config FleetLaunchTemplateConfigArgs
Nested argument containing EC2 Launch Template configurations. Defined below.
on_demand_options FleetOnDemandOptionsArgs
Nested argument containing On-Demand configurations. Defined below.
replace_unhealthy_instances bool
Whether EC2 Fleet should replace unhealthy instances. Defaults to false.
spot_options FleetSpotOptionsArgs
Nested argument containing Spot configurations. Defined below.
tags Mapping[str, str]
tags_all Mapping[str, str]
target_capacity_specification FleetTargetCapacitySpecificationArgs
Nested argument containing target capacity configurations. Defined below.
terminate_instances bool
Whether to terminate instances for an EC2 Fleet if it is deleted successfully. Defaults to false.
terminate_instances_with_expiration bool
Whether running instances should be terminated when the EC2 Fleet expires. Defaults to false.
type str
The type of request. Indicates whether the EC2 Fleet only requests the target capacity, or also attempts to maintain it. Valid values: maintain, request. Defaults to maintain.

Supporting Types

FleetLaunchTemplateConfig

LaunchTemplateSpecification FleetLaunchTemplateConfigLaunchTemplateSpecificationArgs
Nested argument containing EC2 Launch Template to use. Defined below.
Overrides List<FleetLaunchTemplateConfigOverrideArgs>
Nested argument(s) containing parameters to override the same parameters in the Launch Template. Defined below.
LaunchTemplateSpecification FleetLaunchTemplateConfigLaunchTemplateSpecification
Nested argument containing EC2 Launch Template to use. Defined below.
Overrides []FleetLaunchTemplateConfigOverride
Nested argument(s) containing parameters to override the same parameters in the Launch Template. Defined below.
launchTemplateSpecification FleetLaunchTemplateConfigLaunchTemplateSpecificationArgs
Nested argument containing EC2 Launch Template to use. Defined below.
overrides FleetLaunchTemplateConfigOverrideArgs[]
Nested argument(s) containing parameters to override the same parameters in the Launch Template. Defined below.
launch_template_specification FleetLaunchTemplateConfigLaunchTemplateSpecificationArgs
Nested argument containing EC2 Launch Template to use. Defined below.
overrides Sequence[FleetLaunchTemplateConfigOverrideArgs]
Nested argument(s) containing parameters to override the same parameters in the Launch Template. Defined below.

FleetLaunchTemplateConfigLaunchTemplateSpecification

Version string
Version number of the launch template.
LaunchTemplateId string
ID of the launch template.
LaunchTemplateName string
Name of the launch template.
Version string
Version number of the launch template.
LaunchTemplateId string
ID of the launch template.
LaunchTemplateName string
Name of the launch template.
version string
Version number of the launch template.
launchTemplateId string
ID of the launch template.
launchTemplateName string
Name of the launch template.
version str
Version number of the launch template.
launch_template_id str
ID of the launch template.
launch_template_name str
Name of the launch template.

FleetLaunchTemplateConfigOverride

AvailabilityZone string
Availability Zone in which to launch the instances.
InstanceType string
Instance type.
MaxPrice string
Maximum price per unit hour that you are willing to pay for a Spot Instance.
Priority double
Priority for the launch template override. If on_demand_options allocation_strategy is set to prioritized, EC2 Fleet uses priority to determine which launch template override to use first in fulfilling On-Demand capacity. The highest priority is launched first. The lower the number, the higher the priority. If no number is set, the launch template override has the lowest priority. Valid values are whole numbers starting at 0.
SubnetId string
ID of the subnet in which to launch the instances.
WeightedCapacity double
Number of units provided by the specified instance type.
AvailabilityZone string
Availability Zone in which to launch the instances.
InstanceType string
Instance type.
MaxPrice string
Maximum price per unit hour that you are willing to pay for a Spot Instance.
Priority float64
Priority for the launch template override. If on_demand_options allocation_strategy is set to prioritized, EC2 Fleet uses priority to determine which launch template override to use first in fulfilling On-Demand capacity. The highest priority is launched first. The lower the number, the higher the priority. If no number is set, the launch template override has the lowest priority. Valid values are whole numbers starting at 0.
SubnetId string
ID of the subnet in which to launch the instances.
WeightedCapacity float64
Number of units provided by the specified instance type.
availabilityZone string
Availability Zone in which to launch the instances.
instanceType string
Instance type.
maxPrice string
Maximum price per unit hour that you are willing to pay for a Spot Instance.
priority number
Priority for the launch template override. If on_demand_options allocation_strategy is set to prioritized, EC2 Fleet uses priority to determine which launch template override to use first in fulfilling On-Demand capacity. The highest priority is launched first. The lower the number, the higher the priority. If no number is set, the launch template override has the lowest priority. Valid values are whole numbers starting at 0.
subnetId string
ID of the subnet in which to launch the instances.
weightedCapacity number
Number of units provided by the specified instance type.
availability_zone str
Availability Zone in which to launch the instances.
instance_type str
Instance type.
max_price str
Maximum price per unit hour that you are willing to pay for a Spot Instance.
priority float
Priority for the launch template override. If on_demand_options allocation_strategy is set to prioritized, EC2 Fleet uses priority to determine which launch template override to use first in fulfilling On-Demand capacity. The highest priority is launched first. The lower the number, the higher the priority. If no number is set, the launch template override has the lowest priority. Valid values are whole numbers starting at 0.
subnet_id str
ID of the subnet in which to launch the instances.
weighted_capacity float
Number of units provided by the specified instance type.

FleetOnDemandOptions

AllocationStrategy string
How to allocate the target capacity across the Spot pools. Valid values: diversified, lowestPrice. Default: lowestPrice.
AllocationStrategy string
How to allocate the target capacity across the Spot pools. Valid values: diversified, lowestPrice. Default: lowestPrice.
allocationStrategy string
How to allocate the target capacity across the Spot pools. Valid values: diversified, lowestPrice. Default: lowestPrice.
allocation_strategy str
How to allocate the target capacity across the Spot pools. Valid values: diversified, lowestPrice. Default: lowestPrice.

FleetSpotOptions

AllocationStrategy string
How to allocate the target capacity across the Spot pools. Valid values: diversified, lowestPrice. Default: lowestPrice.
InstanceInterruptionBehavior string
Behavior when a Spot Instance is interrupted. Valid values: hibernate, stop, terminate. Default: terminate.
InstancePoolsToUseCount int
Number of Spot pools across which to allocate your target Spot capacity. Valid only when Spot allocation_strategy is set to lowestPrice. Default: 1.
MaintenanceStrategies FleetSpotOptionsMaintenanceStrategiesArgs
Nested argument containing maintenance strategies for managing your Spot Instances that are at an elevated risk of being interrupted. Defined below.
AllocationStrategy string
How to allocate the target capacity across the Spot pools. Valid values: diversified, lowestPrice. Default: lowestPrice.
InstanceInterruptionBehavior string
Behavior when a Spot Instance is interrupted. Valid values: hibernate, stop, terminate. Default: terminate.
InstancePoolsToUseCount int
Number of Spot pools across which to allocate your target Spot capacity. Valid only when Spot allocation_strategy is set to lowestPrice. Default: 1.
MaintenanceStrategies FleetSpotOptionsMaintenanceStrategies
Nested argument containing maintenance strategies for managing your Spot Instances that are at an elevated risk of being interrupted. Defined below.
allocationStrategy string
How to allocate the target capacity across the Spot pools. Valid values: diversified, lowestPrice. Default: lowestPrice.
instanceInterruptionBehavior string
Behavior when a Spot Instance is interrupted. Valid values: hibernate, stop, terminate. Default: terminate.
instancePoolsToUseCount number
Number of Spot pools across which to allocate your target Spot capacity. Valid only when Spot allocation_strategy is set to lowestPrice. Default: 1.
maintenanceStrategies FleetSpotOptionsMaintenanceStrategiesArgs
Nested argument containing maintenance strategies for managing your Spot Instances that are at an elevated risk of being interrupted. Defined below.
allocation_strategy str
How to allocate the target capacity across the Spot pools. Valid values: diversified, lowestPrice. Default: lowestPrice.
instance_interruption_behavior str
Behavior when a Spot Instance is interrupted. Valid values: hibernate, stop, terminate. Default: terminate.
instance_pools_to_use_count int
Number of Spot pools across which to allocate your target Spot capacity. Valid only when Spot allocation_strategy is set to lowestPrice. Default: 1.
maintenance_strategies FleetSpotOptionsMaintenanceStrategiesArgs
Nested argument containing maintenance strategies for managing your Spot Instances that are at an elevated risk of being interrupted. Defined below.

FleetSpotOptionsMaintenanceStrategies

CapacityRebalance FleetSpotOptionsMaintenanceStrategiesCapacityRebalanceArgs
Nested argument containing the capacity rebalance for your fleet request. Defined below.
CapacityRebalance FleetSpotOptionsMaintenanceStrategiesCapacityRebalance
Nested argument containing the capacity rebalance for your fleet request. Defined below.
capacityRebalance FleetSpotOptionsMaintenanceStrategiesCapacityRebalanceArgs
Nested argument containing the capacity rebalance for your fleet request. Defined below.
capacity_rebalance FleetSpotOptionsMaintenanceStrategiesCapacityRebalanceArgs
Nested argument containing the capacity rebalance for your fleet request. Defined below.

FleetSpotOptionsMaintenanceStrategiesCapacityRebalance

ReplacementStrategy string
The replacement strategy to use. Only available for fleets of type set to maintain. Valid values: launch.
ReplacementStrategy string
The replacement strategy to use. Only available for fleets of type set to maintain. Valid values: launch.
replacementStrategy string
The replacement strategy to use. Only available for fleets of type set to maintain. Valid values: launch.
replacement_strategy str
The replacement strategy to use. Only available for fleets of type set to maintain. Valid values: launch.

FleetTargetCapacitySpecification

DefaultTargetCapacityType string
Default target capacity type. Valid values: on-demand, spot.
TotalTargetCapacity int
The number of units to request, filled using default_target_capacity_type.
OnDemandTargetCapacity int
The number of On-Demand units to request.
SpotTargetCapacity int
The number of Spot units to request.
DefaultTargetCapacityType string
Default target capacity type. Valid values: on-demand, spot.
TotalTargetCapacity int
The number of units to request, filled using default_target_capacity_type.
OnDemandTargetCapacity int
The number of On-Demand units to request.
SpotTargetCapacity int
The number of Spot units to request.
defaultTargetCapacityType string
Default target capacity type. Valid values: on-demand, spot.
totalTargetCapacity number
The number of units to request, filled using default_target_capacity_type.
onDemandTargetCapacity number
The number of On-Demand units to request.
spotTargetCapacity number
The number of Spot units to request.
default_target_capacity_type str
Default target capacity type. Valid values: on-demand, spot.
total_target_capacity int
The number of units to request, filled using default_target_capacity_type.
on_demand_target_capacity int
The number of On-Demand units to request.
spot_target_capacity int
The number of Spot units to request.

Import

aws_ec2_fleet can be imported by using the Fleet identifier, e.g.

 $ pulumi import aws:ec2/fleet:Fleet example fleet-b9b55d27-c5fc-41ac-a6f3-48fcc91f080c

Package Details

Repository
https://github.com/pulumi/pulumi-aws
License
Apache-2.0
Notes
This Pulumi package is based on the aws Terraform Provider.