Kim Alvefur <zash@zash.se> [Sun, 24 Mar 2024 21:31:47 +0100] rev 13467
util.startup: Don't use not yet existent shutdown procedure when started as root (thanks SigmaTel71)
Kim Alvefur <zash@zash.se> [Sun, 24 Mar 2024 20:39:42 +0100] rev 13466
util.startup: Check root after detecting platform and reading config (thanks SigmaTel71)
Ensures that startup.detect_platform() runs so know whether to use the
POSIX method of checking the current user or something else. Also after
reading the config so we know whether the root override setting is set.
Kim Alvefur <zash@zash.se> [Sat, 23 Mar 2024 20:48:19 +0100] rev 13465
mod_posix: Move everything to util.startup
This allows greater control over the order of events.
Notably, the internal ordering between daemonization, initialization of
libunbound and setup of signal handling is sensitive.
libunbound starts a separate thread for processing DNS requests.
If this thread is started before signal handling has been set up, it
will not inherit the signal handlers and instead behave as it would have
before signal handlers were set up, i.e. cause the whole process to
immediately exit.
libunbound is usually initialized on the first DNS request, usually
triggered by an outgoing s2s connection attempt.
If daemonization happens before signals have been set up, signals may
not be processed at all.
Matthew Wild <mwild1@gmail.com> [Sun, 17 Mar 2024 10:10:24 +0000] rev 13464
mod_bosh: Set base_type on session
This fixes a traceback with mod_saslauth. Ideally we move this to util.session
at some point, though.
Kim Alvefur <zash@zash.se> [Sun, 10 Mar 2024 15:56:01 +0100] rev 13463
util.startup: Back out 598df17b8ebb
Broke signal handling again, such that an early s2s connection results
in libunbound catching signals and getting Prosody killed on e.g. SIGHUP
This returns to the situation where prosody --daemonize does not respond
to signals.
Kim Alvefur <zash@zash.se> [Wed, 06 Mar 2024 20:43:25 +0100] rev 13462
util.startup: Hook signals after daemonization
signalfds stop working with epoll after forking
hooking signals later should not affect anything
Kim Alvefur <zash@zash.se> [Wed, 06 Mar 2024 19:12:11 +0100] rev 13461
mod_pubsub: Ignore shadowed variable [luacheck]
Matthew Wild <mwild1@gmail.com> [Wed, 06 Mar 2024 17:38:21 +0000] rev 13460
mod_pubsub: Add shell commands to create and list nodes
Kim Alvefur <zash@zash.se> [Sat, 02 Mar 2024 14:14:27 +0100] rev 13459
core.features: Advertise that events are fired for SIGUSR1/2
Moved here from mod_posix since these events no longer originate there
Kim Alvefur <zash@zash.se> [Sat, 02 Mar 2024 14:08:47 +0100] rev 13458
util.startup: Fix firing of USR1/2 events