Minor fixes and more output for debug
Pipe Jenkins stdout to file.