added initial logging, redid config settings and flags