2
0

config.php.j2 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. <?php
  2. #域名设置
  3. define("RPC_SERVER","{{ app_rpc_server}}");
  4. define("ASSETS_SERVER","{{ app_assets_server }}");
  5. define('APP_KEY','{{ app_secret_key }}');
  6. /*
  7. 电子邮件设置
  8. PHPMailer
  9. */
  10. define("Email", [
  11. "Host"=>"{{ app_smtp_host }}",//Set the SMTP server to send through
  12. "SMTPAuth"=>true,//Enable SMTP authentication
  13. "Username"=>'{{ app_smtp_user }}',//SMTP username
  14. "Password"=>'{{ app_smtp_password }}',//SMTP password
  15. "Port"=>{{ app_smtp_port }},//TCP port to connect to 465; use 587 if you have set `SMTPSecure = PHPMailer::ENCRYPTION_STARTTLS`
  16. "From"=>"{{ app_smtp_user }}",
  17. "Sender"=>"webmaster"
  18. ]);
  19. /*
  20. 数据库设置
  21. */
  22. define("Database",[
  23. "type"=>"pgsql",
  24. "server"=>"{{ app_postgresql_host }}",
  25. "port"=>{{ app_postgresql_port }},
  26. "name"=>"{{ app_postgresql_dbname }}",
  27. "sslmode" => "disable",
  28. "user" => "{{ app_postgresql_user }}",
  29. "password" => "{{ app_postgresql_password }}"
  30. ]);
  31. /*
  32. Redis 设置,
  33. */
  34. define("Redis",[
  35. "host" => "{{ app_redis_host }}",
  36. "port" => {{ app_redis_port }},
  37. "password" => "",
  38. "prefix"=>"{{ app_deploy_env }}://www"
  39. ]);
  40. # 雪花id
  41. define("SnowFlake",[
  42. "DatacenterId"=>{{ app_snowflake_data_center_id }},
  43. "WorkerId"=>{{ app_snowflake_worker_id }}
  44. ]);
  45. #目录设置,不能更改
  46. require_once __DIR__."/config.dir.php";
  47. /*
  48. 数据表
  49. */
  50. #表设置,此行不能更改
  51. require_once __DIR__."/config.table.php";
  52. ?>