add the option for hostpath as well
This commit is contained in:
@@ -13,8 +13,9 @@ variable "kubernetes" {
|
||||
image = string
|
||||
pvc = optional(map(object({
|
||||
name = string
|
||||
pvc = optional(bool)
|
||||
pvc = optional(bool,false)
|
||||
config_map = optional(bool, false)
|
||||
host_path = optional(string)
|
||||
pvc_size = optional(string)
|
||||
mount_path = string
|
||||
})))
|
||||
@@ -395,10 +396,18 @@ resource "kubernetes_deployment_v1" "automatic" {
|
||||
dynamic "config_map" {
|
||||
for_each = volume.value.config_map ? [1] : []
|
||||
content {
|
||||
name = "${volume.value.name}"
|
||||
name = volume.value.name
|
||||
}
|
||||
}
|
||||
|
||||
dynamic "host_path" {
|
||||
for_each = volume.value.host_path != null ? [1] : []
|
||||
content {
|
||||
path = volume.value.host_path
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -356,12 +356,13 @@ kubernetes = {
|
||||
media = {
|
||||
pvc = false
|
||||
config_map = true
|
||||
name = "media"
|
||||
name = "gitea-runner-configfile"
|
||||
pvc_size = "2Mi"
|
||||
mount_path = "/usr/src/paperless/media"
|
||||
mount_path = "/tmp/usr/src/paperless/media"
|
||||
}
|
||||
export = {
|
||||
pvc = true
|
||||
# pvc = true
|
||||
host_path = "/tmp"
|
||||
name = "export"
|
||||
pvc_size = "2Mi"
|
||||
mount_path = "/usr/src/paperless/export"
|
||||
|
||||
Reference in New Issue
Block a user