Notes:
Configuring Synapse:
matrix ~ # /usr/local/bin/python3.7 -B -m synapse.app.homeserver -c /usr/local/etc/matrix-synapse/homeserver.yaml --generate-config -H matrix.ahlawat.com --report-stats no
Generating config file /usr/local/etc/matrix-synapse/homeserver.yaml
Generating log config file /usr/local/etc/matrix-synapse/matrix.ahlawat.com.log.config which will log to /root/homeserver.log
Generating signing key file /usr/local/etc/matrix-synapse/matrix.ahlawat.com.signing.key
A config file has been generated in '/usr/local/etc/matrix-synapse/homeserver.yaml' for server name 'matrix.ahlawat.com'. Please review this file and customise it to your needs.
matrix ~ #
Please note that you will still need to manually configure paths to log directory, database, and media storage with this method.
matrix ~ # register_new_matrix_user -c homeserver.yaml http://localhost:8008
Open ports on pfSense
${fwcmd} add pass tcp from any to me 8448 setup # MATRIX
Open ports on pfSense to TURN on proxy jail
${fwcmd} add pass tcp from any to me 3478 setup # TURN
${fwcmd} add pass udp from any to me 3478 keep-state # TURN
${fwcmd} add pass tcp from any to me 5349 setup # TURN TLS
${fwcmd} add pass udp from any to me 5349 keep-state # TURN TLS
on web jail:
mkdir -p /usr/local/www/apache24/data/.well-known/matrix
echo '{ "m.server": "matrix.ahlawat.com:8448" }' > /usr/local/www/apache24/data/.well-known/matrix/server
on dns jail:
add SRV record to ahlawat.com.db file
_matrix._tcp.ahlawat.com. 300 IN SRV 10 5 8448 matrix.ahlawat.com.