docs: Add Delegation page #1414
No reviewers
Labels
No labels
Blocked
Bug
Cherry-picking
Database
Dependencies
Dependencies/Renovate
Difficulty
Easy
Difficulty
Hard
Difficulty
Medium
Documentation
Enhancement
Good first issue
Help wanted
Inherited
Matrix/Administration
Matrix/Appservices
Matrix/Auth
Matrix/Client
Matrix/Core
Matrix/E2EE
Matrix/Federation
Matrix/Hydra
Matrix/MSC
Matrix/Media
Matrix/T&S
Meta
Meta/CI
Meta/Packaging
Priority
Blocking
Priority
High
Priority
Low
Security
Status
Confirmed
Status
Duplicate
Status
Invalid
Status
Needs Investigation
Support
To-Merge
Wont fix
old/ci/cd
old/rust
No milestone
No project
No assignees
6 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
continuwuation/continuwuity!1414
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "stratself/continuwuity:stratself/docs-delegation"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
This pull request adds a page for delegation in a newly created Advanced section. The intent is to provide a clear reference point for delegation-related inquiries, which is common in the chatrooms.
I intend to populate Advanced with further guides, and since this is reasonably specific I think it can go in there.
Relates to #1361. Perhaps that PR can simplify well-known processes by redirecting users here.
Further reverse proxy examples (e.g. Nginx) are welcome
Pull request checklist:
mainbranch, and the branch is named something other thanmain.myself, if applicable. This includes ensuring code compiles.
Thank you! This looks good for an explainer, although if it's an advanced guide it should probably explain client delegation too, and maybe mention the support file? At the moment it seems pretty good as something to link people who have questions about it though, so if you think that's the level of detail that's most useful I won't argue
@ -0,0 +1,111 @@# Delegation/split-domainMatrix allows clients and servers to discover a homeserver's "true" destination via _`.well-known` delegation_. This is especially useful if you would like to:Via an algorithm that includes this, as well as srv records etc - see the spec page. If it's going in the advanced section, best fully explain things :3
I've linked the specs at the bottom, and add references to
.well-known/matrix/support. Not sure how to elaborate in-docs so lemme know if any ideas@ -0,0 +1,125 @@# Delegation/split-domainIf you're not going to go over SRV delegation in this, I think this should be renamed to "well-known delegation" instead of just delegation.
I've added some guidance on SRVs with a huge non-recommendation. Compared to Synapse's docs on this one I think it goes into a bit more details
I'm not sure this needs to be in an "advanced" section, since it's a pretty common ask, but the writing looks mostly good except for a few nits.
@ -0,0 +5,4 @@- Serve Continuwuity on a subdomain while having only the base domain for your usernames- Use a port other than `:8448` for server-to-server connectionsThis guide will show you how to have `@user:example.com` usernames while serving Continuwuity on `https://matrix.example.com`. It assumes using port 443 for both client-to-server connections and server-to-server federation.s/using/you are using/
@ -0,0 +11,4 @@First, ensure you have set up A/AAAA records for `matrix.example.com` and `example.com` pointing to your IP.Then, ensure that the `server_name` field matches your intended username suffix. If this is not the case, you **MUST** wipe the database directory and reinstall Continuwuity with your desired `server_name`sentence should end with a period
@ -0,0 +46,4 @@## Serving with a reverse proxyThe steps above will generate three JSON files: `.well-known/matrix/client`, `.well-known/matrix/server`, and `.well-known/matrix/support`. To enable discovery of your homeserver's destination and contact details, you will need to serve these files from your base domain.this should be amended to make it clear that it doesn't generate JSON files on the filesystem, but rather makes Continuwuity serve them
I've amended it to say C10y serves the files, and they need to be reverse proxied from apex domain
@ -0,0 +81,4 @@</details>Bring up Continuwuity and the reverse proxy. You should now see the following contentssuggested wording: "Once you've restarted Continuwuity and your reverse proxy, visit these routes with your web browser and check that the responses match the examples below:"
@ -0,0 +116,4 @@### Cannot log in with web clientsMake sure there is an `Access-Control-Allow-Origin: *` header in your `.well-known/matrix/client` path. While continuwuity serves this header by default, it may be dropped by reverse proxies or other middlewares.inconsistent capitalization of Continuwuity
@ -0,0 +122,4 @@## Using SRV records (not recommended)The following methods uses the legacy SRV records and only apply to federation traffic. They are provided only for completeness, and are **not recommended** for most users due to increased complexity with little benefits. If you have already set up `.well-known` delegation as above, you can safely skip this part.this could go in a
:::warncallout for extra emphasisstratself referenced this pull request2026-02-26 04:06:09 +00:00
@ -0,0 +48,4 @@After doing the steps above, Continuwuity will serve these 3 JSON files:- `.well-known/matrix/client`: for Client-Server discoveryI would kind of like if these had a / at the start, but its not really needed.
it's done
I added another case for SRV records to be used as a fallback discovery method. Of course hidden in a <details> section. Since the docs is in Advanced topics I thought this would be an addition that makes sense
Also rebased to main
@stratself wrote in #1414 (comment):
Love how that actually rendered as a details in my email client
b61395b0e4eee1a5b7d1There is inconsistent capitalization in the commit messages. Shouldn't they all start uppercase?
@Henry-Hiles wrote in #1414 (comment):
Following Conventional Commits specification, rule 15, there should not be any difference in uppercase/lowercase. However, I do agree I should have stuck to one or the other. I am currently more inclined to the lowercase case, as it is the case presented in Continuwuity's https://forgejo.ellis.link/continuwuation/continuwuity/src/branch/main/CONTRIBUTING.md#commit-messages and on the Conventional Commits website.
Do let me know if, and how, previous commits can be rewritten
change history in the manner of your choosing, e.g. rebase, or undoing commits and recommiting, then
git push --force. Out rn, can give better instructions when home. However, looking at latest commits to continuwuity, some are uppercase some lowercase, and maybe this will be squash merged anyways idk. Therefore, idk if changing is even needed.docs: add Delegation pageto docs: Add Delegation page