Send all logs to stderr by default instead of stdout. Fixes a problem where parsing the output of sandboxed commands could fail, because they could contain Rails log messages in their stdout. When we run a command in a sandbox, we call fork+exec to run the command in the background so we can capture its output. If Rails prints anything to stdout between the fork and exec calls, then it will be inadvertently captured along with the command's output. This will break parsing of the command's output. This can happen if warning messages are printed by Rails while setting up the sandbox between the fork and exec calls. Writing to stderr is also more correct, since stdout is buffered by default, which means logs could potentially be lost if the process dies unexpectedly before the buffers are flushed. Stderr is unbuffered by default, which means logs will always be output immediately.
Config
This directory contains configuration files for Danbooru.
To configure your Danbooru instance, copy danbooru_default_config.rb to danbooru_local_config.rb and edit it. See danbooru_default_config.rb for details.
The only file here that end users need to be concerned about is danbooru_default_config.rb. The rest of the files here are internal Rails-related configuration files that end users shouldn't need to edit.