Closed sergx closed 1 year ago
The ngrok config
command edits the configuration file, it should not be done every time when starting the tunnel, you must add your configurations using ngrok config
or editing the configuration file manually before starting the tunnel, the ngrok will load the configurations from the default configuration file, or you can specify the configuration file using php artisan ngrok --extra='--config=ngrok.yml' loc-team.test
.
Describe the bug I got error in console after
php artisan ngrok loc-team.test
:cURL error 7: Send failure: Connection was reset (see https://curl.haxx.se/libcurl/c/libcurl-errors.html) for http://127.0.0.1:4041/api/tunne
After some research i figured out, that this error appears because ngrok just did not started properly. And it's because it wanted me to set auth token (with command
ngrok config add-authtoken
).The ngrok token you can get at https://dashboard.ngrok.com/get-started/setup
To solve the problem in the
NgrokProcessBuilder.php
file i added one line:$command = explode(" ", "ngrok config add-authtoken XXXXXXXXXXX");
beforereturn new Process($command, $this->getWorkingDirectory(), null, null, null);
And commented outif
block with$tunnels = $webService->getTunnels();
in theNgrokCommand.php
This changes i made only for one request CLI command -
php artisan ngrok