fix
This commit is contained in:
@@ -13,7 +13,14 @@ locals {
|
||||
"ingress-class" = var.ingress-class
|
||||
"backups" = var.backups
|
||||
}
|
||||
dolibarr = { for k, v in var.dolibarr : k => v if k!="enable" }
|
||||
dolibarr = { for k, v in var.dolibarr : k => v if contains(["enable","storage"],k) }
|
||||
doli-storage = merge({
|
||||
"storage" = {
|
||||
"size" = "10Gi"
|
||||
"accessMode" = var.storage-classes.FilesystemReadWriteMany!=""?"ReadWriteMany":"ReadWriteOnce"
|
||||
"type" = "Filesystem"
|
||||
}
|
||||
}, { for k, v in var.dolibarr : k => v if k=="storage" })
|
||||
}
|
||||
|
||||
resource "kubernetes_namespace_v1" "erp-ns" {
|
||||
@@ -39,6 +46,6 @@ resource "kubectl_manifest" "dolibarr" {
|
||||
distrib: "${var.distributions.domain}"
|
||||
category: "apps"
|
||||
component: "dolibarr"
|
||||
options: ${jsonencode(merge(local.global, local.dolibarr))}
|
||||
options: ${jsonencode(merge(local.global, local.doli-storage, local.dolibarr))}
|
||||
EOF
|
||||
}
|
||||
|
||||
@@ -11,21 +11,6 @@ options:
|
||||
examples:
|
||||
- your-company
|
||||
type: string
|
||||
domain-name:
|
||||
default: your_company.com
|
||||
examples:
|
||||
- your_company.com
|
||||
type: string
|
||||
issuer:
|
||||
default: letsencrypt-prod
|
||||
examples:
|
||||
- letsencrypt-prod
|
||||
type: string
|
||||
ingress-class:
|
||||
default: traefik
|
||||
examples:
|
||||
- traefik
|
||||
type: string
|
||||
distributions:
|
||||
default:
|
||||
core: core
|
||||
@@ -71,6 +56,36 @@ options:
|
||||
default: backup-settings
|
||||
type: string
|
||||
type: object
|
||||
ingress-class:
|
||||
default: traefik
|
||||
examples:
|
||||
- traefik
|
||||
type: string
|
||||
storage-classes:
|
||||
default:
|
||||
BlockReadWriteMany: ''
|
||||
BlockReadWriteOnce: ''
|
||||
FilesystemReadWriteMany: ''
|
||||
FilesystemReadWriteOnce: ''
|
||||
examples:
|
||||
- BlockReadWriteMany: ''
|
||||
BlockReadWriteOnce: ''
|
||||
FilesystemReadWriteMany: ''
|
||||
FilesystemReadWriteOnce: ''
|
||||
properties:
|
||||
BlockReadWriteMany:
|
||||
default: ''
|
||||
type: string
|
||||
BlockReadWriteOnce:
|
||||
default: ''
|
||||
type: string
|
||||
FilesystemReadWriteMany:
|
||||
default: ''
|
||||
type: string
|
||||
FilesystemReadWriteOnce:
|
||||
default: ''
|
||||
type: string
|
||||
type: object
|
||||
dolibarr:
|
||||
default:
|
||||
enable: true
|
||||
@@ -81,6 +96,16 @@ options:
|
||||
default: true
|
||||
type: boolean
|
||||
type: object
|
||||
domain-name:
|
||||
default: your_company.com
|
||||
examples:
|
||||
- your_company.com
|
||||
type: string
|
||||
issuer:
|
||||
default: letsencrypt-prod
|
||||
examples:
|
||||
- letsencrypt-prod
|
||||
type: string
|
||||
dependencies: []
|
||||
providers:
|
||||
kubernetes: true
|
||||
|
||||
Reference in New Issue
Block a user