I am running ejabberd version 21.04 from docker in windows 10 whenever I try to use web admin while pressing the button in docker desktop the browser gives me an error saying localhost didn’t send any data. ERR_EMPTY_RESPONSE I use chrome as the web browser I followed this tutorial https://hub.docker.com/r/ejabberd/ecs they are starting ejabberd container on port 5222, but when I run web admin it says invalid http response, for port 5222 and when I run on port 8000 it says err empty response from server
to check log I used docker exec -it ejabberd tail -f logs/ejabberd.log
2021-04-27 10:43:15.196032+00:00 [debug] <0.43.0>@application_controller:info_started/2:1929 PROGRESS REPORT:
application: runtime_tools
started_at: ejabberd@73fe5729d7a6
2021-04-27 10:43:15.196319+00:00 [debug] <0.43.0>@application_controller:info_started/2:1929 PROGRESS REPORT:
application: artificery
started_at: ejabberd@73fe5729d7a6
2021-04-27 10:43:15.196575+00:00 [debug] <0.43.0>@application_controller:info_started/2:1929 PROGRESS REPORT:
application: distillery
started_at: ejabberd@73fe5729d7a6
2021-04-27 10:43:16.037858+00:00 [debug] <0.651.0>@ejabberd:check_apps/0:139 All applications are intact
what should I do ? do I have to change config file thank you
1条答案
按热度按时间goucqfw61#
When clicking on the "Open in Browser" icon in Docker Desktop, it will open using the lowest port number, see https://github.com/docker/for-win/issues/9537
So, if you expose 5222 for C2S and 5280 for web admin, Docker Desktop opens the url http://localhost:5222 Am I right? That obviously will cause a problem!!! And you should have noticed that the port opened in the webbrowser is wrong!!!
Instead of installing the image and creating the container manually and then complaining, I followed this cool tutorial that bypasses that problem by performing all the actions automatically, and it sets 5180 for webadmin (instead of 5280), so Web Admin works correctly:
https://www.process-one.net/blog/install-ejabberd-on-windows-10-using-docker-desktop/