Don't log to stdout when log_dir is set

In addition to checking if log_file is set, we should check
for log_dir as well. Previously, If log_file is not set, oslo
will output logs to stdout even if log_dir is set. The only way
for example the Heat folks avoided logging to stdout was to
set log_file, but then all the heat processes ended up logging
to the same file. So a check for both log_dir and log_file
should avoid any output to stdout. Please note that use_stderr
should be set to false as well to avoid any output to console

Change-Id: Ie2886da679daedea0197ee3b3963ebedb8f11a0b
Closes-Bug: #1226287
Merge "Don't log to stdout when log_dir is set"