Skip to content

Commit ee30bb3

Browse files
authored
feat: Expose hash_extra variable from Lambda module (#211)
1 parent a3e3f98 commit ee30bb3

File tree

3 files changed

+8
-0
lines changed

3 files changed

+8
-0
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,7 @@ See the [functions](https://github.com/terraform-aws-modules/terraform-aws-notif
103103
| <a name="input_create"></a> [create](#input\_create) | Whether to create all resources | `bool` | `true` | no |
104104
| <a name="input_create_sns_topic"></a> [create\_sns\_topic](#input\_create\_sns\_topic) | Whether to create new SNS topic | `bool` | `true` | no |
105105
| <a name="input_enable_sns_topic_delivery_status_logs"></a> [enable\_sns\_topic\_delivery\_status\_logs](#input\_enable\_sns\_topic\_delivery\_status\_logs) | Whether to enable SNS topic delivery status logs | `bool` | `false` | no |
106+
| <a name="input_hash_extra"></a> [hash\_extra](#input\_hash\_extra) | The string to add into hashing function. Useful when building same source path for different functions. | `string` | `""` | no |
106107
| <a name="input_iam_policy_path"></a> [iam\_policy\_path](#input\_iam\_policy\_path) | Path of policies to that should be added to IAM role for Lambda Function | `string` | `null` | no |
107108
| <a name="input_iam_role_boundary_policy_arn"></a> [iam\_role\_boundary\_policy\_arn](#input\_iam\_role\_boundary\_policy\_arn) | The ARN of the policy that is used to set the permissions boundary for the role | `string` | `null` | no |
108109
| <a name="input_iam_role_name_prefix"></a> [iam\_role\_name\_prefix](#input\_iam\_role\_name\_prefix) | A unique role name beginning with the specified prefix | `string` | `"lambda"` | no |

main.tf

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,7 @@ module "lambda" {
8787
function_name = var.lambda_function_name
8888
description = var.lambda_description
8989

90+
hash_extra = var.hash_extra
9091
handler = "${local.lambda_handler}.lambda_handler"
9192
source_path = var.lambda_source_path != null ? "${path.root}/${var.lambda_source_path}" : "${path.module}/functions/notify_slack.py"
9293
recreate_missing_package = var.recreate_missing_package

variables.tf

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,12 @@ variable "create_sns_topic" {
1616
default = true
1717
}
1818

19+
variable "hash_extra" {
20+
description = "The string to add into hashing function. Useful when building same source path for different functions."
21+
type = string
22+
default = ""
23+
}
24+
1925
variable "lambda_role" {
2026
description = "IAM role attached to the Lambda Function. If this is set then a role will not be created for you."
2127
type = string

0 commit comments

Comments
 (0)