From 6650dc232855843cb9a81aaa8fac983979463dcc Mon Sep 17 00:00:00 2001 From: JesseBot Date: Mon, 24 Jul 2023 12:49:44 +0200 Subject: [PATCH] add existingClaim for synapseConfig and removing typokign from maintainers, though he is still mentioned in the readme and license (#5) --- charts/matrix/Chart.yaml | 6 +----- charts/matrix/README.md | 6 ++++-- .../matrix/templates/synapse/config-pvc.yaml | 18 ++++++++++++++++++ .../matrix/templates/synapse/deployment.yaml | 4 ++++ charts/matrix/values.yaml | 7 +++++++ 5 files changed, 34 insertions(+), 7 deletions(-) create mode 100644 charts/matrix/templates/synapse/config-pvc.yaml diff --git a/charts/matrix/Chart.yaml b/charts/matrix/Chart.yaml index 990bae43..cefe9b76 100644 --- a/charts/matrix/Chart.yaml +++ b/charts/matrix/Chart.yaml @@ -8,14 +8,10 @@ sources: type: application -version: 3.1.1 +version: 3.2.0 appVersion: 1.88.0 maintainers: - # this person hasn't updated their upstream repo in years - - name: "dacruz21" - email: "david@typokign.com" - url: "https://github.com/dacruz21/" - name: "Arkaniad" email: "rhea@isomemetric.com" url: "https://github.com/Arkaniad/" diff --git a/charts/matrix/README.md b/charts/matrix/README.md index 283d9542..f49052b7 100644 --- a/charts/matrix/README.md +++ b/charts/matrix/README.md @@ -1,6 +1,6 @@ # matrix -![Version: 3.1.1](https://img.shields.io/badge/Version-3.1.1-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 1.88.0](https://img.shields.io/badge/AppVersion-1.88.0-informational?style=flat-square) +![Version: 3.2.0](https://img.shields.io/badge/Version-3.2.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 1.88.0](https://img.shields.io/badge/AppVersion-1.88.0-informational?style=flat-square) A Helm chart to deploy a Matrix homeserver stack into Kubernetes @@ -10,7 +10,6 @@ A Helm chart to deploy a Matrix homeserver stack into Kubernetes | Name | Email | Url | | ---- | ------ | --- | -| dacruz21 | | | | Arkaniad | | | | jessebot | | | @@ -266,6 +265,9 @@ A Helm chart to deploy a Matrix homeserver stack into Kubernetes | volumes.signingKey.capacity | string | `"1Mi"` | Capacity of the signing key PVC. Note: 1Mi is more than enough, but some cloud providers set a minimum PVC size of 1Mi or 1Gi, adjust as necessary | | volumes.signingKey.existingClaim | string | `""` | name of an existing persistent volume claim to use for signing key | | volumes.signingKey.storageClass | string | `""` | Storage class (optional) | +| volumes.synapseConfig.capacity | string | `"1Mi"` | Capacity of the signing key PVC. Note: 1Mi is more than enough, but some cloud providers set a minimum PVC size of 1Mi or 1Gi, adjust as necessary | +| volumes.synapseConfig.existingClaim | string | `""` | name of an existing persistent volume claim for synapse config file | +| volumes.synapseConfig.storageClass | string | `""` | Storage class (optional) | ---------------------------------------------- Autogenerated from chart metadata using [helm-docs v1.11.0](https://github.com/norwoodj/helm-docs/releases/v1.11.0) diff --git a/charts/matrix/templates/synapse/config-pvc.yaml b/charts/matrix/templates/synapse/config-pvc.yaml new file mode 100644 index 00000000..54e419b5 --- /dev/null +++ b/charts/matrix/templates/synapse/config-pvc.yaml @@ -0,0 +1,18 @@ +{{- if not .Values.volumes.synapseConfig.existingClaim }} +apiVersion: v1 +kind: PersistentVolumeClaim +metadata: + name: {{ include "matrix.fullname" . }}-synapse-config + labels: +{{ include "matrix.labels" . | indent 4}} +{{ include "matrix.synapse.labels" . | indent 4}} +spec: + {{- if .Values.volumes.synapseConfig.storageClass }} + storageClassName: {{ .Values.volumes.synapseConfig.storageClass }} + {{- end }} + accessModes: + - ReadWriteOnce + resources: + requests: + storage: {{ .Values.volumes.synapseConfig.capacity }} +{{- end }} diff --git a/charts/matrix/templates/synapse/deployment.yaml b/charts/matrix/templates/synapse/deployment.yaml index 8889016a..cf4d52c1 100644 --- a/charts/matrix/templates/synapse/deployment.yaml +++ b/charts/matrix/templates/synapse/deployment.yaml @@ -191,7 +191,11 @@ spec: name: {{ include "matrix.fullname" . }}-initial-synapse-config - name: synapse-config persistentVolumeClaim: + {{- if not .Values.volumes.synapseConfig.existingClaim }} claimName: {{ include "matrix.fullname" . }}-synapse-config + {{ else }} + claimName: {{ .Values.volumes.synapseConfig.existingClaim }} + {{- end }} - name: signing-key persistentVolumeClaim: {{- if not .Values.volumes.signingKey.existingClaim }} diff --git a/charts/matrix/values.yaml b/charts/matrix/values.yaml index a8d6870c..a1858d52 100644 --- a/charts/matrix/values.yaml +++ b/charts/matrix/values.yaml @@ -228,6 +228,13 @@ volumes: storageClass: "" # -- name of an existing persistent volume claim to use for signing key existingClaim: "" + synapseConfig: + # -- Capacity of the signing key PVC. Note: 1Mi is more than enough, but some cloud providers set a minimum PVC size of 1Mi or 1Gi, adjust as necessary + capacity: 1Mi + # -- Storage class (optional) + storageClass: "" + # -- name of an existing persistent volume claim for synapse config file + existingClaim: "" ingress: enabled: true