Add missing CORS headers to host-meta.json

Otherwise XMPP Web clients cannot fetch the Bosh and WS endpoint info
This commit is contained in:
Râu Cao 2025-04-08 00:10:29 +04:00
parent 6c35a20b89
commit 10e8ba5569
Signed by: raucao
GPG Key ID: 37036C356E56CC51

View File

@ -29,11 +29,15 @@ server {
ssl_certificate <%= @ssl_cert %>;
ssl_certificate_key <%= @ssl_key %>;
location /.well-known/host-meta.json {
add_header 'Access-Control-Allow-Origin' '*';
}
<% if @accounts_url %>
location ~ ^/.well-known/(keysend|lnurlp|nostr|openpgpkey|webfinger) {
proxy_ssl_server_name on;
proxy_set_header X-Forwarded-Host $host;
proxy_pass https://accounts.kosmos.org;
proxy_pass <%= @accounts_url %>;
}
<% end %>
}