matrix-synapse: Update to 1.88.0

This update is going to be the first part of a larger change to how the
use of workers affects the shared configuration, more changes to the
handling of stream writers and federation senders will be coming soon as
well.

Fixes #26
This commit is contained in:
Alexander Olofsson 2023-07-18 18:05:09 +02:00
parent b499ea19df
commit aefb0cfae2
No known key found for this signature in database
GPG key ID: D439C9470CB04C73
6 changed files with 47 additions and 9 deletions

View file

@ -3,10 +3,10 @@ apiVersion: v2
name: matrix-synapse name: matrix-synapse
description: Matrix reference homeserver description: Matrix reference homeserver
icon: https://matrix.org/images/matrix-logo.svg icon: https://matrix.org/images/matrix-logo.svg
appVersion: 1.87.0 appVersion: 1.88.0
type: application type: application
version: 3.5.0 version: 3.6.0
maintainers: maintainers:
- name: Alexander Olofsson - name: Alexander Olofsson
email: ace@haxalot.com email: ace@haxalot.com

View file

@ -49,6 +49,20 @@ data:
log_config: "/synapse/config/log.yaml" log_config: "/synapse/config/log.yaml"
report_stats: {{ required "You need to specify config.reportStats" .Values.config.reportStats }} report_stats: {{ required "You need to specify config.reportStats" .Values.config.reportStats }}
instance_map:
main:
host: {{ include "matrix-synapse.replicationname" . }}
port: 9093
{{- $default := .Values.workers.default }}
{{- range $worker, $config := .Values.workers }}
{{- if and $config.enabled $config.name $config.listeners (has "replication" $config.listeners) }}
{{- $name := $worker | replace "_" "-" }}
{{ $config.name | quote }}:
host: {{ include "matrix-synapse.workername" (dict "global" $ "worker" $name) | quote }}
port: 9093
{{- end }}
{{- end }}
## Ports ## ## Ports ##
listeners: listeners:
@ -133,7 +147,7 @@ data:
{{- else if or (eq $worker "appservice") (eq ($config.app | default "") "appservice") }} {{- else if or (eq $worker "appservice") (eq ($config.app | default "") "appservice") }}
# For appservice worker # For appservice worker
notify_appservices: false notify_appservices_from_worker: {{ $config.name | quote }}
{{- else if or (eq $worker "federation_sender") (eq ($config.app | default "") "federation_sender") }} {{- else if or (eq $worker "federation_sender") (eq ($config.app | default "") "federation_sender") }}
# For federation_sender worker # For federation_sender worker
@ -145,7 +159,7 @@ data:
{{- else if or (eq $worker "user_dir") (eq ($config.app | default "") "user_dir") }} {{- else if or (eq $worker "user_dir") (eq ($config.app | default "") "user_dir") }}
# For user_dir worker # For user_dir worker
update_user_directory: false update_user_directory_from_worker: {{ $config.name | quote }}
{{- end }} {{- end }}
{{- end }} {{- end }}
{{- end }} {{- end }}

View file

@ -51,6 +51,12 @@ spec:
targetPort: listener targetPort: listener
protocol: TCP protocol: TCP
name: listener name: listener
{{- if has "replication" $config.listeners }}
- port: 9093
targetPort: replication
protocol: TCP
name: replication
{{- end }}
selector: selector:
{{- include "matrix-synapse.selectorLabels" $ | nindent 4 }} {{- include "matrix-synapse.selectorLabels" $ | nindent 4 }}
app.kubernetes.io/component: {{ $name }} app.kubernetes.io/component: {{ $name }}

View file

@ -30,10 +30,6 @@ data:
worker_name: {{ $config.name }} worker_name: {{ $config.name }}
{{- end }} {{- end }}
worker_main_http_uri: http://{{ include "matrix-synapse.fullname" $ }}:{{ $.Values.service.port }}
worker_replication_host: {{ include "matrix-synapse.replicationname" $ | quote }}
worker_replication_http_port: 9093
worker_listeners: worker_listeners:
- port: 9090 - port: 9090
tls: false tls: false
@ -44,6 +40,21 @@ data:
- names: [metrics] - names: [metrics]
compress: false compress: false
{{- if $config.listeners }} {{- if $config.listeners }}
{{- if has "replication" $config.listeners }}
{{- if not $config.name }}
{{- fail "Workers with replication listeners must have unique names." }}
{{- end }}
- port: 9093
tls: false
bind_addresses: ['::']
type: http
x_forwarded: true
resources:
- names: [replication]
compress: false
{{- end }}
- port: 8083 - port: 8083
tls: false tls: false
@ -53,7 +64,7 @@ data:
resources: resources:
- names: - names:
{{- toYaml $config.listeners | nindent 14 }} {{- toYaml (without $config.listeners "replication") | nindent 14 }}
compress: false compress: false
{{- end }} {{- end }}

View file

@ -123,6 +123,11 @@ spec:
- name: listener - name: listener
containerPort: 8083 containerPort: 8083
protocol: TCP protocol: TCP
{{- if has "replication" $config.listeners }}
- name: replication
containerPort: 9093
protocol: TCP
{{- end }}
{{- if (or $config.readinessProbe $default.readinessProbe) }} {{- if (or $config.readinessProbe $default.readinessProbe) }}
readinessProbe: readinessProbe:
{{- $config.readinessProbe | default $default.readinessProbe | toYaml | nindent 12 }} {{- $config.readinessProbe | default $default.readinessProbe | toYaml | nindent 12 }}

View file

@ -553,6 +553,7 @@ workers:
## ##
appservice: appservice:
enabled: false enabled: false
name: appservices
## This worker handles sending federation traffic to other Synapse servers. ## This worker handles sending federation traffic to other Synapse servers.
## ##
@ -587,6 +588,7 @@ workers:
## ##
user_dir: user_dir:
enabled: false enabled: false
name: userdir
listeners: [client] listeners: [client]
csPaths: csPaths:
- "/_matrix/client/(api/v1|r0|v3|unstable)/user_directory/search$" - "/_matrix/client/(api/v1|r0|v3|unstable)/user_directory/search$"