Disable stdout buffering.
Allow upload to be run concurrently by splitting it into two phases.