public static function getRoot() {
    if (!isset(self::$root)) {
      try {

        $root = getenv('PSC_CMS');

        if (!empty($root)) {
          return self::$root = new Dir($root);
        }
  
      } catch (\Webforge\Common\System\Exception $e) {}

      throw MissingEnvironmentVariableException::factory('PSC_CMS', 'The variable should reference a directory, where the host-config.php can live. Use trailing slash/backslash.');
    }

    return self::$root;
  }