-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
[WIP] Dendrite as alternative Matrix Server Implementation #818
Conversation
Thanks for working on this. I'm really exited to get Dendrite up and running. I haven't really dug in but I tried this out and it does appear to be working for me. I did have a few notes from what I can see initially. You can probably go ahead and delete the I also wanted to mention that since we are using Postgres, Dendrite does have the option of running everything from a single database. You are only required to use multiple databases if you are using SQLite. It probably does make sense to use multiple databases since we have the capability to do it and it could provide room for future expansion but just thought I would mention it. I haven't actually set things up correctly yet but on https://github.com/aaronraimist/matrix-docker-ansible-deploy/commits/dendrite-aaron I just hard coded nginx to use dendrite instead of synapse and all of the basics are working. The APIs are available and I was able to register for an account. Exciting! |
I guess going for a single Postgres database is possible, and I probably would have done that for simplicity. .. but given that you've made it use multiple databases already, I guess it's better if we kept that. People can then scale out - moving some heavier/busier databases more easily outside of @aaronraimist, pointing nginx (well In addition to the the above forwarding change, we should also start the process of dynamically tweaking other things as well, based on which homeserver implementation is enabled (various changes in But first.. let's get #456 merged, as it will be necessary for repointing nginx to Dendrite, instead of Synapse. This is indeed very exciting! |
I've updated the build with @aaronraimist's changes to remove the duplicate goofys installation and updated the docker image to the newest version. I think this PR should then be mostly ready once we can connect NGINX correctly. |
I'm very interested in this being merged, and it looks like it's rather close 😃. @Dekker1 how's the NGINX? |
@tecosaur It seems that #456 (which should make it easier to point NGINX in the right direction, which seems to be the last missing technical step) has been merged. I haven't had a chance yet to have a look (and might not be able to in the next few weeks). If you feel you might be able to have a look sooner, then please feel free to add to continue this branch. I'm happy to apply any contributions to the branch when ready. |
f266a94
to
4047e38
Compare
I've rebased the |
Just to confirm, is it only the nginx configuration that's missing? |
There's probably some rewiring work (in |
Would there also be a migration path from Synapse to Dendrite? |
@thomwiggers once the Dendrite developers invent one. That's likely at least 6+ months away and could be multiple years away. |
Not entirely unexpected but rough, it seems quite attractive considering even bridging a few small IRC rooms takes like 2GB of virtual memory with Synapse. |
4047e38
to
45bc576
Compare
We refrain from logging to files for all components, because we rely on systemd-journald anyway.
This brings dendrite.yaml up to date and cleans things up a bit.
I've upgraded Dendrite from 0.3.11 to 0.5.0 and brought the configuration up to date. This still needs more work to integrate properly with |
… implementation The goal is to have a single variable which tells us which homeserver software is in use. Much simpler than having if/elif/elif checks for variables like (`matrix_synapse_enabled` and `matrix_dendrite_enabled`, etc.) everywhere.
Since 025a5ab, we do a similar check in matrix-base.
…_enabled, not the other way around Doing this seems more reasonable and simpler.
…synapse_macaroon_secret_key We're trying to move away from implementation-specific variables, hoping for a clean (implementation-neutral) examples/vars.yml file.
…eneric_secret_key Doing this further simplifies examples/vars.yml.
…-nginx-proxy disabled
This brings matrix-dendrite.service in line with all the other services.
This is the equivalent of b1b4ba5 for the matrix-dendrite role.
Related to spantaleev#818
I believe that Dendrite support is now ready, so I just merged this manually. Thanks to everyone involved! 🙇 To learn more, see the CHANGELOG. If you've been testing this PR and using configuration like this: matrix_synapse_enabled: false
matrix_dendrite_enabled: true
matrix_dendrite_generic_secret_key: "SOME_SECRET_KEY_HERE" you'd need to change to this: matrix_homeserver_implementation: dendrite
matrix_homeserver_generic_secret_key: "SOME_SECRET_KEY_HERE" While the Dendrite team focuses on making Dendrite more production-ready, we should probably focus on documenting Dendrite support better. Some other potential Dendrite-related work that I've identified is:
|
Fantastic! Thanks for all your work. |
…et_key Related to the work done in #818
Related to spantaleev#818
…et_key Related to the work done in spantaleev#818
This PR is a start towards providing Dendrite as an optional alternative Matrix server (as asked in #800). Dendrite is the second generation "sample" implementation of a Matrix server and offers to be more performant alternative to Synapse, allowing administrators to run Matrix on more minimal hardware. Currently Dendrite is in beta and does not contain all features that Synapse does.
This Dendrite role is directly based on the
matrix-synapse
role to hopefully be easy to maintain side-by-side.Using Dendrite
To use dendrite you have to enable Dendrite, disable Synapse (to not cause any conflict), and Dendrite, like Synapse, will need a shared secret to create accounts:
What is currently working
create-account
binary provided) should be working, both using Ansible and amatrix-dendrite-create-account
script added to the system.What is not working
I got stuck (and ran out of time) trying to configure the correct TLS / Nginx settings to correctly proxy Dendrite through Nginx and allow outside connections to Dendrite. Once this is fixed, the hope is that this would provide correct Dendrite functionality.
Even more work
The most important work that has to happen thereafter is that the functionality is correctly documented so other users will know how to activate the Dendrite server, how/if it connects with the other components (which I'm not sure about), and maybe some general information about Dendrite.
Call for Help
I believe this is a good start to providing Dendrite functionality in these Ansible scripts, but there is still quite a bit of work to be done. Although I had fun working on this for a few hours and would love to continue, I'm not sure how much time I will have in the next few weeks. So if you feel like you would like to have a go at fixing the last parts, then feel free to take over and amend my work. I'm happy to answer any questions and help with any superseding PRs.