diff options
author | Badlop <badlop@process-one.net> | 2022-01-17 11:49:16 +0100 |
---|---|---|
committer | Badlop <badlop@process-one.net> | 2022-02-03 18:21:47 +0100 |
commit | adbccbe852e3d9980e531ff206bebd6b2c983fba (patch) | |
tree | 04d4b8ae5447fc1f41e87d1f152fd79b70b8e855 /src | |
parent | mod_pubsub: Unsubscribe JID on whitelist removal (diff) |
New "make relive" similar to "ejabberdctl live" without installing
Prepare with:
./autogen.sh && ./configure --with-rebar=./rebar3 && make
Or use this if you installed Elixir:
./autogen.sh && ./configure --with-rebar=mix && make
Start without installing (it recompiles when necessary):
make relive
It stores config, database and logs in _build/relive/
There's available the well-known script:
_build/relive/ejabberdctl
Please note this fails immediately:
r3:do(compile).
This crashes a few seconds later:
rebar3:run(["compile"]).
Workaround that works correctly:
ejabberd_admin:update().
Diffstat (limited to 'src')
-rw-r--r-- | src/ejabberd_admin.erl | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/ejabberd_admin.erl b/src/ejabberd_admin.erl index 9e72c7b36..cbf372654 100644 --- a/src/ejabberd_admin.erl +++ b/src/ejabberd_admin.erl @@ -40,7 +40,7 @@ %% Cluster join_cluster/1, leave_cluster/1, list_cluster/0, %% Erlang - update_list/0, update/1, + update_list/0, update/1, update/0, %% Accounts register/3, unregister/2, registered_users/1, @@ -540,6 +540,15 @@ update_module(ModuleNameString) -> {error, Reason} -> {error, Reason} end. +update() -> + io:format("Compiling ejabberd...~n", []), + os:cmd("make"), + Mods = ejabberd_admin:update_list(), + io:format("Updating modules: ~p~n", [Mods]), + ejabberd_admin:update("all"), + io:format("Updated modules: ", []), + Mods -- ejabberd_admin:update_list(). + %%% %%% Account management %%% |