Skip to content

Commit 120c2ff

Browse files
committed
feat!: Upgraded AWS provider to v6 and Terraform to v1.5.7
1 parent 3690011 commit 120c2ff

File tree

6 files changed

+16
-7
lines changed

6 files changed

+16
-7
lines changed

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
repos:
22
- repo: https://github.com/antonbabenko/pre-commit-terraform
3-
rev: v1.96.1
3+
rev: v1.99.4
44
hooks:
55
- id: terraform_fmt
66
- id: terraform_docs

examples/complete/main.tf

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -241,12 +241,12 @@ resource "null_resource" "download_package" {
241241

242242
module "lambda_function" {
243243
source = "terraform-aws-modules/lambda/aws"
244-
version = "~> 2.0"
244+
version = "~> 8.0"
245245

246246
function_name = "${random_pet.this.id}-lambda"
247247
description = "My awesome lambda function"
248248
handler = "index.lambda_handler"
249-
runtime = "python3.8"
249+
runtime = "python3.12"
250250

251251
publish = true
252252

examples/complete/versions.tf

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
terraform {
2-
required_version = ">= 1.0"
2+
required_version = ">= 1.5.7"
33

44
required_providers {
55
aws = {
66
source = "hashicorp/aws"
7-
version = ">= 5.61"
7+
version = ">= 6.0"
88
}
99
random = {
1010
source = "hashicorp/random"

main.tf

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ locals {
1515
resource "aws_sfn_state_machine" "this" {
1616
count = var.create ? 1 : 0
1717

18+
region = var.region
19+
1820
name = var.name
1921

2022
role_arn = var.use_existing_role ? var.role_arn : aws_iam_role.this[0].arn
@@ -323,6 +325,8 @@ data "aws_cloudwatch_log_group" "sfn" {
323325
resource "aws_cloudwatch_log_group" "sfn" {
324326
count = var.create && local.enable_logging && !var.use_existing_cloudwatch_log_group ? 1 : 0
325327

328+
region = var.region
329+
326330
name = coalesce(var.cloudwatch_log_group_name, "/aws/vendedlogs/states/${var.name}")
327331
retention_in_days = var.cloudwatch_log_group_retention_in_days
328332
kms_key_id = var.cloudwatch_log_group_kms_key_id

variables.tf

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,11 @@ variable "use_existing_cloudwatch_log_group" {
2626
# Step Function
2727
################
2828

29+
variable "region" {
30+
description = "Region where the resource(s) will be managed. Defaults to the region set in the provider configuration"
31+
type = string
32+
default = null
33+
}
2934
variable "name" {
3035
description = "The name of the Step Function"
3136
type = string

versions.tf

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
terraform {
2-
required_version = ">= 1.0"
2+
required_version = ">= 1.5.7"
33

44
required_providers {
55
aws = {
66
source = "hashicorp/aws"
7-
version = ">= 5.61"
7+
version = ">= 6.0"
88
}
99
}
1010
}

0 commit comments

Comments
 (0)