Skip to content

Commit

Permalink
chore: apply reviewer's suggestions
Browse files Browse the repository at this point in the history
  • Loading branch information
gberenice committed Jun 21, 2023
1 parent c762aee commit ece4e40
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion modules/lambda/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ module "iam_policy" {

iam_policy_enabled = true
iam_policy = var.iam_policy
iam_source_policy_documents = [var.policy_json]
iam_source_policy_documents = var.policy_json != null ? [var.policy_json] : []

context = module.this.context
}
Expand Down
6 changes: 3 additions & 3 deletions modules/lambda/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,7 @@ variable "vpc_config" {

variable "custom_iam_policy_arns" {
type = set(string)
description = "ARNs of custom policies to be attached to the lambda role"
description = "ARNs of IAM policies to be attached to the Lambda role"
default = []
}

Expand All @@ -269,7 +269,7 @@ variable "iam_policy_description" {

variable "policy_json" {
type = string
description = "IAM policy to attach to the Lambda IAM role. This can be used with or instead of the `var.iam_policy`."
description = "IAM policy to attach to the Lambda role, specified as JSON. This can be used with or instead of `var.iam_policy`."
default = null
}

Expand Down Expand Up @@ -299,7 +299,7 @@ variable "iam_policy" {
})), [])
}))
})
description = "IAM policy as Terraform object. This can be used with or instead of the `var.policy_json`."
description = "IAM policy to attach to the Lambda role, specified as a Terraform object. This can be used with or instead of `var.policy_json`."
default = null
}

Expand Down

0 comments on commit ece4e40

Please sign in to comment.