-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Option to configure WS/BOSH URL directly? #7
Comments
Hello.
However, you may experience CORS issues if XMPP listener and chat app are not on the same domain. Keep me informed if it works as you expected 🙂 |
Yes, I tested it with a totally different domain and it seems to work fine in Firefox. My WSS/BOSH is running on ejabberd with a traefik.io reverseproxy. Thanks for the confirmation. Would be still nice if there was a way to configure this in the login screen (advanced settings?) and if |
I take a quick look, this XEP is not in Stanza supported XEPs. |
That would still leave it to the server admin to configure the URL, no? The main idea is that there would be a default WS/BOSH URL, but if people want to connect with another XMPP server they could configure (or XEP-156 does it automatically) it themselves before login. |
That is the purpose of auto-discovery as described in the XEP 😄 |
Yeah, that would certainly work. Thanks for considering it! |
Even if not implemented in Stanza, it's just a DNS lookup and/or a HTTP request to a .well-known URL for the JID domain which can be pulled from Stanza. Would attempting to pull _xmppconnect.jid-domain.org and populating the bosh/ws values that way be a problem? I'm just starting to look around the code here, and I'll take a shot at it unless you think there's some good reason that it wouldn't be straightforward. Do you have a MUC to discuss this project? I'm happy to maintain something on chinwag.im for it if you don't have a preferred server. |
Hello, I just added the two functionalities:
|
@bremensaki Thanks for proposition 😃 |
Awesome, thanks a lot for adding this. Is "xmpp-websocket" the default for Prosody? In ejabberd the defaults are "/ws" and "/bosh" which are arguably the more common defaults with non-selfhosted servers. |
Yes, Prosody defaults are xmpp-websocket and http-bind for BOSH. It looks a bit clunky I agree, but it's easily changed and it's not usually something end users have to see and deal with anyway. I usually just reverse proxy everything from nginx anyway, and use /ws and /bosh there just because it's easier to type. |
Would be great if there was a way to configure the websocket or BOSH URL directly and not depend on the Apache2 proxy.
Both for running it on a shared server that doesn't allow modification of the Apache2 config and for use as a stand alone HTML5 app.
Thanks :)
Edit: or is it sufficient to modify the local.js?
Would be still nice to be able to configure it as a parameter.
The text was updated successfully, but these errors were encountered: