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
Matrix-Synapse Client API and Federation 502 Errors with External Nginx Server #790
Comments
Hi! Is nginx running on the host itself or is it in some container? The logs for Those for If you're running your external nginx server in some container, you'd need other modifications. |
Hello! Thanks for taking a look. Nginx is not running in a container but is installed through Ubuntu's repos.
Here is
Here is
Here is partial
Anything else networking related you want to know? Here are contents of the nginx element.conf file. (I've made no manual modifications besides copying it to my nginx directory, cleaning up the whitespace, and modifying the SSL path. The Mailcow installation took over ports 8080 and 8443 and Ansible modified the port to 8765.) The element webpage loads but reports the server is not found, as mentioned.
Here are the contents of the matrix-synapse conf. (Modified to reduce whitespace manually and again copied to the nginx directory and modified the SSL path.)
|
Hmm.. strange.. I can't really reproduce this in my testing. Do you also get "connection refused" when doing |
No, that's coming through fine.
Could something have gone wrong with installation (and in attempted setting up the server again after initial install) due to the preexisting matrix-synpase-py3 server? |
Sounds like Synapse may be failing to start then. Can you try But.. it was showing up in Both I don't see how |
I performed Method 2 and everything is working. I'm not sure what makes the difference, perhaps something with Mailcow-dockerized. |
Good to hear you found some way! 👍 |
I am having a similar issue. I have two VMs, one a reverse proxy and another this project. All my DNS records are fine, but when I curl the services I get connection refused. According to netstat the docker-proxies are binding to localhost. Shouldn't they be binding to 0.0.0.0 in order for my external nginx proxy to work properly? |
If you disable All of these port bindings can be changed though. If you search for Instead of exposing each service's ports one by one, you can do something else -- keep using You'd probably wish to change |
Perfect, I don't know why I overlooked that. Everything is working excellently. |
The problem
After installing the playbook and attempting to run Matrix, I am bumping into a 502 error that I'm having trouble pinning down and correcting. This error is preventing logging into server.
The Server, Configs, and Ansible
The Matrix install was performed on an Ubuntu 20.04 server that had previously used the Matrix Synapse repo and matrix-synapse-py3 package. Matrix was properly functioning in that installation. This package has been removed from the server. (I turned to this Ansible installation after failing to get Coturn properly functioning for Audio and Video in Element.)
The current installation through Ansible has imported the database and media store from the previous install.
I am utilizing the generated Nginx configs through an external Nginx server, as the server hosts other websites and a Mailcow-dockerized installation. I am not seeing any conflicting ports between the the Matrix and Mailcow-dockerized installations.
I have added the following to the base domain's Nginx server config.
The Ansible installation is running.
Nginx is running as is Synpase; port 443 is most definitely open.
Errors, Logs, Federation Testing
I am seeing the following errors on a self-check.
Nginx reports the following on https://matrix.domain.tld:8448.
Nginx reports the following on https://element.domain.tld
Federationtester logs the following Nginx error.
Federationtester reports the following error regarding the JSON.
Element reports the following.
My hypothesis is something is improperly configured in the Nginx server, but I am not sure what after looking over the matrix-synapse.conf file.
Please let me know if I can provide further information and what information is desired.
The text was updated successfully, but these errors were encountered: