This code (knownOpts, shortHands, var argv = require('nopt') ...) is exactly the same is all hermes services.
We should probably move it into a small module and inherit from it.