disable reverse proxy and add extra site

This commit is contained in:
pierre.geeraert
2026-10-13 14:45:50 +01:00
parent dce7d02073
commit bd2d151ebd
2 changed files with 39 additions and 60 deletions
+17 -1
View File
@@ -14,7 +14,7 @@ resource "kubernetes_ingress_v1" "automatic_ingress" {
ingress_class_name = "traefik" ingress_class_name = "traefik"
# Dynamic TLS configuration for cert-manager # Dynamic TLS configuration for cert-manager
tls { tls {
hosts = [join(".", [coalesce(each.value.domain_name, each.key), "geeraert.eu"])] hosts = [join(".", [coalesce(each.value.domain_name, each.key), "geeraert.eu"]),join(".", [coalesce(each.value.domain_name, each.key), "tryton.geeraert.eu"])]
secret_name = "${each.key}-tls-secret" # cert-manager will create and manage this secret automatically secret_name = "${each.key}-tls-secret" # cert-manager will create and manage this secret automatically
} }
@@ -34,6 +34,22 @@ resource "kubernetes_ingress_v1" "automatic_ingress" {
} }
} }
} }
rule {
host = join(".", [coalesce(each.value.domain_name, each.key), "tryton.geeraert.eu"])
http {
path {
path = "/"
backend {
service {
name = "${each.key}-svc"
port {
number = each.value.service_port[0] #selecting the first of the list
}
}
}
}
}
}
} }
} }
+22 -59
View File
@@ -1,42 +1,33 @@
kubernetes = { kubernetes = {
reverse-proxy = { echo = {
enabled = false #enabled = false
#docker = true #docker = true
image = "nginx:latest" image = "ealen/echo-server:latest"
service_port = [80, 443] service_port = [4580]
service_type = "NodePort"
external_port = true external_port = true
service_type = "NodePort"
#command = ["-text=Hello authenticated world!"]
pvc = { pvc = {
sites-terraform = { echo-config = {
#requires to run the reverse proxy terraform with the kubernetes enabled mount_path = "/app/configs"
mount_path = "/etc/nginx/conf.d/"
host_path = "/data/kubernetes/reverse-proxy/reverse-proxy-sites"
#config_map = sites-terraform
} }
echo-testing = {
reverse-proxy-log = { mount_path = "/app/test"
name = "reverse-proxy-log"
mount_path = "/var/log/nginx/"
host_path = "/data/kubernetes/reverse-proxy/reverse-proxy-log"
}
reverse-proxy-ssl = {
name = "reverse-proxy-ssl"
mount_path = "/etc/nginx/ssl/"
host_path = "/data/kubernetes/reverse-proxy/reverse-proxy-ssl"
}
nginx-configfile = {
name = "nginx-configfile"
mount_path = "/etc/nginx/nginx.conf"
host_path = "/data/kubernetes/reverse-proxy/reverse-proxy-configfile/nginx.conf"
} }
} }
environment = {
PORT = {
value = 4580
}
PAPERLESS_REDIS = {
value = "redis://paperless-redis-svc:6379"
}
database = {
value = "datgg"
}
}
} }
gitea = { gitea = {
#enabled = false #enabled = false
#docker = true #docker = true
@@ -102,35 +93,7 @@ kubernetes = {
} }
echo = {
#enabled = false
#docker = true
image = "ealen/echo-server:latest"
service_port = [4580]
external_port = true
service_type = "NodePort"
#command = ["-text=Hello authenticated world!"]
pvc = {
echo-config = {
mount_path = "/app/configs"
}
echo-testing = {
mount_path = "/app/test"
}
}
environment = {
PORT = {
value = 4580
}
PAPERLESS_REDIS = {
value = "redis://paperless-redis-svc:6379"
}
database = {
value = "datgg"
}
}
}
bitwarden-admin = { bitwarden-admin = {