Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

docs/workers.md media_repository regex on federation port #8695

Closed
localguru opened this issue Oct 30, 2020 · 2 comments
Closed

docs/workers.md media_repository regex on federation port #8695

localguru opened this issue Oct 30, 2020 · 2 comments
Labels
A-Docs things relating to the documentation Z-Help-Wanted We know exactly how to fix this issue, and would be grateful for any contribution

Comments

@localguru
Copy link
Contributor

localguru commented Oct 30, 2020

Description

This is not a bug, but should be mentioned in docs/workers.md:
If homeserver A sends an image to homeserver B, homerserver B is asking for the image on the federation port 8448 to get the media on URL /_matrix/media/. If (on homeserver A) worker_app: synapse.app.media_repository is enabled and client and federation are split to different vhosts (443 and 8448) the regex /_matrix/media/for the media worker must point to the internal media worker port in nginx vhost for federation port 8448 too. Otherwise homeserver B gets a 404 (not found) on the federation port 8448 of homeserver A. The mean thing is that on homeserver B, the user/client gets the message "Error decrypting image" and not something like "not found".

So it might be a good idea to mention under "synapse.app.media_repository" in docs/workers.md that the regex location /_matrix/media/ for the media worker must be available on client and federation port.

Version information

@erikjohnston erikjohnston added A-Docs things relating to the documentation Z-Help-Wanted We know exactly how to fix this issue, and would be grateful for any contribution labels Oct 30, 2020
@localguru
Copy link
Contributor Author

see #8701

erikjohnston pushed a commit that referenced this issue Nov 6, 2020
If SSO login is used (e.g. SAML) in a multi worker setup, it should be mentioned that currently all SAML logins must run on the same worker, see #7530

Also, if you are using different ports (for example 443 and 8448) in a reverse proxy for client and federation, the path `/_matrix/media` on the client and federation port must point to the listener of the `media_repository` worker, otherwise you'll get a 404 on the federation port for the path `/_matrix/media`, if a remote server is trying to get the media object on federation port, see #8695
@localguru
Copy link
Contributor Author

closed by PR #8701

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
A-Docs things relating to the documentation Z-Help-Wanted We know exactly how to fix this issue, and would be grateful for any contribution
Projects
None yet
Development

No branches or pull requests

2 participants