Fix logging to stdout under Rails 4

Change-Id: I45824bbc1a12ff3aa2a6306980a1c30440916353