Support run mode set by env var BEEGO_RUNMODE
fix #833
Remove dependency of third party lib
Merge pull request #849 from pabdavis/runmode-env

Support run mode set by environment variable