openshift.py fixes and improvements based on downstream tests

During tests for RHBZ#1039755 some issues were found. This PR is to implement those changes.