Make migration script log correctly

In all environments except dev, the django config overrides the logging. It
only does this when we access a variable from settings, which is the first
time we actually use any of django. Once django has bootstrapped the
logging, we can override with our own logging configuration - it should be
safe to set this to stdout as this is only ever run as a script.