It looks like fd 3 needs to be closed IN ADDITION to STDIN/STDOUT/STDERR for direnv to return control to the user.
By closing fd 3 after we fork but before we exec redis-server and mariadbd, we can ensure that they don't cause direnv to hang.
Kind of annoying, but direnv is not designed to handle launching of daemons.. and we're doing some custom stuff instead of launchd.