rroemhild / docker-ejabberd

Dockerfile for Ejabberd server
MIT License
267 stars 161 forks source link

When installing modules, they should be copied to ejabberdctl module folder #109

Open hhravn opened 7 years ago

hhravn commented 7 years ago

@who i'm just trying to understand the mechanism that loads modules from the "outside", and i see that you did the original pull request, so here goes;

https://github.com/rroemhild/docker-ejabberd/blob/master/scripts/post/11_ejabberd_install_modules.sh#L14

Shouldn't the script that installs "sideloaded" modules copy them to ejabberdctl's $CONTRIB_MODULES_PATH, rather than

${EJABBERD_HOME}/.ejabberd-modules/sources/${module_name}

Furthermore, i'm not sure ${module_name} should be a part of the path. When i do

docker run -v ./ejabberd/module_source/:/opt/ejabberd/module_source/ ...

where the source contains a module, mod_offline_push, the structure will end up as

${EJABBERD_HOME}/.ejabberd-modules/sources/mod_offline_push/mod_offline_push

and the installation will fail miserably;

ejabberd_1  | Error: [{missing,"mod_offline_push.spec"},
ejabberd_1  |         {missing,"COPYING"},
ejabberd_1  |         {missing,"README.txt"},
ejabberd_1  |         {missing,"src (Erlang) or lib (Elixir) sources directory"},
ejabberd_1  |         {invalid_spec,"no such file or directory"}]
rroemhild commented 7 years ago

Hi, i merged #116. Does this merge fix your issue?

ghost commented 7 years ago

@hhravn Did @rroemhild's change fix the issue for you?

claudiocleberson commented 7 years ago

Hi there,

I am having a bit of a problem to add a module! for some reason when I try to build the container I get that log below, via docker-compose

EJABBERD_SOURCE_MODULES=mod_offline_http_post

ejabberd_1 | Updating module specs... ok ejabberd_1 | Analyzing module mod_offline_http_post for installation ejabberd_1 | Copying module to ejabberd folder /opt/ejabberd/.ejabberd-modules/sources ejabberd_1 | Running module_check on mod_offline_http_post ejabberd_1 | Error: not_available

Ejabberd 17.04