diff --git a/matrix-synapse/Chart.yaml b/matrix-synapse/Chart.yaml index 8bb8c07..4995b9a 100644 --- a/matrix-synapse/Chart.yaml +++ b/matrix-synapse/Chart.yaml @@ -2,7 +2,7 @@ apiVersion: v2 name: matrix-synapse description: A Helm chart to deploy a Matrix Synapse server on Kubernetes type: application -version: 1.1.0+upv1.149.1 +version: 1.2.0+upv1.149.1 appVersion: "v1.149.1" maintainers: - name: jklein \ No newline at end of file diff --git a/matrix-synapse/templates/matrix-delegation-nginx.deployment.yaml b/matrix-synapse/templates/matrix-delegation-nginx.deployment.yaml index 1d10d79..7066cda 100644 --- a/matrix-synapse/templates/matrix-delegation-nginx.deployment.yaml +++ b/matrix-synapse/templates/matrix-delegation-nginx.deployment.yaml @@ -28,13 +28,31 @@ spec: subPath: nginx.conf resources: limits: - memory: "128Mi" - cpu: "250m" - ephemeral-storage: "100Mi" + memory: "{{ .Values.matrix.delegation.resources.limits.memory }}" + cpu: "{{ .Values.matrix.delegation.resources.limits.cpu }}" + ephemeral-storage: "{{ .Values.matrix.delegation.resources.limits.ephemeralStorage }}" requests: - memory: "64Mi" - cpu: "125m" - ephemeral-storage: "50Mi" + memory: "{{ .Values.matrix.delegation.resources.requests.memory }}" + cpu: "{{ .Values.matrix.delegation.resources.requests.cpu }}" + ephemeral-storage: "{{ .Values.matrix.delegation.resources.requests.ephemeralStorage }}" + readinessProbe: + httpGet: + path: / + port: http + scheme: HTTP + initialDelaySeconds: 5 + periodSeconds: 10 + timeoutSeconds: 3 + failureThreshold: 3 + livenessProbe: + httpGet: + path: / + port: http + scheme: HTTP + initialDelaySeconds: 15 + periodSeconds: 10 + timeoutSeconds: 3 + failureThreshold: 3 volumes: - name: nginx-config configMap: diff --git a/matrix-synapse/templates/matrix-synapse.sfs.yaml b/matrix-synapse/templates/matrix-synapse.sfs.yaml index dc22fcd..8f27e0e 100644 --- a/matrix-synapse/templates/matrix-synapse.sfs.yaml +++ b/matrix-synapse/templates/matrix-synapse.sfs.yaml @@ -38,8 +38,33 @@ spec: - name: http containerPort: 8008 protocol: TCP - # TODO: Add liveness and readiness probes - # TODO: Add resource requests and limits + readinessProbe: + httpGet: + path: /health + port: http + scheme: HTTP + initialDelaySeconds: 10 + periodSeconds: 10 + timeoutSeconds: 5 + failureThreshold: 3 + livenessProbe: + httpGet: + path: /health + port: http + scheme: HTTP + initialDelaySeconds: 30 + periodSeconds: 10 + timeoutSeconds: 5 + failureThreshold: 3 + resources: + requests: + memory: "{{ .Values.matrix.resources.requests.memory }}" + cpu: "{{ .Values.matrix.resources.requests.cpu }}" + ephemeral-storage: "{{ .Values.matrix.resources.requests.ephemeralStorage }}" + limits: + memory: "{{ .Values.matrix.resources.limits.memory }}" + cpu: "{{ .Values.matrix.resources.limits.cpu }}" + ephemeral-storage: "{{ .Values.matrix.resources.limits.ephemeralStorage }}" volumeMounts: - name: matrix-synapse-volume mountPath: /data diff --git a/matrix-synapse/values.yaml b/matrix-synapse/values.yaml index 9e4e684..66f2a82 100644 --- a/matrix-synapse/values.yaml +++ b/matrix-synapse/values.yaml @@ -5,6 +5,24 @@ matrix: delegation: enabled: false serverUrl: null + resources: + limits: + memory: "128Mi" + cpu: "250m" + ephemeralStorage: "100Mi" + requests: + memory: "64Mi" + cpu: "125m" + ephemeralStorage: "50Mi" + resources: + requests: + memory: "1Gi" + cpu: "1" + ephemeralStorage: "1Gi" + limits: + memory: "2Gi" + cpu: "2" + ephemeralStorage: "2Gi" storage: amount: 10Gi