blob: 01f94fcd75738f54906108abc799417256b5d85b (
plain)
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
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
|
# Nomad
variable "nomad_datacenters" {
description = "Nomad data centers"
type = list(string)
default = [ "dc1" ]
}
variable "nomad_host_volume" {
description = "Nomad Host Volume"
type = string
default = "persistence"
}
# Minio
variable "minio_job_name" {
description = "Minio job name"
type = string
default = "minio"
}
variable "minio_service_name" {
description = "Minio service name"
type = string
default = "minio"
}
variable "minio_group_count" {
description = "Number of Minio group instances"
type = number
default = 1
}
variable "minio_host" {
description = "Minio host"
type = string
default = "127.0.0.1"
}
variable "minio_port" {
description = "Minio port"
type = number
default = 9000
}
variable "minio_cpu" {
description = "CPU allocation for Minio"
type = number
default = 200
}
variable "minio_memory" {
description = "Memory allocation for Minio"
type = number
default = 1024
}
variable "minio_container_image" {
description = "Minio docker image"
type = string
default = "minio/minio:latest"
}
variable "minio_envs" {
description = "Minio environment variables"
type = list(string)
default = []
}
variable "minio_access_key" {
description = "Minio access key"
type = string
default = "minio"
}
variable "minio_secret_key" {
description = "Minio secret key"
type = string
default = "minio123"
}
variable "minio_data_dir" {
description = "Minio server data dir"
type = string
default = "/data/"
}
variable "minio_use_host_volume" {
description = "Use Nomad host volume feature"
type = bool
default = false
}
variable "minio_use_canary" {
description = "Uses canary deployment for Minio"
type = bool
default = false
}
variable "minio_vault_secret" {
description = "Set of properties to be able to fetch secret from vault"
type = object({
use_vault_provider = bool,
vault_kv_policy_name = string,
vault_kv_path = string,
vault_kv_field_access_key = string,
vault_kv_field_secret_key = string
})
}
variable "minio_resource_proxy" {
description = "Minio proxy resources"
type = object({
cpu = number,
memory = number
})
default = {
cpu = 200,
memory = 128
}
validation {
condition = var.minio_resource_proxy.cpu >= 200 && var.minio_resource_proxy.memory >= 128
error_message = "Proxy resource must be at least: cpu=200, memory=128."
}
}
# MC
variable "mc_job_name" {
description = "Minio client job name"
type = string
default = "mc"
}
variable "mc_service_name" {
description = "Minio client service name"
type = string
default = "mc"
}
variable "mc_container_image" {
description = "Minio client docker image"
type = string
default = "minio/mc:latest"
}
variable "mc_envs" {
description = "Minio client environment variables"
type = list(string)
default = []
}
variable "minio_buckets" {
description = "List of buckets to create on startup"
type = list(string)
default = []
}
variable "minio_upstreams" {
description = "List of upstream services (list of object with service_name, port)"
type = list(object({
service_name = string,
port = number,
}))
default = []
}
variable "mc_extra_commands" {
description = "Extra commands to run in MC container after creating buckets"
type = list(string)
default = [""]
}
|