Ignore possibly overridden container hostname.
If docker container hostname is overridden, the hostname in cgroups must be ignored. Hostname can be overridden using [-h|--hostname[=HOSTNAME]] docker run option.
I am sorry for not noticing this earlier! This is definitely a needed improvement. Could you try to merge in latest master and fix any conflicts? I'll try to review and merge in after that. Also, please don't bump version in package.json — I'll bump that using npm versioning commands myself. Thanks!
Thanks for getting back after all this time. I've amended my pull request as you requested - leaving out the version bump.
DEPRECATED (You can use following package instead: https://github.com/sindresorhus/is-docker)