From 82ca2f393bef2895ef09df70beac455bc28e4c45 Mon Sep 17 00:00:00 2001 From: Matthew Wild Date: Sun, 10 Jan 2010 23:11:28 +0000 Subject: prosodyctl: Move definition of prosody singleton to prior to loading datamanager, and add platform --- prosodyctl | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'prosodyctl') diff --git a/prosodyctl b/prosodyctl index fd9bbe2f..407b10d4 100755 --- a/prosodyctl +++ b/prosodyctl @@ -60,6 +60,8 @@ do end end +prosody = { hosts = {}, events = events, platform = "posix" }; + local data_path = config.get("*", "core", "data_path") or CFG_DATADIR or "data"; require "util.datamanager".set_data_path(data_path); @@ -111,8 +113,7 @@ local error_messages = setmetatable({ local events = require "util.events".new(); -hosts = {}; -prosody = { hosts = hosts, events = events }; +hosts = prosody.hosts; for hostname, config in pairs(config.getconfig()) do hosts[hostname] = { events = events }; -- cgit v1.2.3