feat(gitea): refactor configuration to use structured app_config and add TLS support
This commit is contained in:
@@ -23,12 +23,6 @@ variable "backup_cron_schedule" {
|
||||
type = string
|
||||
}
|
||||
|
||||
variable "db_password" {
|
||||
description = "The password for the Gitea MySQL database"
|
||||
type = string
|
||||
sensitive = true
|
||||
}
|
||||
|
||||
variable "db_root_password" {
|
||||
description = "The root password for the MySQL database"
|
||||
type = string
|
||||
@@ -46,34 +40,49 @@ variable "fqdn" {
|
||||
type = string
|
||||
}
|
||||
|
||||
variable "app_name" {
|
||||
description = "The name of the application"
|
||||
type = string
|
||||
|
||||
variable "tls_enabled" {
|
||||
description = "Enable TLS for the SFTPGo server"
|
||||
type = bool
|
||||
default = true
|
||||
}
|
||||
|
||||
variable "smtp_host" {
|
||||
description = "The SMTP relay host"
|
||||
variable "issuer" {
|
||||
description = "The issuer for the certificate"
|
||||
type = string
|
||||
default = "internal-ca"
|
||||
}
|
||||
|
||||
variable "smtp_port" {
|
||||
description = "The SMTP relay port"
|
||||
type = number
|
||||
}
|
||||
|
||||
variable "smtp_username" {
|
||||
description = "The SMTP relay username"
|
||||
type = string
|
||||
sensitive = true
|
||||
}
|
||||
|
||||
variable "smtp_password" {
|
||||
description = "The SMTP relay password"
|
||||
type = string
|
||||
sensitive = true
|
||||
}
|
||||
|
||||
variable "from_email" {
|
||||
description = "The email address to use as the sender"
|
||||
type = string
|
||||
variable "app_config" {
|
||||
description = "The configuration for the SFTPGo server"
|
||||
type = object({
|
||||
app_name = string
|
||||
domain = string
|
||||
lfs_jwt_secret = string
|
||||
db_passwd = string
|
||||
jwt_secret = string
|
||||
mail_from = string
|
||||
no_reply_address = string
|
||||
smtp_user = string
|
||||
smtp_passwd = string
|
||||
smtp_host = string
|
||||
secret_key = string
|
||||
internal_token = string
|
||||
disable_registration = optional(bool, true)
|
||||
require_signin_view = optional(bool, false)
|
||||
register_email_confirm = optional(bool, false)
|
||||
enable_notify_mail = optional(bool, true)
|
||||
allow_only_external_registration = optional(bool, false)
|
||||
enable_captcha = optional(bool, true)
|
||||
run_mode = optional(string, "prod")
|
||||
http_port = optional(string, "3000")
|
||||
disable_ssh = optional(bool, false)
|
||||
ssh_port = optional(number, 22)
|
||||
db_host = optional(string, "mariadb")
|
||||
db_port = optional(string, "3306")
|
||||
db_name = optional(string, "gitea")
|
||||
db_user = optional(string, "gitea")
|
||||
smtp_protocol = optional(string, "SMTPS")
|
||||
smtp_port = optional(string, "587")
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user