Skip to content

Commit 6eb0390

Browse files
author
=
committed
Fixed bundle to support changes to unix socket daemon
1 parent 2169472 commit 6eb0390

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

Command/DaemonRunCommand.php

100644100755
Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@ protected function configure()
2929
->setName('speedfony:daemon:run')
3030
->setDescription('Execute the FCGI daemon')
3131
->addArgument('cycles', InputArgument::OPTIONAL, 'Request cycles to live for, 0 means infinite (default is 20)', 20)
32-
->addOption('socket', null, InputOption::VALUE_REQUIRED, 'The socket stream to listen on')
3332
->addOption('port', null, InputOption::VALUE_REQUIRED, 'Port to listen on');
3433
}
3534

@@ -44,7 +43,7 @@ protected function execute(InputInterface $input, OutputInterface $output)
4443
throw new \LogicException('Unknown input type: ' . $type);
4544
}
4645

47-
$intValue = (int) $value;
46+
$intValue = (int) $value;
4847

4948
if ((string) $intValue !== $value) {
5049
throw new \Exception('The ' . $argument . ' argument must be an integer');
@@ -55,12 +54,10 @@ protected function execute(InputInterface $input, OutputInterface $output)
5554
return $value;
5655
};
5756

58-
if (null !== $input->getOption('socket')) {
59-
$daemon = new StreamSocketDaemon($input->getOption('socket'));
60-
} elseif (null !== $input->getOption('port')) {
57+
if (null !== $input->getOption('port')) {
6158
$daemon = new SocketDaemon($getIntegerInput('option', 'port', 0));
6259
} else {
63-
throw new \Exception('You must specify either the socket or port argument');
60+
$daemon = new StreamSocketDaemon();
6461
}
6562

6663
$maximumCycles = $getIntegerInput('argument', 'cycles', 0);

0 commit comments

Comments
 (0)