Matrix

Matrix

Docker app from junkerderprovinz Repository

Overview

All-in-one Matrix homeserver for Unraid: Synapse + coturn + Element Web (/element/) + Synapse-Admin (/admin/). Plug-and-play — just fill in SERVER_NAME and Postgres connection, everything else is generated automatically. PREREQUISITES (before starting the container): 1) PostgreSQL database — connect to your Postgres container and run: CREATE USER matrix WITH PASSWORD 'yourpass'; CREATE DATABASE matrix ENCODING 'UTF8' LC_COLLATE='C' LC_CTYPE='C' TEMPLATE template0 OWNER matrix; (UTF8 + LC_COLLATE='C' is mandatory — Synapse will refuse to start otherwise.) 2) Reverse proxy (Nginx Proxy Manager) for matrix.yourdomain.tld → Unraid-IP:8008. In the proxy host → Advanced tab, add: client_max_body_size 100m; proxy_read_timeout 600s; (Without these, media uploads fail and long-running requests time out.) 3) For federation: two extra Custom Locations on the SAME proxy host for /.well-known/matrix/server and /.well-known/matrix/client → Unraid-IP:8080. Full step-by-step guide (NPM screenshots, well-known, first user): https://github.com/junkerderprovinz/matrix#readme

Requirements

PostgreSQL container with a database: ENCODING UTF8, LC_COLLATE=C, LC_CTYPE=C

Runtime arguments

Web UI
http://[IP]:[PORT:8080]/element/
Network
bridge
Shell
sh
Privileged
false

Template configuration

Matrix HTTP APIPorttcp

Synapse HTTP API. Expose via reverse proxy with HTTPS — never directly to the internet.

Target
8008
Default
8008
Value
8008
Element Web + Synapse-AdminPorttcp

Serves Element Web (/element/), Synapse-Admin (/admin/) and /.well-known/matrix/* endpoints.

Target
8080
Default
8080
Value
8080
TURN TCPPorttcp

TURN/STUN over TCP for voice/video calls. Open this port in your router/firewall.

Target
3478
Default
3478
Value
3478
TURN UDPPortudp

TURN/STUN over UDP for voice/video calls. Open this port in your router/firewall.

Target
3478
Default
3478
Value
3478
TURN TLS TCPPorttcp

TURN over TLS (TCP). Optional — only if TLS certs are mounted.

Target
5349
Default
5349
Value
5349
TURN TLS UDPPortudp

TURN over TLS (UDP). Optional — only if TLS certs are mounted.

Target
5349
Default
5349
Value
5349
Prometheus MetricsPorttcp

Prometheus metrics at /_synapse/metrics. Bind to a private network only.

Target
9090
Default
9090
Value
9090
Data DirectoryPath

Persistent data: homeserver.yaml, media, signing keys. Never delete — destroys keys and breaks federation.

Target
/data
Default
/mnt/user/appdata/matrix/
Value
/mnt/user/appdata/matrix/
TURN-TLS CertsPathro

Optional. Mount a folder containing fullchain.pem + privkey.pem to enable TURN-TLS on 5349.

Target
/data/certs
Matrix Server DomainVariable

Your Matrix domain, e.g. matrix.yourdomain.tld. Used in Matrix IDs (@user:matrix.yourdomain.tld). Cannot be changed later without wiping the DB.

Target
SERVER_NAME
Value
matrix.yourdomain.tld
Anonymous Usage ReportingVariable

Send anonymous usage stats to Matrix.org. 'yes' or 'no'. Recommended: no.

Target
REPORT_STATS
Default
no
Value
no
Enable FederationVariable

true = chat with the public Matrix network (requires /.well-known/matrix/* on your proxy, see README). false = private island.

Target
ENABLE_FEDERATION
Default
true
Value
true
PostgreSQL HostVariable

IP of your PostgreSQL server (e.g. Unraid host IP). IP+port is more reliable than container names.

Target
POSTGRES_HOST
Default
192.168.x.x
Value
192.168.x.x
PostgreSQL PortVariable

PostgreSQL port. Default 5432.

Target
POSTGRES_PORT
Default
5432
Value
5432
PostgreSQL UsernameVariable

Postgres user for Synapse. Must already exist (see README — Postgres setup).

Target
POSTGRES_USER
Default
admin
Value
admin
PostgreSQL PasswordVariable

Password for the Postgres user above.

Target
POSTGRES_PASSWORD
PostgreSQL DatabaseVariable

Synapse database name. Must be created with ENCODING UTF8, LC_COLLATE='C', LC_CTYPE='C' — see Overview.

Target
POSTGRES_DB
Default
matrix
Value
matrix
Matrix Admin Username (Element / Synapse-Admin login)Variable

Optional. Localpart of the admin user to auto-create on first boot (e.g. 'admin' → @admin:SERVER_NAME). Logs into Element Web + Synapse-Admin. Clear after creation.

Target
ADMIN_USER
Matrix Admin Password (Element / Synapse-Admin login)Variable

Optional. Password for the admin user above. Clear after first boot.

Target
ADMIN_PASSWORD
TimezoneVariable

Container timezone (affects log timestamps).

Target
TZ
Default
Europe/Vienna
Value
Europe/Vienna
User ID (PUID)Variable

UID Synapse runs as. Default 99 (nobody on Unraid).

Target
PUID
Default
99
Value
99
Group ID (PGID)Variable

GID Synapse runs as. Default 100 (users on Unraid).

Target
PGID
Default
100
Value
100

Details

Repository
ghcr.io/junkerderprovinz/matrix:latest
Last Updated2026-05-31
First Seen2026-05-13

Run Matrix on Unraid.

Matrix is listed in Community Apps for Unraid OS. Explore Unraid to build a flexible home server, NAS, or homelab.