Skip to content
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

Add Attribute Based Instance-type Selection support to EC2 Launch Templates #24543

Merged

Conversation

cjerad
Copy link
Contributor

@cjerad cjerad commented May 4, 2022

Community Note

  • Please vote on this pull request by adding a 👍 reaction to the original pull request comment to help the community and maintainers prioritize this request
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for pull request followers and do not help prioritize the request

Relates #21566

Output from acceptance testing:

$ make testacc PKG=ec2 TESTS=TestAccEC2LaunchTemplate_instanceRequirements
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/ec2/... -v -count 1 -parallel 20 -run='TestAccEC2LaunchTemplate_instanceRequirements'  -timeout 180m
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_memoryMiBAndVCpuCount
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_memoryMiBAndVCpuCount
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_acceleratorCount
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_acceleratorCount
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_acceleratorManufacturers
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_acceleratorManufacturers
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_acceleratorNames
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_acceleratorNames
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_acceleratorTotalMemoryMiB
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_acceleratorTotalMemoryMiB
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_acceleratorTypes
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_acceleratorTypes
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_bareMetal
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_bareMetal
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_baselineEbsBandwidthMbps
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_baselineEbsBandwidthMbps
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_burstablePerformance
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_burstablePerformance
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_cpuManufacturers
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_cpuManufacturers
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_excludedInstanceTypes
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_excludedInstanceTypes
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_instanceGenerations
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_instanceGenerations
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_localStorage
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_localStorage
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_localStorageTypes
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_localStorageTypes
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_memoryGiBPerVCpu
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_memoryGiBPerVCpu
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_networkInterfaceCount
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_networkInterfaceCount
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_onDemandMaxPricePercentageOverLowestPrice
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_onDemandMaxPricePercentageOverLowestPrice
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_requireHibernateSupport
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_requireHibernateSupport
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_spotMaxPricePercentageOverLowestPrice
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_spotMaxPricePercentageOverLowestPrice
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_totalLocalStorageGB
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_totalLocalStorageGB
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_memoryMiBAndVCpuCount
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_excludedInstanceTypes
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_acceleratorTypes
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_cpuManufacturers
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_totalLocalStorageGB
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_spotMaxPricePercentageOverLowestPrice
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_acceleratorNames
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_acceleratorManufacturers
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_acceleratorCount
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_requireHibernateSupport
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_acceleratorTotalMemoryMiB
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_onDemandMaxPricePercentageOverLowestPrice
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_networkInterfaceCount
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_memoryGiBPerVCpu
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_localStorageTypes
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_localStorage
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_instanceGenerations
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_burstablePerformance
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_baselineEbsBandwidthMbps
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_bareMetal
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_onDemandMaxPricePercentageOverLowestPrice (59.83s)
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_spotMaxPricePercentageOverLowestPrice (59.99s)
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_instanceGenerations (88.30s)
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_acceleratorTypes (94.84s)
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_localStorageTypes (94.88s)
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_acceleratorManufacturers (104.68s)
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_requireHibernateSupport (104.76s)
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_excludedInstanceTypes (104.94s)
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_cpuManufacturers (105.20s)
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_acceleratorNames (109.54s)
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_memoryMiBAndVCpuCount (109.66s)
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_burstablePerformance (125.01s)
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_baselineEbsBandwidthMbps (130.44s)
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_acceleratorTotalMemoryMiB (134.16s)
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_acceleratorCount (134.58s)
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_bareMetal (134.68s)
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_memoryGiBPerVCpu (134.68s)
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_networkInterfaceCount (137.18s)
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_localStorage (137.38s)
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_totalLocalStorageGB (141.21s)
PASS
ok      github.com/hashicorp/terraform-provider-aws/internal/service/ec2        144.648s

@github-actions
Copy link

github-actions bot commented May 4, 2022

Hey @cjerad 👋 Thank you very much for your contribution! At times, our maintainers need to make direct edits to pull requests in order to help get it ready to be merged. Your current settings do not allow maintainers to make such edits. To help facilitate this, update your pull request to allow such edits as described in GitHub's Allowing changes to a pull request branch created from a fork documentation. (If you're using a fork owned by an organization, your organization may not allow you to change this setting. If that is the case, let us know.)

@github-actions github-actions bot added documentation Introduces or discusses updates to documentation. service/ec2 Issues and PRs that pertain to the ec2 service. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. needs-triage Waiting for first response or review from a maintainer. size/XL Managed by automation to categorize the size of a PR. and removed needs-triage Waiting for first response or review from a maintainer. labels May 4, 2022
@cjerad cjerad changed the title [WIP] Add Attribute Based Instance-type Selection support to EC2 Launch Templates Add Attribute Based Instance-type Selection support to EC2 Launch Templates May 4, 2022
@cjerad cjerad marked this pull request as ready for review May 4, 2022 17:01
Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Welcome @cjerad 👋

It looks like this is your first Pull Request submission to the Terraform AWS Provider! If you haven’t already done so please make sure you have checked out our CONTRIBUTING guide and FAQ to make sure your contribution is adhering to best practice and has all the necessary elements in place for a successful approval.

Also take a look at our FAQ which details how we prioritize Pull Requests for inclusion.

Thanks again, and welcome to the community! 😃

@github-actions github-actions bot added the verify Pertains to the verify package (i.e., provider-level validating, diff suppression, etc.) label May 9, 2022
Copy link
Contributor

@ewbankkit ewbankkit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🚀.

% make testacc TESTS=TestAccEC2LaunchTemplate PKG=ec2 ACCTEST_PARALLELISM=2
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/ec2/... -v -count 1 -parallel 2 -run='TestAccEC2LaunchTemplate'  -timeout 180m
=== RUN   TestAccEC2LaunchTemplateDataSource_name
=== PAUSE TestAccEC2LaunchTemplateDataSource_name
=== RUN   TestAccEC2LaunchTemplateDataSource_id
=== PAUSE TestAccEC2LaunchTemplateDataSource_id
=== RUN   TestAccEC2LaunchTemplateDataSource_filter
=== PAUSE TestAccEC2LaunchTemplateDataSource_filter
=== RUN   TestAccEC2LaunchTemplateDataSource_tags
=== PAUSE TestAccEC2LaunchTemplateDataSource_tags
=== RUN   TestAccEC2LaunchTemplate_basic
=== PAUSE TestAccEC2LaunchTemplate_basic
=== RUN   TestAccEC2LaunchTemplate_Name_generated
=== PAUSE TestAccEC2LaunchTemplate_Name_generated
=== RUN   TestAccEC2LaunchTemplate_Name_prefix
=== PAUSE TestAccEC2LaunchTemplate_Name_prefix
=== RUN   TestAccEC2LaunchTemplate_disappears
=== PAUSE TestAccEC2LaunchTemplate_disappears
=== RUN   TestAccEC2LaunchTemplate_BlockDeviceMappings_ebs
=== PAUSE TestAccEC2LaunchTemplate_BlockDeviceMappings_ebs
=== RUN   TestAccEC2LaunchTemplate_BlockDeviceMappingsEBS_deleteOnTermination
=== PAUSE TestAccEC2LaunchTemplate_BlockDeviceMappingsEBS_deleteOnTermination
=== RUN   TestAccEC2LaunchTemplate_BlockDeviceMappingsEBS_gp3
=== PAUSE TestAccEC2LaunchTemplate_BlockDeviceMappingsEBS_gp3
=== RUN   TestAccEC2LaunchTemplate_ebsOptimized
=== PAUSE TestAccEC2LaunchTemplate_ebsOptimized
=== RUN   TestAccEC2LaunchTemplate_elasticInferenceAccelerator
=== PAUSE TestAccEC2LaunchTemplate_elasticInferenceAccelerator
=== RUN   TestAccEC2LaunchTemplate_NetworkInterfaces_deleteOnTermination
=== PAUSE TestAccEC2LaunchTemplate_NetworkInterfaces_deleteOnTermination
=== RUN   TestAccEC2LaunchTemplate_data
=== PAUSE TestAccEC2LaunchTemplate_data
=== RUN   TestAccEC2LaunchTemplate_description
=== PAUSE TestAccEC2LaunchTemplate_description
=== RUN   TestAccEC2LaunchTemplate_update
=== PAUSE TestAccEC2LaunchTemplate_update
=== RUN   TestAccEC2LaunchTemplate_tags
=== PAUSE TestAccEC2LaunchTemplate_tags
=== RUN   TestAccEC2LaunchTemplate_CapacityReservation_preference
=== PAUSE TestAccEC2LaunchTemplate_CapacityReservation_preference
=== RUN   TestAccEC2LaunchTemplate_CapacityReservation_target
=== PAUSE TestAccEC2LaunchTemplate_CapacityReservation_target
=== RUN   TestAccEC2LaunchTemplate_cpuOptions
=== PAUSE TestAccEC2LaunchTemplate_cpuOptions
=== RUN   TestAccEC2LaunchTemplate_CreditSpecification_nonBurstable
=== PAUSE TestAccEC2LaunchTemplate_CreditSpecification_nonBurstable
=== RUN   TestAccEC2LaunchTemplate_CreditSpecification_t2
=== PAUSE TestAccEC2LaunchTemplate_CreditSpecification_t2
=== RUN   TestAccEC2LaunchTemplate_CreditSpecification_t3
=== PAUSE TestAccEC2LaunchTemplate_CreditSpecification_t3
=== RUN   TestAccEC2LaunchTemplate_IAMInstanceProfile_emptyBlock
=== PAUSE TestAccEC2LaunchTemplate_IAMInstanceProfile_emptyBlock
=== RUN   TestAccEC2LaunchTemplate_networkInterface
=== PAUSE TestAccEC2LaunchTemplate_networkInterface
=== RUN   TestAccEC2LaunchTemplate_networkInterfaceAddresses
=== PAUSE TestAccEC2LaunchTemplate_networkInterfaceAddresses
=== RUN   TestAccEC2LaunchTemplate_networkInterfaceType
=== PAUSE TestAccEC2LaunchTemplate_networkInterfaceType
=== RUN   TestAccEC2LaunchTemplate_networkInterfaceCardIndex
=== PAUSE TestAccEC2LaunchTemplate_networkInterfaceCardIndex
=== RUN   TestAccEC2LaunchTemplate_networkInterfaceIPv4PrefixCount
=== PAUSE TestAccEC2LaunchTemplate_networkInterfaceIPv4PrefixCount
=== RUN   TestAccEC2LaunchTemplate_networkInterfaceIPv4Prefixes
=== PAUSE TestAccEC2LaunchTemplate_networkInterfaceIPv4Prefixes
=== RUN   TestAccEC2LaunchTemplate_networkInterfaceIPv6PrefixCount
=== PAUSE TestAccEC2LaunchTemplate_networkInterfaceIPv6PrefixCount
=== RUN   TestAccEC2LaunchTemplate_networkInterfaceIPv6Prefixes
=== PAUSE TestAccEC2LaunchTemplate_networkInterfaceIPv6Prefixes
=== RUN   TestAccEC2LaunchTemplate_associatePublicIPAddress
=== PAUSE TestAccEC2LaunchTemplate_associatePublicIPAddress
=== RUN   TestAccEC2LaunchTemplate_associateCarrierIPAddress
=== PAUSE TestAccEC2LaunchTemplate_associateCarrierIPAddress
=== RUN   TestAccEC2LaunchTemplate_Placement_hostResourceGroupARN
=== PAUSE TestAccEC2LaunchTemplate_Placement_hostResourceGroupARN
=== RUN   TestAccEC2LaunchTemplate_Placement_partitionNum
=== PAUSE TestAccEC2LaunchTemplate_Placement_partitionNum
=== RUN   TestAccEC2LaunchTemplate_privateDNSNameOptions
=== PAUSE TestAccEC2LaunchTemplate_privateDNSNameOptions
=== RUN   TestAccEC2LaunchTemplate_NetworkInterface_ipv6Addresses
=== PAUSE TestAccEC2LaunchTemplate_NetworkInterface_ipv6Addresses
=== RUN   TestAccEC2LaunchTemplate_NetworkInterface_ipv6AddressCount
=== PAUSE TestAccEC2LaunchTemplate_NetworkInterface_ipv6AddressCount
=== RUN   TestAccEC2LaunchTemplate_instanceMarketOptions
=== PAUSE TestAccEC2LaunchTemplate_instanceMarketOptions
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_memoryMiBAndVCpuCount
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_memoryMiBAndVCpuCount
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_acceleratorCount
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_acceleratorCount
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_acceleratorManufacturers
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_acceleratorManufacturers
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_acceleratorNames
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_acceleratorNames
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_acceleratorTotalMemoryMiB
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_acceleratorTotalMemoryMiB
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_acceleratorTypes
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_acceleratorTypes
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_bareMetal
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_bareMetal
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_baselineEbsBandwidthMbps
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_baselineEbsBandwidthMbps
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_burstablePerformance
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_burstablePerformance
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_cpuManufacturers
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_cpuManufacturers
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_excludedInstanceTypes
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_excludedInstanceTypes
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_instanceGenerations
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_instanceGenerations
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_localStorage
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_localStorage
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_localStorageTypes
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_localStorageTypes
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_memoryGiBPerVCpu
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_memoryGiBPerVCpu
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_networkInterfaceCount
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_networkInterfaceCount
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_onDemandMaxPricePercentageOverLowestPrice
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_onDemandMaxPricePercentageOverLowestPrice
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_requireHibernateSupport
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_requireHibernateSupport
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_spotMaxPricePercentageOverLowestPrice
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_spotMaxPricePercentageOverLowestPrice
=== RUN   TestAccEC2LaunchTemplate_instanceRequirements_totalLocalStorageGB
=== PAUSE TestAccEC2LaunchTemplate_instanceRequirements_totalLocalStorageGB
=== RUN   TestAccEC2LaunchTemplate_licenseSpecification
=== PAUSE TestAccEC2LaunchTemplate_licenseSpecification
=== RUN   TestAccEC2LaunchTemplate_metadataOptions
=== PAUSE TestAccEC2LaunchTemplate_metadataOptions
=== RUN   TestAccEC2LaunchTemplate_enclaveOptions
=== PAUSE TestAccEC2LaunchTemplate_enclaveOptions
=== RUN   TestAccEC2LaunchTemplate_hibernation
=== PAUSE TestAccEC2LaunchTemplate_hibernation
=== RUN   TestAccEC2LaunchTemplate_defaultVersion
=== PAUSE TestAccEC2LaunchTemplate_defaultVersion
=== RUN   TestAccEC2LaunchTemplate_updateDefaultVersion
=== PAUSE TestAccEC2LaunchTemplate_updateDefaultVersion
=== CONT  TestAccEC2LaunchTemplateDataSource_name
=== CONT  TestAccEC2LaunchTemplate_associateCarrierIPAddress
--- PASS: TestAccEC2LaunchTemplateDataSource_name (53.56s)
=== CONT  TestAccEC2LaunchTemplate_tags
--- PASS: TestAccEC2LaunchTemplate_associateCarrierIPAddress (82.84s)
=== CONT  TestAccEC2LaunchTemplate_associatePublicIPAddress
--- PASS: TestAccEC2LaunchTemplate_tags (67.84s)
=== CONT  TestAccEC2LaunchTemplate_networkInterfaceIPv6Prefixes
--- PASS: TestAccEC2LaunchTemplate_networkInterfaceIPv6Prefixes (23.20s)
=== CONT  TestAccEC2LaunchTemplate_networkInterfaceIPv6PrefixCount
--- PASS: TestAccEC2LaunchTemplate_associatePublicIPAddress (72.95s)
=== CONT  TestAccEC2LaunchTemplate_networkInterfaceIPv4Prefixes
--- PASS: TestAccEC2LaunchTemplate_networkInterfaceIPv6PrefixCount (23.54s)
=== CONT  TestAccEC2LaunchTemplate_networkInterfaceIPv4PrefixCount
--- PASS: TestAccEC2LaunchTemplate_networkInterfaceIPv4Prefixes (23.79s)
=== CONT  TestAccEC2LaunchTemplate_networkInterfaceCardIndex
--- PASS: TestAccEC2LaunchTemplate_networkInterfaceIPv4PrefixCount (24.26s)
=== CONT  TestAccEC2LaunchTemplate_networkInterfaceType
--- PASS: TestAccEC2LaunchTemplate_networkInterfaceCardIndex (23.72s)
=== CONT  TestAccEC2LaunchTemplate_networkInterfaceAddresses
--- PASS: TestAccEC2LaunchTemplate_networkInterfaceType (30.65s)
=== CONT  TestAccEC2LaunchTemplate_networkInterface
--- PASS: TestAccEC2LaunchTemplate_networkInterfaceAddresses (42.39s)
=== CONT  TestAccEC2LaunchTemplate_IAMInstanceProfile_emptyBlock
--- PASS: TestAccEC2LaunchTemplate_networkInterface (43.51s)
=== CONT  TestAccEC2LaunchTemplate_BlockDeviceMappingsEBS_deleteOnTermination
--- PASS: TestAccEC2LaunchTemplate_IAMInstanceProfile_emptyBlock (25.61s)
=== CONT  TestAccEC2LaunchTemplate_update
--- PASS: TestAccEC2LaunchTemplate_BlockDeviceMappingsEBS_deleteOnTermination (101.12s)
=== CONT  TestAccEC2LaunchTemplate_description
--- PASS: TestAccEC2LaunchTemplate_update (101.36s)
=== CONT  TestAccEC2LaunchTemplate_CreditSpecification_t3
--- PASS: TestAccEC2LaunchTemplate_CreditSpecification_t3 (22.76s)
=== CONT  TestAccEC2LaunchTemplate_data
--- PASS: TestAccEC2LaunchTemplate_description (44.17s)
=== CONT  TestAccEC2LaunchTemplate_CreditSpecification_t2
--- PASS: TestAccEC2LaunchTemplate_data (24.55s)
=== CONT  TestAccEC2LaunchTemplate_NetworkInterfaces_deleteOnTermination
--- PASS: TestAccEC2LaunchTemplate_CreditSpecification_t2 (22.14s)
=== CONT  TestAccEC2LaunchTemplate_CreditSpecification_nonBurstable
--- PASS: TestAccEC2LaunchTemplate_CreditSpecification_nonBurstable (26.56s)
=== CONT  TestAccEC2LaunchTemplate_elasticInferenceAccelerator
--- PASS: TestAccEC2LaunchTemplate_NetworkInterfaces_deleteOnTermination (79.81s)
=== CONT  TestAccEC2LaunchTemplate_cpuOptions
--- PASS: TestAccEC2LaunchTemplate_elasticInferenceAccelerator (40.08s)
=== CONT  TestAccEC2LaunchTemplate_ebsOptimized
--- PASS: TestAccEC2LaunchTemplate_cpuOptions (15.01s)
=== CONT  TestAccEC2LaunchTemplate_CapacityReservation_target
--- PASS: TestAccEC2LaunchTemplate_CapacityReservation_target (20.66s)
=== CONT  TestAccEC2LaunchTemplate_CapacityReservation_preference
--- PASS: TestAccEC2LaunchTemplate_CapacityReservation_preference (17.37s)
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_excludedInstanceTypes
--- PASS: TestAccEC2LaunchTemplate_ebsOptimized (67.36s)
=== CONT  TestAccEC2LaunchTemplate_updateDefaultVersion
--- PASS: TestAccEC2LaunchTemplate_updateDefaultVersion (51.85s)
=== CONT  TestAccEC2LaunchTemplate_defaultVersion
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_excludedInstanceTypes (87.73s)
=== CONT  TestAccEC2LaunchTemplate_hibernation
--- PASS: TestAccEC2LaunchTemplate_defaultVersion (46.73s)
=== CONT  TestAccEC2LaunchTemplate_enclaveOptions
--- PASS: TestAccEC2LaunchTemplate_hibernation (51.60s)
=== CONT  TestAccEC2LaunchTemplate_Name_generated
--- PASS: TestAccEC2LaunchTemplate_Name_generated (21.64s)
=== CONT  TestAccEC2LaunchTemplate_metadataOptions
--- PASS: TestAccEC2LaunchTemplate_enclaveOptions (52.29s)
=== CONT  TestAccEC2LaunchTemplate_licenseSpecification
    acctest.go:1018: skipping test for aws/us-west-2: Error running apply: exit status 1
        
        Error: Error creating License Manager license configuration: ResourceLimitExceededException: You have reached the maximum allowed number of license configurations created in one day.
        
          with aws_licensemanager_license_configuration.test,
          on terraform_plugin_test.tf line 2, in resource "aws_licensemanager_license_configuration" "test":
           2: resource "aws_licensemanager_license_configuration" "test" {
        
--- SKIP: TestAccEC2LaunchTemplate_licenseSpecification (7.48s)
=== CONT  TestAccEC2LaunchTemplate_BlockDeviceMappingsEBS_gp3
--- PASS: TestAccEC2LaunchTemplate_metadataOptions (54.75s)
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_totalLocalStorageGB
--- PASS: TestAccEC2LaunchTemplate_BlockDeviceMappingsEBS_gp3 (71.85s)
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_spotMaxPricePercentageOverLowestPrice
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_spotMaxPricePercentageOverLowestPrice (47.91s)
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_acceleratorManufacturers
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_totalLocalStorageGB (143.39s)
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_requireHibernateSupport
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_acceleratorManufacturers (89.39s)
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_cpuManufacturers
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_requireHibernateSupport (87.04s)
=== CONT  TestAccEC2LaunchTemplate_BlockDeviceMappings_ebs
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_cpuManufacturers (86.69s)
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_burstablePerformance
--- PASS: TestAccEC2LaunchTemplate_BlockDeviceMappings_ebs (59.97s)
=== CONT  TestAccEC2LaunchTemplate_disappears
--- PASS: TestAccEC2LaunchTemplate_disappears (12.45s)
=== CONT  TestAccEC2LaunchTemplate_Name_prefix
--- PASS: TestAccEC2LaunchTemplate_Name_prefix (15.90s)
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_onDemandMaxPricePercentageOverLowestPrice
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_onDemandMaxPricePercentageOverLowestPrice (47.55s)
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_networkInterfaceCount
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_burstablePerformance (126.10s)
=== CONT  TestAccEC2LaunchTemplateDataSource_tags
--- PASS: TestAccEC2LaunchTemplateDataSource_tags (14.26s)
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_baselineEbsBandwidthMbps
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_networkInterfaceCount (125.65s)
=== CONT  TestAccEC2LaunchTemplate_basic
--- PASS: TestAccEC2LaunchTemplate_basic (16.33s)
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_acceleratorTotalMemoryMiB
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_baselineEbsBandwidthMbps (129.66s)
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_acceleratorNames
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_acceleratorNames (82.42s)
=== CONT  TestAccEC2LaunchTemplate_NetworkInterface_ipv6AddressCount
--- PASS: TestAccEC2LaunchTemplate_NetworkInterface_ipv6AddressCount (15.97s)
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_acceleratorCount
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_acceleratorTotalMemoryMiB (129.20s)
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_memoryMiBAndVCpuCount
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_memoryMiBAndVCpuCount (84.79s)
=== CONT  TestAccEC2LaunchTemplate_instanceMarketOptions
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_acceleratorCount (128.25s)
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_memoryGiBPerVCpu
--- PASS: TestAccEC2LaunchTemplate_instanceMarketOptions (106.62s)
=== CONT  TestAccEC2LaunchTemplate_privateDNSNameOptions
--- PASS: TestAccEC2LaunchTemplate_privateDNSNameOptions (17.22s)
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_localStorageTypes
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_memoryGiBPerVCpu (129.49s)
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_acceleratorTypes
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_localStorageTypes (79.58s)
=== CONT  TestAccEC2LaunchTemplate_NetworkInterface_ipv6Addresses
--- PASS: TestAccEC2LaunchTemplate_NetworkInterface_ipv6Addresses (16.29s)
=== CONT  TestAccEC2LaunchTemplate_Placement_partitionNum
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_acceleratorTypes (86.33s)
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_instanceGenerations
--- PASS: TestAccEC2LaunchTemplate_Placement_partitionNum (30.80s)
=== CONT  TestAccEC2LaunchTemplateDataSource_filter
--- PASS: TestAccEC2LaunchTemplateDataSource_filter (14.62s)
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_localStorage
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_instanceGenerations (80.48s)
=== CONT  TestAccEC2LaunchTemplate_Placement_hostResourceGroupARN
--- PASS: TestAccEC2LaunchTemplate_Placement_hostResourceGroupARN (20.57s)
=== CONT  TestAccEC2LaunchTemplateDataSource_id
--- PASS: TestAccEC2LaunchTemplateDataSource_id (14.71s)
=== CONT  TestAccEC2LaunchTemplate_instanceRequirements_bareMetal
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_localStorage (135.36s)
--- PASS: TestAccEC2LaunchTemplate_instanceRequirements_bareMetal (125.04s)
PASS
ok  	github.com/hashicorp/terraform-provider-aws/internal/service/ec2	1981.752s

@ewbankkit
Copy link
Contributor

@cjerad Thanks for the contribution 🎉 👏.
Overall everything was great, especially the very thorough acceptance tests.
I made a few minor functional changes:

  • Changed the various string lists in instance_requirements to TypeSet so that element order is not significant.
  • Added an instance_requirements attribute to the aws_launch_template data source.

@github-actions
Copy link

This functionality has been released in v4.14.0 of the Terraform AWS Provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading.

For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template. Thank you!

@cjerad cjerad deleted the f-aws_launch_template-instance_requirements branch May 26, 2022 13:44
@github-actions
Copy link

I'm going to lock this pull request because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 26, 2022
@justinretzolk justinretzolk added the partner Contribution from a partner. label May 16, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
documentation Introduces or discusses updates to documentation. partner Contribution from a partner. service/ec2 Issues and PRs that pertain to the ec2 service. size/XL Managed by automation to categorize the size of a PR. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. verify Pertains to the verify package (i.e., provider-level validating, diff suppression, etc.)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants