Friendica Communications Platform (please note that this is a clone of the repository at github, issues are handled there) https://friendi.ca
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

34 lines
571B

  1. <?php /** @file */
  2. use Friendica\App;
  3. use Friendica\Core\Config;
  4. require_once('boot.php');
  5. // Everything we need to boot standalone 'background' processes
  6. function cli_startup() {
  7. global $a, $db;
  8. if (is_null($a)) {
  9. $a = new App(dirname(__DIR__));
  10. }
  11. if (is_null($db)) {
  12. @include(".htconfig.php");
  13. require_once("dba.php");
  14. $db = new dba($db_host, $db_user, $db_pass, $db_data);
  15. unset($db_host, $db_user, $db_pass, $db_data);
  16. };
  17. require_once('include/session.php');
  18. Config::load();
  19. $a->set_baseurl(get_config('system','url'));
  20. load_hooks();
  21. }