-
Notifications
You must be signed in to change notification settings - Fork 9.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
New Resource: aws_ec2_fleet #5960
Conversation
8c3f51c
to
859f607
Compare
859f607
to
e5eed2f
Compare
Does this supersede ec2_spot_fleet ? Seems so. |
They are two separate AWS services. |
aws/resource_aws_ec2_fleet.go
Outdated
}, | ||
}, | ||
}, | ||
"overrides": { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should be singular
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will update code, testing, and documentation. 👍
aws/resource_aws_ec2_fleet.go
Outdated
|
||
input := &ec2.CreateFleetInput{ | ||
ExcessCapacityTerminationPolicy: aws.String(d.Get("excess_capacity_termination_policy").(string)), | ||
LaunchTemplateConfigs: expandEc2FleetLaunchTemplateConfigRequests(d.Get("launch_template_configs").([]interface{})), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I feel like these casts are panic potential, but won't hold up a merge over it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Calling d.Get()
against a schema.TypeList
will always return a []interface{}
with 0 or more elements 😄
@paultyng feedback hopefully addressed! 😄 Output from acceptance testing:
|
Output from acceptance testing: ``` --- PASS: TestAccAWSEc2Fleet_basic (35.71s) --- PASS: TestAccAWSEc2Fleet_disappears (32.21s) --- PASS: TestAccAWSEc2Fleet_ExcessCapacityTerminationPolicy (94.75s) --- PASS: TestAccAWSEc2Fleet_LaunchTemplateConfig_LaunchTemplateSpecification_LaunchTemplateId (72.23s) --- PASS: TestAccAWSEc2Fleet_LaunchTemplateConfig_LaunchTemplateSpecification_LaunchTemplateName (65.05s) --- PASS: TestAccAWSEc2Fleet_LaunchTemplateConfig_LaunchTemplateSpecification_Version (66.15s) --- PASS: TestAccAWSEc2Fleet_LaunchTemplateConfig_Override_AvailabilityZone (64.70s) --- PASS: TestAccAWSEc2Fleet_LaunchTemplateConfig_Override_InstanceType (70.11s) --- PASS: TestAccAWSEc2Fleet_LaunchTemplateConfig_Override_Priority (62.72s) --- PASS: TestAccAWSEc2Fleet_LaunchTemplateConfig_Override_Priority_Multiple (62.67s) --- PASS: TestAccAWSEc2Fleet_LaunchTemplateConfig_Override_SubnetId (84.59s) --- PASS: TestAccAWSEc2Fleet_LaunchTemplateConfig_Override_WeightedCapacity (66.18s) --- PASS: TestAccAWSEc2Fleet_LaunchTemplateConfig_Override_WeightedCapacity_Multiple (66.18s) --- PASS: TestAccAWSEc2Fleet_OnDemandOptions_AllocationStrategy (65.99s) --- PASS: TestAccAWSEc2Fleet_ReplaceUnhealthyInstances (67.76s) --- PASS: TestAccAWSEc2Fleet_SpotOptions_AllocationStrategy (65.17s) --- PASS: TestAccAWSEc2Fleet_SpotOptions_InstanceInterruptionBehavior (64.85s) --- PASS: TestAccAWSEc2Fleet_SpotOptions_InstancePoolsToUseCount (62.53s) --- PASS: TestAccAWSEc2Fleet_Tags (65.32s) --- PASS: TestAccAWSEc2Fleet_TargetCapacitySpecification_DefaultTargetCapacityType (64.69s) --- PASS: TestAccAWSEc2Fleet_TargetCapacitySpecification_DefaultTargetCapacityType_OnDemand (32.68s) --- PASS: TestAccAWSEc2Fleet_TargetCapacitySpecification_DefaultTargetCapacityType_Spot (34.97s) --- PASS: TestAccAWSEc2Fleet_TargetCapacitySpecification_TotalTargetCapacity (468.10s) --- PASS: TestAccAWSEc2Fleet_TerminateInstancesWithExpiration (63.03s) --- PASS: TestAccAWSEc2Fleet_Type (32.81s) ```
This has been released in version 1.39.0 of the provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading. As an example: provider "aws" {
version = "~> 1.39.0"
}
# ... other configuration ... |
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thanks! |
Closes #4581
Changes proposed in this pull request:
aws_ec2_fleet
Output from acceptance testing: