Skip to content

Commit

Permalink
Fixed host argument to use the getHost() function (#957)
Browse files Browse the repository at this point in the history
* fix-host-option: Fixed host argument to use the getHost() function from the inhirited trait.

* fix-host-option: Added fix for the roadrunn er command as well.
  • Loading branch information
elomonaco authored Sep 27, 2024
1 parent bfac74c commit 6cb1f30
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/Commands/StartFrankenPhpCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ class StartFrankenPhpCommand extends Command implements SignalableCommandInterfa
{--host=127.0.0.1 : The IP address the server should bind to}
{--port= : The port the server should be available on}
{--admin-host=localhost : The host the admin server should be available on}
{--admin-port= : The port the admin server should be available on}
{--admin-port=2019 : The port the admin server should be available on}
{--workers=auto : The number of workers that should be available to handle requests}
{--max-requests=500 : The number of requests to process before reloading the server}
{--caddyfile= : The path to the FrankenPHP Caddyfile file}
Expand Down Expand Up @@ -76,7 +76,7 @@ public function handle(ServerProcessInspector $inspector, ServerStateFile $serve

$this->forgetEnvironmentVariables();

$host = $this->option('host');
$host = $this->getHost();
$port = $this->getPort();

$https = $this->option('https');
Expand Down
2 changes: 1 addition & 1 deletion src/Commands/StartRoadRunnerCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ public function handle(ServerProcessInspector $inspector, ServerStateFile $serve
$roadRunnerBinary,
'-c', $this->configPath(),
'-o', 'version=3',
'-o', 'http.address='.$this->option('host').':'.$this->getPort(),
'-o', 'http.address='.$this->getHost().':'.$this->getPort(),
'-o', 'server.command='.(new PhpExecutableFinder)->find().','.base_path(config('octane.roadrunner.command', 'vendor/bin/roadrunner-worker')),
'-o', 'http.pool.num_workers='.$this->workerCount(),
'-o', 'http.pool.max_jobs='.$this->option('max-requests'),
Expand Down

0 comments on commit 6cb1f30

Please sign in to comment.