Cannot start new installation - erlang cookie not in correct location

I'm trying to build a new installation on a new Ubuntu server (17.04), with ejabberd 17.07.
I created a user for the service "useradd -r ejabberd".

I ran the binary installer with "sudo -u ejabberd ./ejabberd-17.07-linux-x86_64-installer.run"

But I cannot start the service. I tried "sudo -u ejabberd ./ejabberdctl start" and get this:
Failed to create cookie file /home/phil/.erlang.cookie

Obviously it is running under the wrong user context, but for 10 hours now I have not been able to straighten this out.

It is a completely fresh install of Ubuntu with nothing else on it.

Syndicate content