public static function init()
    {
        $instance = self::getInstance();
        $instance->_environments = $instance->_loadEnvironment($instance->_envPath . DS . 'config.php');

        if (!isset($instance->_environments['local'])) {
            $instance->_environments['local'] = [];
        }

        $instance->_current = $instance->_getEnvironment();

        if ($instance->_current !== null && isset($instance->_environments[$instance->_current])) {
            $instance->_loadEnvironment($instance->_envPath . DS . 'environment.' . $instance->_current . '.php');
        }
    }