adding database support

This commit is contained in:
pierre.geeraert
2026-10-12 09:54:26 +01:00
parent b27bfe5714
commit 534958f828
2 changed files with 5 additions and 6 deletions
+4 -5
View File
@@ -43,7 +43,7 @@ resource "kubernetes_deployment_v1" "database-automatic" {
volume_mount {
mount_path = try(each.value.database.mountPath, "/var/lib/postgresql/")
name = "${each.key}-db-pvc"
name = "${each.key}-db-volume"
}
dynamic "volume_mount" {
@@ -82,7 +82,6 @@ resource "kubernetes_deployment_v1" "database-automatic" {
content {
name = env.value.value_from.secret_key_ref.name
key = env.value.value_from.secret_key_ref.key
# optional = true
}
}
}
@@ -96,9 +95,9 @@ resource "kubernetes_deployment_v1" "database-automatic" {
volume {
name = "${each.key}-db-pvc"
persistent_volume_claim {
claim_name = "${each.key}-db-pvc"
name = "${each.key}-db-volume"
host_path {
path = try(each.value.database.host_path, join("/", [var.storage_path.main_storage, coalesce(each.value.namespace, each.value.connected_namespace, each.key), join("-", [each.key, "db"])]))
}
}
+1 -1
View File
@@ -37,7 +37,7 @@ kubernetes = {
gitea = {
enabled = false
#enabled = false
#docker = true
image = "gitea/gitea:1.27.0"
# no service_port: nginx reaches http://gitea:3000 over deployment_network