-
Notifications
You must be signed in to change notification settings - Fork 2
/
variables.tf
131 lines (109 loc) · 3.49 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
variable "name" {
type = string
description = "The name of the Glue job"
}
variable "command_name" {
type = string
default = "glueetl"
description = "The name of the job command. Defaults to glueetl"
validation {
condition = var.command_name == "glueetl" || var.command_name == "pythonshell" || var.command_name == "gluestreaming"
error_message = "For an Apache Spark ETL job, this must be glueetl. For a Python shell job, it must be pythonshell. For an Apache Spark streaming ETL job, this must be gluestreaming."
}
}
variable "connections" {
type = list(string)
default = []
description = "A list with connections for this job"
}
variable "default_arguments" {
type = map(string)
default = {}
description = "A map with default arguments for the job"
}
variable "glue_version" {
type = string
default = "4.0"
description = "The Glue version to use"
}
variable "kms_key_id" {
type = string
default = null
description = "The kms key id of the AWS KMS Customer Managed Key to be used to encrypt the log data"
}
variable "log_retention_days" {
type = number
description = "The cloudwatch log group retention in days"
default = 365
}
variable "max_capacity" {
type = number
default = null
description = "The maximum number of data processing units that can be allocated"
}
variable "max_retries" {
type = number
default = 0
description = "The maximum number of times to retry the failing job"
}
variable "number_of_workers" {
type = string
default = null
description = "The number of workers that are allocated when the job runs"
}
variable "python_version" {
type = string
default = "3"
description = "The Python version (2 or 3) being used to execute a Python shell job"
}
variable "role_arn" {
type = string
default = null
description = "An optional Glue execution role"
}
variable "role_policy" {
type = string
default = null
description = "A valid Glue IAM policy JSON document"
}
variable "schedule" {
type = string
default = null
description = "A cron expression used to specify the schedule for the glue trigger"
}
variable "security_configuration" {
type = string
default = null
description = "The name of the Security Configuration to be associated with the job"
}
variable "schedule_active" {
type = bool
default = true
description = "Whether the glue trigger should be active"
}
variable "script_location" {
type = string
description = "The S3 path to the script that is executed by the job"
}
variable "trigger_type" {
type = string
default = null
description = "The type ('ON_DEMAND' or 'SCHEDULED') of the trigger"
validation {
condition = var.trigger_type == null || var.trigger_type == "ON_DEMAND" || var.trigger_type == "SCHEDULED"
error_message = "Valid values are ON_DEMAND, or SCHEDULED."
}
}
variable "worker_type" {
type = string
default = null
description = "The type ('Standard' or 'G.1X' or 'G.2X') of predefined worker that is allocated when the job runs"
validation {
condition = var.worker_type == null || var.worker_type == "Standard" || var.worker_type == "G.1X" || var.worker_type == "G.2X"
error_message = "Valid values are Standard, G.1X, or G.2X."
}
}
variable "tags" {
type = map(string)
description = "A mapping of tags to assign to all resources"
}