Error with client strophejs

0

Ejabberd.yml version 18.03

Port:

port: 5280
ip: "::"
module: ejabberd_http
request_handlers:
  "/ws": ejabberd_http_ws
  "/bosh": mod_bosh
  "/oauth": ejabberd_oauth
  "/api": mod_http_api
##  "/pub/archive": mod_http_fileserver
web_admin: true
## register: true
## captcha: false

Module: (the http-bind module in this version is missing)

mod_bosh: {}

strophejs:

var BOSH_SERVICE = 'http://localhost/xmmp-httpbind';

apache httpd.conf:

ProxyRequests Off

<Proxy *>

  Order deny,allow

  Deny from all

  Allow from all

</Proxy>

ProxyPass /xmpp-httpbind http://localhost:5280/bosh/

ProxyPassReverse /xmpp-httpbind http://localhost:5280/bosh/

configuration of the hosts file:

# localhost name resolution is handled within DNS itself.
    127.0.0.1   localhost
    ::1 localhost

Error by console:

  

Failed to load link : Response to preflight   request does not pass access control check: No   'Access-Control-Allow-Origin' header is present on the requested   resource. Origin ' link ' is therefore not allowed   access.

    
asked by wao 27.04.2018 в 20:30
source

1 answer

0

You have to add http-bind: true and restart the server and change / bosh / by / http-bind / in the proxy and add mod_http_bind {} after mod_bosh

    
answered by 17.05.2018 в 19:59