@@ -21,17 +21,17 @@ This module provides a Lambda function which logs to CloudWatch. If no image URI
2121
2222## Inputs
2323
24- | Name | Description | Type | Default | Required |
25- | ------------- | --------------------------------------------------------------------------- | -------------- | ------- | :------: |
26- | identifier | Unique identifier to differentiate global resources. | ` string ` | n/a | yes |
27- | policies | List of IAM policy ARNs for the Lambda's IAM role. | ` list(string) ` | [ ] | no |
28- | vpc_config | Object to define the subnets and security groups for the Lambda function. | ` object ` | null | no |
29- | log | A flag for make the Lambda function submit logs to CloudWatch. | ` bool ` | false | no |
30- | image | Object of the image which will be pulled by the Lambda function to execute. | ` object ` | null | no |
31- | memory_size | Amount of memory in MB the Lambda function can use at runtime. | ` number ` | 128 | no |
32- | timeout | Amount of time the Lambda function has to run in seconds. | ` number ` | 3 | no |
33- | env_variables | A map of environment variables for the Lambda function at runtime. | ` map(string) ` | {} | no |
34- | tags | A map of tags to add to all resources. | ` map(string) ` | {} | no |
24+ | Name | Description | Type | Default | Required |
25+ | ------------- | ---------------------------------------------------------------------------- | -------------- | ------- | :------: |
26+ | identifier | Unique identifier to differentiate global resources. | ` string ` | n/a | yes |
27+ | policies | List of IAM policy ARNs for the Lambda's IAM role. | ` list(string) ` | [ ] | no |
28+ | vpc_config | Object to define the subnets and security groups for the Lambda function. | ` object ` | null | no |
29+ | log_config | Object to define logging configuration of the Lambda function to CloudWatch. | ` object ` | null | no |
30+ | image | Object of the image which will be pulled by the Lambda function to execute. | ` object ` | null | no |
31+ | memory_size | Amount of memory in MB the Lambda function can use at runtime. | ` number ` | 128 | no |
32+ | timeout | Amount of time the Lambda function has to run in seconds. | ` number ` | 3 | no |
33+ | env_variables | A map of environment variables for the Lambda function at runtime. | ` map(string) ` | {} | no |
34+ | tags | A map of tags to add to all resources. | ` map(string) ` | {} | no |
3535
3636### ` vpc_config `
3737
@@ -40,6 +40,12 @@ This module provides a Lambda function which logs to CloudWatch. If no image URI
4040| subnets | List of subnet IDs in which the Lambda function will run in. | ` list(string) ` | n/a | yes |
4141| security_groups | List of security group IDs the Lambda function will hold. | ` list(string) ` | n/a | yes |
4242
43+ ### ` log_config `
44+
45+ | Name | Description | Type | Default | Required |
46+ | ----------------- | -------------------------------------------------------------------------------------------------------------------------- | -------- | ------- | :------: |
47+ | retention_in_days | Specifies the number of days the log events shall be retained. Valid values: 1, 3, 5, 7, 14, 30, 365 and 0 (never expire). | ` number ` | n/a | yes |
48+
4349### ` image `
4450
4551| Name | Description | Type | Default | Required |
@@ -48,10 +54,11 @@ This module provides a Lambda function which logs to CloudWatch. If no image URI
4854
4955## Outputs
5056
51- | Name | Description |
52- | ---------- | -------------------------------------- |
53- | arn | The ARN of the Lambda function. |
54- | invoke_arn | The invoke ARN of the Lambda function. |
57+ | Name | Description |
58+ | -------------- | ------------------------------------------------------------------------------- |
59+ | arn | The ARN of the Lambda function. |
60+ | invoke_arn | The invoke ARN of the Lambda function. |
61+ | log_group_name | The name of the CloudWatch log group created for the Lambda function to log to. |
5562
5663## Example
5764
0 commit comments