diff --git a/privfrontends/templates/in/apps.Caddyfile b/privfrontends/templates/in/apps.Caddyfile index 922c453..95741a1 100644 --- a/privfrontends/templates/in/apps.Caddyfile +++ b/privfrontends/templates/in/apps.Caddyfile @@ -6,50 +6,6 @@ cinny.projectsegfau.lt cy.psf.lt { import def } -# Website -projectsegfau.lt { - reverse_proxy :1337 - import def - reverse_proxy /_matrix/* :8456 - reverse_proxy /.well-known/acme-challenge/* :5380 - reverse_proxy /bosh :5443 { - header_up X-Real-IP {remote_host} - transport http { - tls_insecure_skip_verify - } - } - reverse_proxy /ws :5443 { - header_up X-Real-IP {remote_host} - transport http { - tls_insecure_skip_verify - } - } - header /.well-known/matrix/* Content-Type application/json - header /.well-known/matrix/* Access-Control-Allow-Origin * - handle_path /.well-known/* { - root * /var/www/well-known - file_server - } - header /.well-known/host-meta Content-Type application/xrd+xml - header /.well-known/host-meta Access-Control-Allow-Origin * - header /.well-known/host-meta.json Content-Type application/json - header /.well-known/host-meta.json Access-Control-Allow-Origin * - header /.well-known/xmpp-provider-v2.json Content-Type application/json - header /.well-known/xmpp-provider-v2.json Access-Control-Allow-Origin * - import torloc www -} -psf.lt { - reverse_proxy :1337 - import def - import torloc www - header /.well-known/matrix/* Content-Type application/json - header /.well-known/matrix/* Access-Control-Allow-Origin * - handle_path /.well-known/* { - root * /var/www/psf-well-known - file_server - } -} - mtx.psf.lt { reverse_proxy :8466 import def @@ -72,12 +28,6 @@ matrix.projectsegfau.lt { handle_path / { redir https://wiki.projectsegfau.lt/Matrix } - @hasSlashes path_regexp expression \/_matrix\/media\/(v3|v1|r0)\/(download|thumbnail)\/projectsegfau.lt\/([a-zA-Z]{2})([a-zA-Z]{2})([a-zA-z]+) - rewrite @hasSlashes /mediawork/{re.expression.3}/{re.expression.4}/{re.expression.5} - handle_path /mediawork/* { - root * /mnt/matrix/synapse/storage/media-store/local_content - file_server - } } # Element @@ -176,7 +126,18 @@ xmpp.projectsegfau.lt, conference.projectsegfau.lt, proxy.projectsegfau.lt, pubs tls_insecure_skip_verify } } - reverse_proxy /.well-known/acme-challenge/* :5380 + reverse_proxy /bosh :5443 { + header_up X-Real-IP {remote_host} + transport http { + tls_insecure_skip_verify + } + } + reverse_proxy /ws :5443 { + header_up X-Real-IP {remote_host} + transport http { + tls_insecure_skip_verify + } + } @register { path /new/ path /change_password/