Matrix Docker Ansible eploy
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

42 lines
912 B

  1. server {
  2. listen 80;
  3. server_name {{ hostname_matrix }};
  4. server_tokens off;
  5. location /.well-known/acme-challenge {
  6. default_type "text/plain";
  7. alias /acmetool-certs/run/acme-challenge;
  8. }
  9. location / {
  10. return 301 https://$http_host$request_uri;
  11. }
  12. }
  13. server {
  14. listen 443 ssl http2;
  15. listen [::]:443 ssl http2;
  16. server_name {{ hostname_matrix }};
  17. server_tokens off;
  18. root /dev/null;
  19. ssl on;
  20. ssl_certificate /acmetool-certs/live/{{ hostname_matrix }}/fullchain;
  21. ssl_certificate_key /acmetool-certs/live/{{ hostname_matrix }}/privkey;
  22. ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
  23. ssl_prefer_server_ciphers on;
  24. ssl_ciphers "EECDH+AESGCM:EDH+AESGCM:AES256+EECDH:AES256+EDH";
  25. location /_matrix {
  26. proxy_pass http://synapse:8008;
  27. proxy_set_header X-Forwarded-For $remote_addr;
  28. client_body_buffer_size 25M;
  29. client_max_body_size {{ matrix_max_upload_size_mb }}M;
  30. proxy_max_temp_file_size 0;
  31. }
  32. }