Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix incorrect port mapping in docker-compose.yml #18051

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from

Conversation

Kuan-Lun
Copy link

The port mapping for the Synapse service was incorrectly set to 8448:8448/tcp. This has been corrected to 8448:8008/tcp to match the Traefik configuration, which specifies the backend service port as 8008 using the traefik.http.services.synapse.loadbalancer.server.port.

The port mapping for the Synapse service was incorrectly set to `8448:8448/tcp`. This has been corrected to `8448:8008/tcp` to match the Traefik configuration,
which specifies the backend service port as `8008` using the `traefik.http.services.synapse.loadbalancer.server.port`.
@Kuan-Lun Kuan-Lun requested a review from a team as a code owner December 26, 2024 12:55
@CLAassistant
Copy link

CLAassistant commented Dec 26, 2024

CLA assistant check
All committers have signed the CLA.

Copy link
Member

@anoadragon453 anoadragon453 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This came up previously in #17702, and I did some investigation in #17702 (comment).

My conclusion was that directly exposing 8008 would not work as that port won't terminate TLS, whereas remote homeservers sending federation traffic to 8448 would wrap the request in TLS. So I don't believe this would work (unless you put a reverse proxy in front, but the second example does that).

This change is a step in the right direction (Synapse isn't actually listening on port 8448), but I think you'll still fail to federate.

@Kuan-Lun have you had this change working in your setup?

@Kuan-Lun
Copy link
Author

Kuan-Lun commented Jan 3, 2025

Thank you for your response.

To address your question, I have tested this change in my setup with a reverse proxy (Traefik) configured to handle TLS termination. The connection to port 8008 works as expected, and federation is successful under this setup. This aligns with the README for Docker, which recommends using a reverse proxy for TLS support, and the section on Testing a new installation, which states that TLS configuration is required unless running on a local machine.

Additionally, the configuration in line 47 of docker-compose.yml specifies the Host, which implies that users are expected to use a reverse proxy to access port 8008. The Volumes for Docker section does not mention where to place CA files, further supporting this assumption.

I believe this change improves consistency with the Traefik configuration, but I’m happy to adjust if there are other considerations. Let me know your thoughts!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants