From 918f2f7764b8797872b2f8a0330f1145ba23cacf Mon Sep 17 00:00:00 2001 From: Meraj Kashi <55163548+meraj-kashi@users.noreply.github.com> Date: Mon, 28 Oct 2024 16:11:01 +0100 Subject: [PATCH] Added IAM role and permission path (#9) Co-authored-by: Meraj Kashi --- main.tf | 2 ++ variables.tf | 12 ++++++++++++ 2 files changed, 14 insertions(+) diff --git a/main.tf b/main.tf index 37a8691..1a048c4 100644 --- a/main.tf +++ b/main.tf @@ -13,6 +13,8 @@ module "reporter_lambda" { role_name = var.create_role ? var.name : null role_permissions_boundary = var.role_permissions_boundary + role_path = var.role_path + policy_path = var.policy_path timeout = var.lambda_timeout create_package = false publish = true diff --git a/variables.tf b/variables.tf index 075ddd9..8fd085e 100644 --- a/variables.tf +++ b/variables.tf @@ -81,6 +81,18 @@ variable "role_permissions_boundary" { default = null } +variable "role_path" { + description = "Path of IAM role to use for Lambda Function" + type = string + default = null +} + +variable "policy_path" { + description = "Path of policies to that should be added to IAM role for Lambda Function" + type = string + default = null +} + variable "kosli_api_token_ssm_parameter_name" { description = "The name of the kosli_api_token SSM parameter name" type = string