Address review comments plus general cleanup

* fix get_db_dump to use the specified DB name
* fix doc on get_db_dump
* fix env.root on production
* add better doc for get_media
* removed some unused things