aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/mod_posix.lua
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/mod_posix.lua')
-rw-r--r--plugins/mod_posix.lua20
1 files changed, 5 insertions, 15 deletions
diff --git a/plugins/mod_posix.lua b/plugins/mod_posix.lua
index fe826c22..5177aaa5 100644
--- a/plugins/mod_posix.lua
+++ b/plugins/mod_posix.lua
@@ -20,7 +20,6 @@ if not have_signal then
module:log("warn", "Couldn't load signal library, won't respond to SIGTERM");
end
-local format = require "util.format".format;
local lfs = require "lfs";
local stat = lfs.attributes;
@@ -113,24 +112,15 @@ local function write_pidfile()
end
end
-local syslog_opened;
-function syslog_sink_maker(config) -- luacheck: ignore 212/config
- if not syslog_opened then
- pposix.syslog_open("prosody", module:get_option_string("syslog_facility"));
- syslog_opened = true;
- end
- local syslog = pposix.syslog_log;
- return function (name, level, message, ...)
- syslog(level, name, format(message, ...));
- end;
-end
-require "core.loggingmanager".register_sink_type("syslog", syslog_sink_maker);
-
local daemonize = prosody.opts.daemonize;
if daemonize == nil then
-- Fall back to config file if not specified on command-line
- daemonize = module:get_option("daemonize", prosody.installed);
+ daemonize = module:get_option_boolean("daemonize", nil);
+ if daemonize ~= nil then
+ module:log("warn", "The 'daemonize' option has been deprecated, specify -D or -F on the command line instead.");
+ -- TODO: Write some docs and include a link in the warning.
+ end
end
local function remove_log_sinks()