config.php 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103
  1. <?php
  2. use Rocketeer\Services\Connections\ConnectionsHandler;
  3. return [
  4. // The name of the application to deploy
  5. // This will create a folder of the same name in the root directory
  6. // configured above, so be careful about the characters used
  7. 'application_name' => 'cms-manage',
  8. // Plugins
  9. ////////////////////////////////////////////////////////////////////
  10. // The plugins to load
  11. 'plugins' => [// 'Rocketeer\Plugins\Slack\RocketeerSlack',
  12. ],
  13. // Logging
  14. ////////////////////////////////////////////////////////////////////
  15. // The schema to use to name log files
  16. 'logs' => function (ConnectionsHandler $connections) {
  17. return sprintf('%s-%s-%s.log', $connections->getConnection(), $connections->getStage(), date('Ymd'));
  18. },
  19. // Remote access
  20. //
  21. // You can either use a single connection or an array of connections
  22. ////////////////////////////////////////////////////////////////////
  23. // The default remote connection(s) to execute tasks on
  24. 'default' => ['beta'],
  25. // The various connections you defined
  26. // You can leave all of this empty or remove it entirely if you don't want
  27. // to track files with credentials : Rocketeer will prompt you for your credentials
  28. // and store them locally
  29. 'connections' => [
  30. 'beta' => [
  31. 'host' => '47.92.174.125:2345',
  32. 'username' => 'root',
  33. 'password' => '',
  34. 'key' => '/root/.ssh/id_rsa',
  35. 'keyphrase' => '',
  36. 'agent' => '',
  37. 'db_role' => true,
  38. ],
  39. 'production' => [
  40. 'host' => '47.92.121.231:2345',
  41. 'username' => 'root',
  42. 'password' => '',
  43. 'key' => '/root/.ssh/id_rsa',
  44. 'keyphrase' => '',
  45. 'agent' => '',
  46. 'db_role' => true,
  47. ],
  48. ],
  49. /*
  50. * In most multiserver scenarios, migrations must be run in an exclusive server.
  51. * In the event of not having a separate database server (in which case it can
  52. * be handled through connections), you can assign a 'db_role' => true to the
  53. * server's configuration and it will only run the migrations in that specific
  54. * server at the time of deployment.
  55. */
  56. 'use_roles' => false,
  57. // Contextual options
  58. //
  59. // In this section you can fine-tune the above configuration according
  60. // to the stage or connection currently in use.
  61. // Per example :
  62. // 'stages' => array(
  63. // 'staging' => array(
  64. // 'scm' => array('branch' => 'staging'),
  65. // ),
  66. // 'production' => array(
  67. // 'scm' => array('branch' => 'master'),
  68. // ),
  69. // ),
  70. ////////////////////////////////////////////////////////////////////
  71. 'on' => [
  72. // Stages configurations
  73. 'stages' => [],
  74. // Connections configuration
  75. 'connections' => [
  76. 'production' => [
  77. 'remote' => [
  78. 'root_directory' => '/data/wwwroot/uptoyo/api'
  79. ],
  80. 'scm' => [
  81. 'branch' => 'release'
  82. ]
  83. ]
  84. ],
  85. ],
  86. ];