TEXT 1
Matrix By manuel on 24th October 2024 11:34:41 PM
  1. 1. dns einrichten, zb. matrix.dein.server
  2. 2. portfreischaltung 8448 auf reverse proxy geben (braucht er für federated zeugs)
  3. 3. debian 12 lxc erstellen (8gb disk, 2gb ram)
  4. 4. auf debian ausführen:
  5.  
  6. cd /tmp
  7. wget https://github.com/girlbossceo/conduwuit/releases/download/v0.4.6/x86_64-unknown-linux-musl-debug.deb
  8. apt install -f /tmp/x86_64-unknown-linux-musl-debug.deb
  9. nano /etc/conduwuit/conduwuit.toml
  10.  
  11. folgende config einfügen: https://pastebin.kmpr.at//paste.php?id=3f3fd9aa-924f-11ef-aaf9-3a303f3fd287
  12.  
  13. systemctl enable conduwuit
  14. systemctl start conduwuit
  15.  
  16. 5. nginx reverse proxy beispiel:
  17. server {
  18.         server_name matrix.dein.server;
  19.         listen 80;
  20.         return 301 https://$host$request_uri;
  21. }
  22.  
  23. server {
  24.         listen 443 ssl;
  25.         listen 8448 ssl;
  26.         server_name matrix.dein.server;
  27.  
  28.         include snippets/geoblock.conf;
  29.         include snippets/ssl.conf;
  30.  
  31.         proxy_read_timeout 720s;
  32.         proxy_connect_timeout 720s;
  33.         proxy_send_timeout 720s;
  34.  
  35.         client_max_body_size 15m;
  36.         keepalive_timeout 15;
  37.  
  38.         access_log /var/log/nginx/matrix_ssl.access.log;
  39.         error_log  /var/log/nginx/matrix_ssl.error.log;
  40.  
  41.     location /.well-known/matrix/server {
  42.         return 200 '{"m.server": "matrix.dein.server:443"}';
  43.         types { } default_type "application/json; charset=utf-8";
  44.     }
  45.  
  46.     location /.well-known/matrix/client {
  47.         return 200 '{"m.homeserver": {"base_url": "https://matrix.dein.server"}}';
  48.         types { } default_type "application/json; charset=utf-8";
  49.         add_header "Access-Control-Allow-Origin" *;
  50.     }
  51.  
  52.     location /.well-known {
  53.         root /home/matrix/public/;
  54.     }
  55.  
  56.     location ~* ^(\/_matrix|\/_synapse\/client|\/_conduwuit) {
  57.         proxy_pass http://srv-matrix.local:6167;
  58.         add_header 'Access-Control-Allow-Methods' 'GET, POST, PUT, DELETE, OPTIONS, PATCH, HEAD';
  59.         proxy_set_header X-Forwarded-For $remote_addr;
  60.         proxy_buffering off;
  61.         proxy_set_header Host $host;
  62.     }
  63. }
  64.  
  65. in der doku steht auch was von caddy:
  66. Create /etc/caddy/conf.d/conduwuit_caddyfile and enter this (substitute for your server name).
  67.  
  68. your.server.name, your.server.name:8448 {
  69.     # TCP reverse_proxy
  70.     127.0.0.1:6167
  71.     # UNIX socket
  72.     #reverse_proxy unix//run/conduwuit/conduwuit.sock
  73. }
  74. That's it! Just start and enable the service and you're set.
  75.  
  76.  
  77. sudo systemctl enable --now caddy

pastebin.kmpr.at ist f;r Quelltexte und generellen Debugging Text.

Login oder Registrieren um zu bearbeiten, löschen, um deine Pastes zu verfolgen und mehr.

Raw Paste

Login oder Registrieren um diesen Paste zu bearbeiten oder zu forken. Es ist kostenlos.