Skip to content

Conversation

@djglaser
Copy link
Contributor

@djglaser djglaser commented Dec 18, 2025

Re-created PR to cleanup Git history: #45667

Rollback Plan

If a change needs to be reverted, we will publish an updated version of the library.

Description

Adds support for capacityOptionType which has two options: ON_DEMAND and SPOT. With on-demand instances, you pay for compute capacity by the hour, with no long-term commitments or upfront payments. Amazon EC2 Spot instances let you take advantage of unused EC2 capacity in the AWS cloud.

See public documentation here.

Output from Acceptance Testing

terraform-provider-aws|feat/ecs_managed_instances⚡ ⇒ make t T=TestAccECSCapacityProvider_managedInstancesProvider_capacityOptionTypeReplacement K=ecs P=1
make: Verifying source code with gofmt...
==> Checking that code complies with gofmt requirements...
make: Running acceptance tests on branch: 🌿 feat/ecs_managed_instances 🌿...
TF_ACC=1 go1.24.10 test ./internal/service/ecs/... -v -count 1 -parallel 1 -run='TestAccECSCapacityProvider_managedInstancesProvider_capacityOptionTypeReplacement'  -timeout 360m -vet=off
2025/11/25 14:58:45 Creating Terraform AWS Provider (SDKv2-style)...
2025/11/25 14:58:46 Initializing Terraform AWS Provider (SDKv2-style)...
=== RUN   TestAccECSCapacityProvider_managedInstancesProvider_capacityOptionTypeReplacement
=== PAUSE TestAccECSCapacityProvider_managedInstancesProvider_capacityOptionTypeReplacement
=== CONT  TestAccECSCapacityProvider_managedInstancesProvider_capacityOptionTypeReplacement
--- PASS: TestAccECSCapacityProvider_managedInstancesProvider_capacityOptionTypeReplacement (50.19s)
PASS
ok      github.com/hashicorp/terraform-provider-aws/internal/service/ecs        56.811s
?       github.com/hashicorp/terraform-provider-aws/internal/service/ecs/test-fixtures  [no test files]

...

@djglaser djglaser requested a review from a team as a code owner December 18, 2025 19:28
@github-actions
Copy link
Contributor

Community Guidelines

This comment is added to every new Pull Request to provide quick reference to how the Terraform AWS Provider is maintained. Please review the information below, and thank you for contributing to the community that keeps the provider thriving! 🚀

Voting for Prioritization

  • Please vote on this Pull Request by adding a 👍 reaction to the original post to help the community and maintainers prioritize it.
  • Please see our prioritization guide for additional information on how the maintainers handle prioritization.
  • Please do not leave +1 or other comments that do not add relevant new information or questions; they generate extra noise for others following the Pull Request and do not help prioritize the request.

Pull Request Authors

  • Review the contribution guide relating to the type of change you are making to ensure all of the necessary steps have been taken.
  • Whether or not the branch has been rebased will not impact prioritization, but doing so is always a welcome surprise.

@github-actions
Copy link
Contributor

github-actions bot commented Dec 18, 2025

⚠️ Our automation has detected the following potential issues with your pull request


❌ Dependency Changes (Click to expand)

Typically Go dependency changes are handled in this repository by dependabot or the maintainers. This is to prevent pull request merge conflicts and further delay reviews of contributions. For more information, see the Dependency Updates section of the contributing guide.

Remove any changes to the go.mod or go.sum files and commit them into this pull request to prevent delays with reviewing and potentially merging it.

Additional details:

  • Check open pull requests with the dependencies label to view other dependency updates.
  • If this pull request includes an update the AWS Go SDK (or any other dependency) version, only updates submitted via dependabot will be merged. This pull request will need to remove these changes and will need to be rebased after the existing dependency update via dependabot has been merged for this pull request to be reviewed.
  • If this pull request is for supporting a new AWS service:
  • Ensure the new AWS service changes are following the Adding a New AWS Service section of the contributing guide, in particular that the dependency addition and initial provider support are in a separate pull request from other changes (e.g. new resources). Contributions not following this item will not be reviewed until the changes are split.
  • If this pull request is already a separate pull request from the above item, you can ignore this message.
❌ Unnecessary Changelog Changes (Click to expand)

The CHANGELOG.md file contents are handled by the maintainers during merge. This is to prevent pull request merge conflicts, especially for contributions which may not be merged immediately. Please see the Changelog Process section of the contributing guide for additional information.

Remove any changes to the CHANGELOG.md file and commit them in this pull request to prevent delays with reviewing and potentially merging it.

@github-actions github-actions bot added needs-triage Waiting for first response or review from a maintainer. documentation Introduces or discusses updates to documentation. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. service/ecs Issues and PRs that pertain to the ecs service. size/M Managed by automation to categorize the size of a PR. partner Contribution from a partner. labels Dec 18, 2025
@ewbankkit
Copy link
Contributor

Requires AWS SDK for Go v2 Release 2025-12-18: #45660.

@github-actions github-actions bot added the size/L Managed by automation to categorize the size of a PR. label Dec 19, 2025
@djglaser djglaser force-pushed the feat/ecs_managed_instances branch from 26cb2cd to 81c4d26 Compare December 19, 2025 15:47
YakDriver and others added 21 commits December 19, 2025 12:11
- Remove S3 origin and origin shield that may be causing 503 errors
- Use single custom origin with headers and custom origin config
- Keep cache behaviors, custom error responses, and tenant config
- Remove aws_region data source (no longer needed without origin shield)
- Update test assertions to match simplified configuration
- Still tests comprehensive functionality without problematic features
- Add ImportState step to basic test for consistency with comprehensive test
- Add etag to ImportStateVerifyIgnore in both tests to match regular distribution pattern
- Ensures both tests verify import functionality works correctly
- Consistent with CloudFront distribution test patterns
- Remove logging_config (not supported in multi-tenant distributions)
- Add missing tenant_config argument (required for multi-tenant distributions)
- Add Custom Error Response section with all attributes
- Add Tenant Config, Parameter Definition, and String Schema sections
- Ensure all schema blocks are documented with correct attributes
- Align documentation with actual schema implementation
- Remove s3_origin_config schema block and model field
- Remove s3OriginConfigModel struct definition
- Remove s3_origin_config from documentation
- Add S3OriginConfig to limitation comments
- Multi-tenant distributions should use origin access control instead
- Aligns with restrictive nature of multi-tenant distributions
- Alphabetize the list of unsupported attributes for better readability
- No functional changes, just improved organization
- Fix Update method to properly handle tag updates and read back state
- Add proper tag update handling using updateTags function
- Read distribution after update to populate computed attributes
- Add comprehensive tags test with create/update/remove scenarios
- Fixes 'unknown value after apply' errors in tag update operations
- Add full UpdateDistribution API call with ETag handling
- Add distributionConfigEqual helper to detect config changes
- Handle tag updates separately from distribution config updates
- Wait for deployment after updates when distribution is enabled
- Read back updated distribution to populate computed attributes
- Ensures ConnectionMode remains tenant-only after updates

Fixes the stub Update method that was causing unknown values after apply.
- Test updating comment, http_version, and default_root_object
- Test updating allowed_methods and tenant_config comment
- Verify updates work without tags to isolate update functionality
- Include import state verification after updates
- Ensures Update method works correctly for distribution config changes
- Replace separate tag config functions with single parameterized function using map[string]string
- Replace separate update config functions with single parameterized function
- Add update step to comprehensive test to validate update functionality
- Parameterize comprehensive config function with comment, defaultRootObject, and compress parameters
- Add strings import for tag config generation
- Reduce test code duplication and improve maintainability
Add missing sections and fields to match schema implementation:

- Add Function Association section (event_type, function_arn)
- Add Lambda Function Association section (event_type, include_body, lambda_arn)
- Add Custom Header section (header_name, header_value)
- Add Custom Origin Config section with all fields and defaults
- Add Origin Shield section (enabled, origin_shield_region)
- Add Origin Group section with failover criteria and members
- Add Restrictions and Geo Restriction sections
- Add Viewer Certificate section with minimum_protocol_version default
- Add missing response_completion_timeout field with default value
- Add missing default_value field to String Schema section

All schema fields from lines 92-671 are now properly documented with correct
optionality, requirements, and default values where applicable.
- Add default value of 0 to error_caching_min_ttl field
- Add int64default import for default value support
- Resolves 'IllegalUpdate: custom error responses does not exist' error on updates
- Follows same pattern as other CloudFront API quirks where fields are required on updates
…ashicorp#45659)

Bumps [github.com/YakDriver/copyplop](https://github.com/YakDriver/copyplop) from 0.4.0 to 0.5.0.
- [Release notes](https://github.com/YakDriver/copyplop/releases)
- [Commits](YakDriver/copyplop@v0.4.0...v0.5.0)

---
updated-dependencies:
- dependency-name: github.com/YakDriver/copyplop
  dependency-version: 0.5.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…icorp#45660)

* Bump the aws-sdk-go-v2 group across 1 directory with 12 updates

Bumps the aws-sdk-go-v2 group with 12 updates in the / directory:

| Package | From | To |
| --- | --- | --- |
| [github.com/aws/aws-sdk-go-v2/service/appstream](https://github.com/aws/aws-sdk-go-v2) | `1.52.5` | `1.53.0` |
| [github.com/aws/aws-sdk-go-v2/service/arcregionswitch](https://github.com/aws/aws-sdk-go-v2) | `1.2.18` | `1.3.0` |
| [github.com/aws/aws-sdk-go-v2/service/bedrockagentcorecontrol](https://github.com/aws/aws-sdk-go-v2) | `1.15.2` | `1.16.0` |
| [github.com/aws/aws-sdk-go-v2/service/cleanrooms](https://github.com/aws/aws-sdk-go-v2) | `1.38.2` | `1.39.0` |
| [github.com/aws/aws-sdk-go-v2/service/ec2](https://github.com/aws/aws-sdk-go-v2) | `1.277.0` | `1.278.0` |
| [github.com/aws/aws-sdk-go-v2/service/ecr](https://github.com/aws/aws-sdk-go-v2) | `1.54.4` | `1.55.0` |
| [github.com/aws/aws-sdk-go-v2/service/ecs](https://github.com/aws/aws-sdk-go-v2) | `1.69.5` | `1.70.0` |
| [github.com/aws/aws-sdk-go-v2/service/iot](https://github.com/aws/aws-sdk-go-v2) | `1.70.0` | `1.71.0` |
| [github.com/aws/aws-sdk-go-v2/service/opensearch](https://github.com/aws/aws-sdk-go-v2) | `1.56.0` | `1.57.0` |
| [github.com/aws/aws-sdk-go-v2/service/sesv2](https://github.com/aws/aws-sdk-go-v2) | `1.58.0` | `1.59.0` |
| [github.com/aws/aws-sdk-go-v2/service/ssmsap](https://github.com/aws/aws-sdk-go-v2) | `1.25.15` | `1.26.0` |
| [github.com/aws/aws-sdk-go-v2/service/ssoadmin](https://github.com/aws/aws-sdk-go-v2) | `1.36.12` | `1.36.13` |



Updates `github.com/aws/aws-sdk-go-v2/service/appstream` from 1.52.5 to 1.53.0
- [Release notes](https://github.com/aws/aws-sdk-go-v2/releases)
- [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json)
- [Commits](aws/aws-sdk-go-v2@service/ssm/v1.52.5...service/s3/v1.53.0)

Updates `github.com/aws/aws-sdk-go-v2/service/arcregionswitch` from 1.2.18 to 1.3.0
- [Release notes](https://github.com/aws/aws-sdk-go-v2/releases)
- [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/v1.3.0/CHANGELOG.md)
- [Commits](aws/aws-sdk-go-v2@feature/rds/auth/v1.2.18...v1.3.0)

Updates `github.com/aws/aws-sdk-go-v2/service/bedrockagentcorecontrol` from 1.15.2 to 1.16.0
- [Release notes](https://github.com/aws/aws-sdk-go-v2/releases)
- [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/v1.16.0/CHANGELOG.md)
- [Commits](aws/aws-sdk-go-v2@config/v1.15.2...v1.16.0)

Updates `github.com/aws/aws-sdk-go-v2/service/cleanrooms` from 1.38.2 to 1.39.0
- [Release notes](https://github.com/aws/aws-sdk-go-v2/releases)
- [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json)
- [Commits](aws/aws-sdk-go-v2@v1.38.2...v1.39.0)

Updates `github.com/aws/aws-sdk-go-v2/service/ec2` from 1.277.0 to 1.278.0
- [Release notes](https://github.com/aws/aws-sdk-go-v2/releases)
- [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json)
- [Commits](aws/aws-sdk-go-v2@service/ec2/v1.277.0...service/ec2/v1.278.0)

Updates `github.com/aws/aws-sdk-go-v2/service/ecr` from 1.54.4 to 1.55.0
- [Release notes](https://github.com/aws/aws-sdk-go-v2/releases)
- [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json)
- [Commits](aws/aws-sdk-go-v2@service/s3/v1.54.4...service/s3/v1.55.0)

Updates `github.com/aws/aws-sdk-go-v2/service/ecs` from 1.69.5 to 1.70.0
- [Release notes](https://github.com/aws/aws-sdk-go-v2/releases)
- [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json)
- [Commits](aws/aws-sdk-go-v2@service/ecs/v1.69.5...service/s3/v1.70.0)

Updates `github.com/aws/aws-sdk-go-v2/service/iot` from 1.70.0 to 1.71.0
- [Release notes](https://github.com/aws/aws-sdk-go-v2/releases)
- [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json)
- [Commits](aws/aws-sdk-go-v2@service/s3/v1.70.0...service/s3/v1.71.0)

Updates `github.com/aws/aws-sdk-go-v2/service/opensearch` from 1.56.0 to 1.57.0
- [Release notes](https://github.com/aws/aws-sdk-go-v2/releases)
- [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json)
- [Commits](aws/aws-sdk-go-v2@service/s3/v1.56.0...service/s3/v1.57.0)

Updates `github.com/aws/aws-sdk-go-v2/service/sesv2` from 1.58.0 to 1.59.0
- [Release notes](https://github.com/aws/aws-sdk-go-v2/releases)
- [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json)
- [Commits](aws/aws-sdk-go-v2@service/s3/v1.58.0...service/s3/v1.59.0)

Updates `github.com/aws/aws-sdk-go-v2/service/ssmsap` from 1.25.15 to 1.26.0
- [Release notes](https://github.com/aws/aws-sdk-go-v2/releases)
- [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json)
- [Commits](aws/aws-sdk-go-v2@service/waf/v1.25.15...v1.26.0)

Updates `github.com/aws/aws-sdk-go-v2/service/ssoadmin` from 1.36.12 to 1.36.13
- [Release notes](https://github.com/aws/aws-sdk-go-v2/releases)
- [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json)
- [Commits](aws/aws-sdk-go-v2@service/xray/v1.36.12...service/xray/v1.36.13)

---
updated-dependencies:
- dependency-name: github.com/aws/aws-sdk-go-v2/service/appstream
  dependency-version: 1.53.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: aws-sdk-go-v2
- dependency-name: github.com/aws/aws-sdk-go-v2/service/arcregionswitch
  dependency-version: 1.3.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: aws-sdk-go-v2
- dependency-name: github.com/aws/aws-sdk-go-v2/service/bedrockagentcorecontrol
  dependency-version: 1.16.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: aws-sdk-go-v2
- dependency-name: github.com/aws/aws-sdk-go-v2/service/cleanrooms
  dependency-version: 1.39.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: aws-sdk-go-v2
- dependency-name: github.com/aws/aws-sdk-go-v2/service/ec2
  dependency-version: 1.278.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: aws-sdk-go-v2
- dependency-name: github.com/aws/aws-sdk-go-v2/service/ecr
  dependency-version: 1.55.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: aws-sdk-go-v2
- dependency-name: github.com/aws/aws-sdk-go-v2/service/ecs
  dependency-version: 1.70.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: aws-sdk-go-v2
- dependency-name: github.com/aws/aws-sdk-go-v2/service/iot
  dependency-version: 1.71.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: aws-sdk-go-v2
- dependency-name: github.com/aws/aws-sdk-go-v2/service/opensearch
  dependency-version: 1.57.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: aws-sdk-go-v2
- dependency-name: github.com/aws/aws-sdk-go-v2/service/sesv2
  dependency-version: 1.59.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: aws-sdk-go-v2
- dependency-name: github.com/aws/aws-sdk-go-v2/service/ssmsap
  dependency-version: 1.26.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: aws-sdk-go-v2
- dependency-name: github.com/aws/aws-sdk-go-v2/service/ssoadmin
  dependency-version: 1.36.13
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: aws-sdk-go-v2
...

Signed-off-by: dependabot[bot] <[email protected]>

* chore: make clean-tidy

---------

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Jared Baker <[email protected]>
@github-actions github-actions bot added service/cloudfront Issues and PRs that pertain to the cloudfront service. provider Pertains to the provider itself, rather than any interaction with AWS. linter Pertains to changes to or issues with the various linters. generators Relates to code generators. size/XL Managed by automation to categorize the size of a PR. labels Dec 19, 2025
@djglaser djglaser closed this Dec 19, 2025
@github-actions github-actions bot removed the needs-triage Waiting for first response or review from a maintainer. label Dec 19, 2025
@github-actions
Copy link
Contributor

Warning

This Issue has been closed, meaning that any additional comments are much easier for the maintainers to miss. Please assume that the maintainers will not see them.

Ongoing conversations amongst community members are welcome, however, the issue will be locked after 30 days. Moving conversations to another venue, such as the AWS Provider forum, is recommended. If you have additional concerns, please open a new issue, referencing this one where needed.

@djglaser
Copy link
Contributor Author

Recreating PR to cleanup git #45667

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Introduces or discusses updates to documentation. generators Relates to code generators. linter Pertains to changes to or issues with the various linters. partner Contribution from a partner. provider Pertains to the provider itself, rather than any interaction with AWS. service/cloudfront Issues and PRs that pertain to the cloudfront service. service/ecs Issues and PRs that pertain to the ecs service. size/L Managed by automation to categorize the size of a PR. size/M Managed by automation to categorize the size of a PR. size/XL Managed by automation to categorize the size of a PR. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants