Fix OS detection for Gerrit postbuild
Merge pull request #2149 from DanRigby/master

Fix OS detection for Gerrit postbuild