Zoom Sucks: Riot Chat + Jitsi Video Conference Setup

Recommended Posts

On 12/4/2020 at 9:49 PM, HojojojoWololo said:

Yep, the tutorial kinda works with a few adjustments. But since I had to work my way through multiple posts and other sites I would love to spare you the pains.


My initial setup was an unraid server running Swag (since the Letsencrypt docker wont be supported anymore in the future due to naming rights - spaceinvaderone made a great tutorial how to switch from the Letsencrypt to the Swag docker). Yinzer's tutorial for the Letsencrypt docker still seems fine, though you really should use the Swag docker instead. Furthermore, Jitsi was already up and running when I started to install Matrix (thanks to spaceinvaderone, again 😄), so I will skip that part. If you have to set up a reverse proxy (be sure to use the Swag container instead of the Letsencrypt container) or want to switch to Swag, the spaceinvaders videos are really helpful. My adjustments to @yinzer's Matrix setup:


Setting up Swag (formerly Letsencrypt)


matrix.subdomain.conf - thanks to @akamemmnon for his config

server {
	listen 443 ssl;
	listen 8448 ssl;
	server_name bridge.*;

	include /config/nginx/ssl.conf;
	client_max_body_size 0;

	location / {
		include /config/nginx/proxy.conf;
		resolver valid=30s;
		set $upstream_app your.unraid.server.ip;
		set $upstream_port 8008;
		set $upstream_proto http;
		proxy_pass $upstream_proto://$upstream_app:$upstream_port;
		proxy_set_header X-Forwarded-For $remote_addr;
	location /.well-known/matrix/server {
        default_type application/json;
               return 200 '{"m.server": "yourdomain.com:443"}';
             add_header Access-Control-Allow-Origin *;

Make sure to change your.unraid.server.ip to your unraid server's IP adress and yourdomain.com to your domain name 😁


Since Riot was renamed to Element, there is a new container so we will use that one instead of Riot and have to adjust the Swag configuration file.



 server {
       listen 443 ssl;
       server_name chat.*;
       include /config/nginx/ssl.conf;
       client_max_body_size 0;

       location / {
               include /config/nginx/proxy.conf;
               resolver valid=30s;
               set $upstream_app element-web;
               set $upstream_port 80;
               set $upstream_proto http;
               proxy_pass $upstream_proto://$upstream_app:$upstream_port;


Install Matrix and configure it according to yinzer's tutorial. Adjustments:


Setting up Matrix




under "listeners" in the "# Unsecure HTTP listeners: for when matrix traffic passes through a reverse proxy" section:

  - port: 8008
    tls: false
    type: http
    x_forwarded: true
    bind_addresses: ['']
      - names: ['client', 'federation']

  - port: 8448
    tls: false
    type: http
    x_forwarded: true
    bind_addresses: ['']
      - names: ['federation']

Make sure you respect the .yaml syntax - that's what created the syntax errors of @lewisd19, @jafi and @l2evy. No tabs, just spaces! Additionally, the resource names have to be commented with inverted commas: 'text'. The examples over this section can help you with this.


If you use the standard SQLite database, make sure you changed the database's direction - thanks to @spyd4r for your input.

  name: sqlite3
    database: /homeserver.db


  name: sqlite3
    database: /data/homeserver.db




Delete the first line which says "lt-cred-mech" since we use "use-auth-secret". Also think about adding the pidfile and userdb infos yinzer posted in his tutorial. My turnserver.conf looks like this:



Setting up Element-Web (based on @yinzer's tutorial for Riot Chat)


1. Before we start, we need to manually create the config path and pull in the default config. So open the terminal/SSH to your server.

2. Create the config path by executing

mkdir -p /mnt/user/appdata/element-web/config

3. Download the default config by executing

wget -O /mnt/user/appdata/element-web/config/config.json https://raw.githubusercontent.com/vector-im/element-web/develop/element.io/app/config.json

4. In Community Applications, search for `element-web' by vectorim
5. Set the `Network Type` to `Custom: ssl proxy`
6. Set the `Fixed IP address` to `` (or whatever)
7. The rest of the settings should be fine. Create the container and run it.


Now lets edit our Element config. It's a JSON file, so make sure you respect JSON syntax

1. Edit  /mnt/user/appdata/riot-web/config/config.json

2. Change 'default_server_name' to

"default_server_name": "bridge.yourdomain.com",

3. Insert your domain to the 'roomDirectory'

"roomDirectory": {
        "servers": [

4. Add the following lines in the config:

  "jitsi": {
    "preferredDomain": "meet.yourdomain.com"


Caution: Using a Jitsi server with enabled authentification doesn't work with Element! And this should also be noticed:



Jitsi Setup


Just follow spaceinvaderone's instructions in this video.


But for setting up a working Matrix synapse and the Element-web container, that should be it. @yinzer Feel free to update your initial post with this adjustments 😃

Hello can I use nginx proxy manager other than swag? And if so how thank you!

Link to comment
  • 2 months later...
  • 5 months later...

Hello. My Matrix has e Problem sins newest Update v1.86.0. It wont start. Have antibody a idea whats can be?



2023-06-25 17:13:20,255 - root - 348 - WARNING - main - ***** STARTING SERVER *****
2023-06-25 17:13:20,255 - root - 349 - WARNING - main - Server /matrix/venv/lib/python3.11/site-packages/synapse/app/homeserver.py version 1.86.0
2023-06-25 17:13:20,255 - root - 354 - INFO - main - Server hostname: bridge.mbasler.ch
2023-06-25 17:13:20,255 - root - 355 - INFO - main - Instance name: master
2023-06-25 17:13:20,255 - root - 356 - INFO - main - Twisted reactor: EPollReactor
2023-06-25 17:13:20,255 - synapse.app.homeserver - 349 - INFO - main - Setting up server
2023-06-25 17:13:20,255 - synapse.server - 337 - INFO - main - Setting up.
2023-06-25 17:13:20,261 - synapse.storage.databases - 66 - INFO - main - [database config 'master']: Checking database server
2023-06-25 17:13:20,261 - synapse.storage.databases - 69 - INFO - main - [database config 'master']: Preparing for databases ['main', 'state']
2023-06-25 17:13:20,261 - synapse.storage.prepare_database - 120 - INFO - main - ['main', 'state']: Checking existing schema version
2023-06-25 17:13:20,262 - synapse.storage.prepare_database - 124 - INFO - main - ['main', 'state']: Existing schema is 77 (+5 deltas)
2023-06-25 17:13:20,262 - synapse.storage.databases.main - 288 - INFO - main - Checking database for consistency with configuration...
2023-06-25 17:13:20,264 - synapse.storage.prepare_database - 418 - INFO - main - Applying schema deltas for v77
2023-06-25 17:13:20,264 - synapse.storage.prepare_database - 418 - INFO - main - Applying schema deltas for v78
2023-06-25 17:13:20,265 - synapse.storage.prepare_database - 513 - INFO - main - Running 78/01_validate_and_update_profiles.py:run_upgrade
2023-06-25 17:13:20,278 - synapse.storage.prepare_database - 513 - INFO - main - Running 78/02_validate_and_update_user_filters.py:run_upgrade
2023-06-25 17:13:20,279 - synapse.app._base - 215 - ERROR - main - Exception during startup
Traceback (most recent call last):
  File "/matrix/venv/lib/python3.11/site-packages/synapse/app/homeserver.py", line 352, in setup
  File "/matrix/venv/lib/python3.11/site-packages/synapse/server.py", line 339, in setup
    self.datastores = Databases(self.DATASTORE_CLASS, self)
  File "/matrix/venv/lib/python3.11/site-packages/synapse/storage/databases/__init__.py", line 74, in __init__
  File "/matrix/venv/lib/python3.11/site-packages/synapse/storage/prepare_database.py", line 141, in prepare_database
  File "/matrix/venv/lib/python3.11/site-packages/synapse/storage/prepare_database.py", line 514, in _upgrade_existing_database
    module.run_upgrade(cur, database_engine, config=config)
  File "/matrix/venv/lib/python3.11/site-packages/synapse/storage/schema/main/delta/78/02_validate_and_update_user_filters.py", line 85, in run_upgrade
    cur.execute(copy_sql, (f"{hostname}",))
  File "/matrix/venv/lib/python3.11/site-packages/synapse/storage/database.py", line 417, in execute
    self._do_execute(self.txn.execute, sql, parameters)
  File "/matrix/venv/lib/python3.11/site-packages/synapse/storage/database.py", line 469, in _do_execute
    return func(sql, *args, **kwargs)
sqlite3.IntegrityError: UNIQUE constraint failed: temp_user_filters.user_id


Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.