Skip to content

fix: support Terraform AWS Provider v6 #4646

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

Merged
merged 1 commit into from
Jul 1, 2025

Conversation

paulschwarzenberger
Copy link
Contributor

@paulschwarzenberger paulschwarzenberger commented Jun 29, 2025

Fixes #4625

Requirements for this PR:

  • support Terraform AWS Provider v6
  • continue to support Terraform AWS Provider v5 for as long as practical
  • avoid the need for another issue to be raised when v7 is eventually released

This PR therefore includes the following:

  • replace current constraints in versions.tf ~> 5.0, ~> 5.27, ~> 5.77 in the module and submodules with >=5.0, >=5.27, >=5.77
  • this follows similar practice adopted by many other popular AWS Terraform modules, e.g. the AWS VPC
  • in the examples, upgrade versions.tf to ">=6.0" except for the base, multi-runner and permission-boundary examples where it's left as is, with a comment ensure backwards compatibility with v5.x
  • ran terraform init --upgrade to upgrade terraform.lock.hcl files in examples

@paulschwarzenberger paulschwarzenberger requested review from a team as code owners June 29, 2025 20:31
@npalm
Copy link
Member

npalm commented Jun 30, 2025

Thx for the PR. I just cracking my head why the versions in the modules are locked down to a major versin. I assume this habbit comes from the fact back in the days a major bump caused several times some troubles. As well that back in the days terraform had no proper locking mechnism. Since users can proper lock their deployment I see no big risk to allow 5+ upawards as long the module does not require 6 only dependencies. In case 7 is breaking something we can always lockdown the mdoule at that time.

@npalm npalm requested a review from Copilot June 30, 2025 20:15
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR broadens Terraform AWS Provider version constraints across the module to allow v6+ while retaining v5 compatibility, and updates example configurations accordingly.

  • Swaps all ~> 5.x constraints in module and submodule versions.tf files to >= 5.x
  • Updates most example versions.tf files to require >= 6.0, leaving only base, multi-runner, and permissions-boundary examples on ~> 5.x for backwards compatibility
  • Ran terraform init --upgrade on all example lockfiles

Reviewed Changes

Copilot reviewed 24 out of 28 changed files in this pull request and generated 1 comment.

File Description
versions.tf Changed AWS provider constraint from ~> 5.77 to >= 5.77
modules/**/versions.tf Replaced all ~> 5.x AWS provider constraints with >= 5.x
examples/**/versions.tf Bumped most examples to >= 6.0, with explicit backward-compat comments on exceptions
Files not reviewed (4)
  • examples/base/.terraform.lock.hcl: Language not supported
  • examples/default/.terraform.lock.hcl: Language not supported
  • examples/ephemeral/.terraform.lock.hcl: Language not supported
  • examples/external-managed-ssm-secrets/.terraform.lock.hcl: Language not supported

Copy link
Member

@npalm npalm left a comment

Choose a reason for hiding this comment

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

@paulschwarzenberger thx! looks all good!

@npalm npalm merged commit aebef80 into github-aws-runners:main Jul 1, 2025
40 checks passed
@paulschwarzenberger paulschwarzenberger deleted the provider-v6 branch July 1, 2025 19:21
npalm pushed a commit that referenced this pull request Jul 1, 2025
🤖 I have created a release *beep* *boop*
---


##
[6.6.0](v6.5.11...v6.6.0)
(2025-07-01)


### Features

* **runner:** support Ubuntu 24.04
([#4246](#4246))
([76456b5](76456b5))
@bdellegrazie


### Bug Fixes

* **lambda:** bump @octokit/webhooks from 14.0.2 to 14.1.0 in /lambdas
in the octokit group
([#4651](#4651))
([754ffc8](754ffc8))
* **lambda:** bump the aws group in /lambdas with 6 updates
([#4641](#4641))
([1955841](1955841))
* **lambda:** bump the aws group in /lambdas with 7 updates
([#4650](#4650))
([e53710e](e53710e))
* support Terraform AWS Provider v6
([#4646](#4646))
([aebef80](aebef80))
@paulschwarzenberger

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

---------

Co-authored-by: runners-releaser[bot] <194412594+runners-releaser[bot]@users.noreply.github.com>
Co-authored-by: github-aws-runners-pr|bot <github-aws-runners-pr[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Cannot initialise with Terraform AWS Provider version 6
2 participants