forked from transcom/terraform-aws-lambda
-
Notifications
You must be signed in to change notification settings - Fork 0
/
variables.tf
142 lines (118 loc) · 3.38 KB
/
variables.tf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
variable "name" {
description = "Lambda function name"
type = string
}
variable "job_identifier" {
description = "Identifier for specific instance of Lambda function"
type = string
}
variable "runtime" {
description = "Lambda runtime type"
type = string
}
# Either deploy from a specified bucket
variable "s3_bucket" {
description = "Name of s3 bucket used for Lambda build"
type = string
default = ""
}
variable "s3_key" {
description = "Key for s3 object for Lambda function code"
type = string
default = ""
}
# Or deploy from a specified Github repo/version
variable "github_project" {
default = ""
type = string
description = "The unique Github project to pull from. Currently, this must be public. Eg. 'trussworks/aws-iam-sleuth'"
}
variable "github_release" {
default = ""
type = string
description = "The release tag to download."
}
variable "github_filename" {
default = "deployment.zip"
type = string
description = "Name of the file to get when building url to pull."
}
variable "validation_sha" {
default = ""
type = string
description = "SHA to validate the file."
}
# We need an explicit count because of Terraform issue 17421
variable "role_policy_arns_count" {
description = "Count of policy ARNs to attach to Lambda role"
type = string
}
variable "role_policy_arns" {
description = "List of policy ARNs to attach to Lambda role"
type = list(any)
}
variable "memory_size" {
default = 128
description = "Size in MB of Lambda function memory allocation"
type = string
}
variable "ephemeral_storage" {
default = 512
description = "Size in MB of Lambda function ephemeral storage allocation"
type = string
}
variable "timeout" {
default = 60
description = "Timeout in seconds for Lambda function timeout"
type = string
}
variable "tags" {
default = {}
description = "Map of tags for Lambda function"
type = map(any)
}
variable "env_vars" {
default = {}
description = "Map of environment variables for Lambda function"
type = map(any)
}
variable "subnet_ids" {
default = []
description = "List of subnet IDs for Lambda VPC config (leave empty if no VPC)"
type = list(any)
}
variable "security_group_ids" {
default = []
description = "List of security group IDs for Lambda VPC config (leave empty if no VPC)"
type = list(any)
}
variable "cloudwatch_logs_retention_days" {
default = 30
description = "Number of days to retain logs in Cloudwatch Logs"
type = string
}
variable "source_types" {
default = []
description = "List of sources for Lambda triggers; order must match source_arns"
type = list(any)
}
variable "source_arns" {
default = []
description = "List of arns for Lambda triggers; order must match source_types"
type = list(any)
}
variable "handler" {
default = "main.Main"
description = "The entrypoint function for the lambda function."
type = string
}
variable "publish" {
description = "Whether to publish creation/change as new Lambda Function Version."
type = bool
default = false
}
variable "cloudwatch_encryption_key_arn" {
description = "The arn of the encryption key to be used for the cloudwatch logs"
type = string
default = ""
}