Search code examples
ubuntuamazon-ec2xmppejabberd

AWS Ubuntu: Configure Ejabberd Hosts from Snap Store


I installed Ejabberd from Snap Store on Ubuntu, on an AWS EC2. I can access admin webpage "localhost:5280/admin" locally on Ubuntu. However, I cannot access it outside VNC from "https://ec2-xx-xxx-xx-xxx.compute-1.amazonaws.com:5280/admin". I guess I need to add "ec2-xx-xxx-xx-xxx.compute-1.amazonaws.com" into hosts in ejabberd.yml according to some tutorials. But it is quite different for Ejabberd installed from Snap, as I see there are two ejabberd.xml, not sure which one I shall change.

root@ip-xxx-xx-xx-xxx:/home/ubuntu# ls /snap/ejabberd/37/config/
config.exs  ejabberd.exs  ejabberd.yml
root@ip-xxx-xx-xx-xxx:/home/ubuntu# ls /snap/ejabberd/current/config/
config.exs  ejabberd.exs  ejabberd.yml
root@ip-xxx-xx-xx-xxx:/home/ubuntu# 

When I open file ejabberd.yml, I find it is readonly with an "equal mark" as picture shown. I am not sure whether I shall use chmod to modify read-write? Or there are other ways to add my aws ip-address to the hosts in config?


Solution

  • The correct yaml file for Ejabberd from Snap Store is /var/snap/ejabberd/37/etc/ejabberd.yml or /var/snap/ejabberd/current/etc/ejabberd.yml, which are the same file. And /snap/ejabberd/37/config/ is pointing to the above files