Clean up code, increase log size, log run time

* Moved global variables into main section (for logging)
* Increased the size of the rotating run logs to 10 Mb
* Started logging run time (UTC) as a run identifier
Improve error handling around logs

Properly separate posting match messages to the wiki
from logging to the DB.