diff --git a/etc/caddy/conf.d/telepath.caddy b/etc/caddy/conf.d/telepath.caddy old mode 100755 new mode 100644 index 2c5cd9c..4f139c4 --- a/etc/caddy/conf.d/telepath.caddy +++ b/etc/caddy/conf.d/telepath.caddy @@ -19,11 +19,11 @@ telepath.im www.telepath.im { respond /.well-known/host-meta.json 200 { body `{"links":[{"rel":"urn:xmpp:alt-connections:xbosh","href":"https://hypertext.telepath.im/http-bind"},{"rel":"urn:xmpp:alt-connections:websocket/","href":"wss://hypertext.telepath.im/xmpp-websocket/"}]}` } +} - reverse_proxy /join/invite* localhost:5280 - reverse_proxy /join/register* localhost:5280 - reverse_proxy /share* localhost:5280 - reverse_proxy /register_apps* localhost:5280 +# XMPP HTTP stuff +xmpp.telepath.im { + reverse_proxy localhost:5280 } # XMPP HTTP file upload service diff --git a/etc/prosody/prosody.cfg.lua b/etc/prosody/prosody.cfg.lua index 127c299..c22c929 100644 --- a/etc/prosody/prosody.cfg.lua +++ b/etc/prosody/prosody.cfg.lua @@ -79,7 +79,7 @@ modules_enabled = { "block_registrations"; "invites_register_web"; "invites_page"; - "http_libjs" + "http_libjs"; } -- These modules are auto-loaded, but should you want @@ -226,11 +226,28 @@ block_registrations_users = { "ethereal", "telepath", "telepath.im", "fsky", "fs groups_file = "/etc/prosody/groups.ini" --- HTTP stuff idk +-- HTTP server +-- See https://prosody.im/doc/http +http_host = "xmpp.telepath.im" +http_external_url = "https://xmpp.telepath.im/" trusted_proxies = { "127.0.0.1", "::1" } +http_paths = { + invites_page = "/join/$host/invite"; + invites_register_web = "/join/$host/register"; +} + +-- BOSH +-- See https://prosody.im/doc/setting_up_bosh + consider_bosh_secure = true +-- Invite and registration page +-- See https://modules.prosody.im/mod_invites.html + +invites_page = "https://xmpp.telepath.im/join/{host}/invite?{invite.token}" + + expose_publisher = true ----------- Virtual hosts ----------- @@ -239,16 +256,6 @@ expose_publisher = true VirtualHost "telepath.im" --- Invites --- See https://modules.prosody.im/mod_invites.html - -invites_page = "https://telepath.im/join/invite?{invite.token}" -http_external_url = "https://telepath.im/" -http_paths = { - invites_page = "/join/invite"; - invites_register_web = "/join/register"; -} - ------ Components ------ -- See https://prosody.im/doc/components @@ -279,6 +286,7 @@ name = "Hypertext (HTTP file share)" http_file_share_size_limit = 100*1024*1024 -- 100 MiB http_file_share_global_quota = 200*1024*1024*1024 -- 200 GiB http_file_share_expires_after = 30*86400 -- 1 month +http_host = "hypertext.telepath.im" http_external_url = "https://hypertext.telepath.im/" -- Beacon (publish-subscribe) @@ -293,6 +301,7 @@ expose_publisher = true Component "relayer.telepath.im" "proxy65" name = "Relayer (SOCKS5 bytestreams)" + -- External components -- See https://prosody.im/doc/components#adding_an_external_component