aboutsummaryrefslogtreecommitdiffstats
path: root/prosodyctl
diff options
context:
space:
mode:
authorMatthew Wild <mwild1@gmail.com>2010-12-20 14:06:16 +0000
committerMatthew Wild <mwild1@gmail.com>2010-12-20 14:06:16 +0000
commit6d96edf726384aa2ce4fd0f5479cf98a39c3b1ef (patch)
tree090958a816087d3440ddd124b5efb83d292a6cd7 /prosodyctl
parente626770ceb54e4526ca2fec6aa59e63ca2cfd27f (diff)
downloadprosody-6d96edf726384aa2ce4fd0f5479cf98a39c3b1ef.tar.gz
prosody-6d96edf726384aa2ce4fd0f5479cf98a39c3b1ef.zip
prosody, prosodyctl, util.dependencies: Split checking and logging of dependencies so we can check hard deps before the config and logging is loaded
Diffstat (limited to 'prosodyctl')
-rwxr-xr-xprosodyctl9
1 files changed, 6 insertions, 3 deletions
diff --git a/prosodyctl b/prosodyctl
index cfc5ca77..9630a9b8 100755
--- a/prosodyctl
+++ b/prosodyctl
@@ -41,6 +41,11 @@ prosody = {
};
local prosody = prosody;
+local dependencies = require "util.dependencies";
+if not dependencies.check_dependencies() then
+ os.exit(1);
+end
+
config = require "core.configmanager"
do
@@ -94,9 +99,7 @@ config.set("*", "core", "log", { { levels = { min="info" }, to = "console" } });
require "core.loggingmanager"
-if not require "util.dependencies".check_dependencies() then
- os.exit(1);
-end
+dependencies.log_warnings();
local data_path = config.get("*", "core", "data_path") or CFG_DATADIR or "data";
require "util.datamanager".set_data_path(data_path);