diff --git a/app/Console/Commands/Cluster/Work.php b/app/Console/Commands/Cluster/Work.php index 1eeaf29..2094853 100644 --- a/app/Console/Commands/Cluster/Work.php +++ b/app/Console/Commands/Cluster/Work.php @@ -116,7 +116,9 @@ public function handle(): int // 子进程 $this->info('正在启动 Web。'); - $command = "php artisan octane:start --host=$node_host --port=$node_port"; + $rpc_port = config('settings.node.rpc_port'); + + $command = "php artisan octane:start --host=$node_host --rpc-port=$rpc_port --port=$node_port"; $this->pipeCommand($command); } else { $this->report(); diff --git a/config/settings.php b/config/settings.php index 52ca304..13de09e 100644 --- a/config/settings.php +++ b/config/settings.php @@ -22,6 +22,7 @@ 'type' => env('NODE_TYPE', 'slave'), 'id' => env('NODE_ID'), 'ip' => env('NODE_IP'), + 'rpc_port' => env('NODE_RPC_PORT', 6001), ], 'roadrunner' => [ 'version' => env('ROADRUNNER_VERSION', '2.12.1'),