config.sample.php 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. <?php
  2. // Require Composer's autoloader.
  3. require_once '../../vendor/autoload.php';
  4. #域名设置
  5. define(WWW_DOMAIN_NAME,"sg.wikipali.org");
  6. define(RPC_DOMAIN_NAME,"rpc.wikipali.org");
  7. /*
  8. 电子邮件设置
  9. PHPMailer
  10. */
  11. use PHPMailer\PHPMailer\PHPMailer;
  12. use PHPMailer\PHPMailer\SMTP;
  13. use PHPMailer\PHPMailer\Exception;
  14. define("Email", ["SMTPDebug"=>SMTP::DEBUG_SERVER,//Enable verbose debug output DEBUG_OFF
  15. "Host"=>"smtp.gmail.com",//Set the SMTP server to send through
  16. "SMTPAuth"=>true,//Enable SMTP authentication
  17. "Username"=>'your@gmail.com',//SMTP username
  18. "Password"=>'your_password',//SMTP password
  19. "SMTPSecure"=>PHPMailer::ENCRYPTION_SMTPS,//Enable implicit TLS encryption
  20. "Port"=>465,//TCP port to connect to 465; use 587 if you have set `SMTPSecure = PHPMailer::ENCRYPTION_STARTTLS`
  21. "From"=>"your@gmail.com",
  22. "Sender"=>"sender"
  23. ]);
  24. /*
  25. 数据库设置
  26. */
  27. define("Database",[
  28. "type"=>"pgsql",
  29. "port"=>5432,
  30. "name"=>"mint",
  31. "sslmode" => "disable",
  32. "user" => "postgres",
  33. "password" => "123456"
  34. ]);
  35. #数据库
  36. # 数据库基本参数 pgsql sqlite
  37. define("_DB_ENGIN_", "pgsql");
  38. define("_DB_HOST_", "localhost");
  39. define("_DB_NAME_", "mint");
  40. define("_DB_PORT_", "5432");
  41. define("_DB_USERNAME_", "postgres");
  42. define("_DB_PASSWORD_", "123456");
  43. /*
  44. Redis 设置,
  45. 使用集群
  46. */
  47. define("Redis",[
  48. "hosts" => ["127.0.0.1:6376", "127.0.0.1:6377", "127.0.0.1:6378"],
  49. "password" => "",
  50. "db" => 0,
  51. "prefix"=>"aaa://"
  52. ]);
  53. ?>