| @@ 75-91 (lines=17) @@ | ||
| 72 | * Execute the console command. |
|
| 73 | * |
|
| 74 | */ |
|
| 75 | public function handle() |
|
| 76 | { |
|
| 77 | $this->abortCommandExecution(); |
|
| 78 | ||
| 79 | $this->info('Executing deploy script for site ' . $this->site . ' in Laravel Forge'); |
|
| 80 | ||
| 81 | $this->url = $this->obtainAPIURLEndpoint(); |
|
| 82 | ||
| 83 | $this->http->post($this->url, [ |
|
| 84 | 'headers' => [ |
|
| 85 | 'X-Requested-With' => 'XMLHttpRequest', |
|
| 86 | 'Authorization' => 'Bearer ' . fp_env('ACACHA_FORGE_ACCESS_TOKEN') |
|
| 87 | ] |
|
| 88 | ] |
|
| 89 | ); |
|
| 90 | } |
|
| 91 | ||
| 92 | /** |
|
| 93 | * Obtain API URL endpoint. |
|
| 94 | * |
|
| @@ 75-87 (lines=13) @@ | ||
| 72 | /** |
|
| 73 | * Create MySQL user. |
|
| 74 | */ |
|
| 75 | protected function createMySQLUser() |
|
| 76 | { |
|
| 77 | $this->checkParameters(); |
|
| 78 | $this->url = $this->obtainAPIURLEndpoint(); |
|
| 79 | $this->http->post($this->url, [ |
|
| 80 | 'form_params' => $this->getData(), |
|
| 81 | 'headers' => [ |
|
| 82 | 'X-Requested-With' => 'XMLHttpRequest', |
|
| 83 | 'Authorization' => 'Bearer ' . fp_env('ACACHA_FORGE_ACCESS_TOKEN') |
|
| 84 | ] |
|
| 85 | ] |
|
| 86 | ); |
|
| 87 | } |
|
| 88 | ||
| 89 | /** |
|
| 90 | * List MySQL users. |
|