refactored to simplify requiring and usage when starting an app with minioc-director