2025-06-01 17:14:33 +02:00
|
|
|
variable "tag" {
|
|
|
|
|
description = "The version of the nginx server to install"
|
|
|
|
|
type = string
|
|
|
|
|
default = "stable-alpine"
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
variable "wireguard_config" {
|
|
|
|
|
description = "The Wireguard configuration file"
|
|
|
|
|
type = object({
|
|
|
|
|
private_key = string
|
|
|
|
|
public_key = string
|
|
|
|
|
pre_shared_key = string
|
|
|
|
|
endpoint = string
|
|
|
|
|
endpoint_port = number
|
|
|
|
|
address = string
|
|
|
|
|
dns = string
|
|
|
|
|
allowed_ips = list(string)
|
|
|
|
|
})
|
|
|
|
|
default = null
|
|
|
|
|
sensitive = true
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
variable "issuer_name" {
|
|
|
|
|
description = "The name of the issuer to use for TLS certificates, internal certificates"
|
|
|
|
|
type = string
|
|
|
|
|
default = "internal-ca"
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
variable "services" {
|
|
|
|
|
description = "A list of services to be deployed"
|
|
|
|
|
type = map(object({
|
|
|
|
|
fqdn = list(string)
|
2025-06-08 21:18:53 +02:00
|
|
|
upstream = optional(string, "")
|
2025-06-07 16:12:55 +02:00
|
|
|
resolver = optional(string, "")
|
2025-06-01 17:14:33 +02:00
|
|
|
default_headers = optional(map(string), {}),
|
|
|
|
|
http_port = optional(number, 80)
|
|
|
|
|
https_port = optional(number, 443)
|
|
|
|
|
tls = optional(bool, false)
|
|
|
|
|
locations = optional(list(object({
|
2025-06-02 01:42:17 +02:00
|
|
|
path = string,
|
|
|
|
|
headers = optional(map(string), {}),
|
|
|
|
|
private = optional(bool, false),
|
|
|
|
|
upstream = optional(string, ""),
|
2025-06-07 16:12:55 +02:00
|
|
|
resolver = optional(string, "")
|
2025-06-02 01:42:17 +02:00
|
|
|
rewrite = optional(string, "")
|
2025-06-01 17:14:33 +02:00
|
|
|
})), [])
|
|
|
|
|
custom_snippet = optional(string, "")
|
|
|
|
|
config = optional(string, "")
|
|
|
|
|
}))
|
|
|
|
|
}
|
2025-06-02 01:42:17 +02:00
|
|
|
|
|
|
|
|
variable "auth_token" {
|
|
|
|
|
description = "The authentication token to use for the reverse proxy"
|
|
|
|
|
type = string
|
|
|
|
|
sensitive = true
|
2025-06-08 21:18:53 +02:00
|
|
|
default = ""
|
2025-06-02 01:42:17 +02:00
|
|
|
}
|