mirror of
https://gitlab.sarex.io/infra/terraform-contour-mirror.git
synced 2026-08-05 18:31:00 +03:00
89 lines
2.6 KiB
HCL
89 lines
2.6 KiB
HCL
variable "secrets" {
|
|
description = "Список секретов для создания"
|
|
type = list(object({
|
|
name = string
|
|
namespace = string
|
|
secret_type = string
|
|
registry_url = optional(string, "")
|
|
dependencies = optional(object({
|
|
cluster = optional(string, "")
|
|
db = optional(string, "")
|
|
user = optional(string, "")
|
|
bucket = optional(string, "") # Имя бакета для s3 секретов
|
|
service_account = optional(string, "") # Имя YC Service Account для yc_sa секретов
|
|
}), {})
|
|
yc_sa_key_names = optional(object({
|
|
access_key = optional(string, "access_key")
|
|
secret_key = optional(string, "secret_key")
|
|
service_account_id = optional(string, "service_account_id")
|
|
}), {})
|
|
custom_keys = optional(map(string), {})
|
|
random_keys = optional(map(object({
|
|
length = optional(number, 32)
|
|
special = optional(bool, false)
|
|
})), {}) # Случайные ключи
|
|
labels = optional(map(string), {})
|
|
annotations = optional(map(string), {})
|
|
ignore_changes = optional(bool, false)
|
|
}))
|
|
}
|
|
|
|
variable "s3_outputs" {
|
|
description = "Outputs от модуля S3 (default/первый бакет)"
|
|
type = object({
|
|
bucket_name = optional(string, "")
|
|
access_key = optional(string, "")
|
|
secret_key = optional(string, "")
|
|
})
|
|
default = {
|
|
bucket_name = ""
|
|
access_key = ""
|
|
secret_key = ""
|
|
}
|
|
}
|
|
|
|
variable "s3_buckets_map" {
|
|
description = "Map всех бакетов (name => data)"
|
|
type = map(object({
|
|
bucket_name = string
|
|
access_key = string
|
|
secret_key = string
|
|
service_account_id = optional(string, "")
|
|
}))
|
|
default = {}
|
|
}
|
|
|
|
variable "yc_service_accounts_map" {
|
|
description = "Map YC service accounts (name => data)"
|
|
type = map(object({
|
|
service_account_id = string
|
|
access_key = optional(string, "")
|
|
secret_key = optional(string, "")
|
|
folder_roles = optional(list(string), [])
|
|
}))
|
|
default = {}
|
|
}
|
|
|
|
variable "database_outputs_map" {
|
|
description = "Outputs от модулей Database, ключ = cluster_id:database_name:user_name"
|
|
type = map(object({
|
|
host = string
|
|
database_name = string
|
|
user_name = string
|
|
password = string
|
|
}))
|
|
default = {}
|
|
}
|
|
|
|
variable "constants" {
|
|
description = "Константные значения (CA сертификаты, endpoints и т.д.)"
|
|
type = map(string)
|
|
default = {}
|
|
}
|
|
|
|
variable "env_vars" {
|
|
description = "Environment variables"
|
|
type = map(string)
|
|
default = {}
|
|
}
|