Unable to recognize the installed custom module? #4155
-
OS: ejabberd version : 23.10 install step: wget https://github.com/processone/ejabberd/releases/download/23.10/ejabberd-23.10-1-linux-x64.run I have followed the official documentation for the operation , but it seems unable to find the module.. code : -module(mod_hello_world).
-behaviour(gen_mod).
%% Required by ?INFO_MSG macros
-include("logger.hrl").
%% Required by ?T macro
-include("translate.hrl").
%% gen_mod API callbacks
-export([start/2, stop/1, depends/2, mod_options/1, mod_doc/0]).
start(_Host, _Opts) ->
?INFO_MSG("Hello, ejabberd world!", []),
ok.
stop(_Host) ->
?INFO_MSG("Bye bye, ejabberd world!", []),
ok.
depends(_Host, _Opts) ->
[].
mod_options(_Host) ->
[].
mod_doc() ->
#{desc =>
?T("This is an example module.")}. my step : |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
you've read https://github.com/processone/ejabberd-contrib/#ejabberd-contrib ? |
Beta Was this translation helpful? Give feedback.
-
Is ejabberd running under your user account? Maybe Does ejabberd store and read modules from that path? Or maybe ejabberd is using a different path? One method to know the path that ejabberd is using for those modules:
Another method is to run |
Beta Was this translation helpful? Give feedback.
Is ejabberd running under your user account? Maybe
$HOME
of the ejabberd program is not your personal$HOME
.Does ejabberd store and read modules from that path? Or maybe ejabberd is using a different path?
One method to know the path that ejabberd is using for those modules:
Another method is to run
ejabberdctl modules_update_specs
, and search in the$HOME
of the user that runs ejabberd the directory .ejabberd-modules
.