[ Index ]

PHP Cross Reference of Phabricator

title

Body

[close]

/src/applications/daemon/management/ -> PhabricatorDaemonManagementStopWorkflow.php (source)

   1  <?php
   2  
   3  final class PhabricatorDaemonManagementStopWorkflow
   4    extends PhabricatorDaemonManagementWorkflow {
   5  
   6    public function didConstruct() {
   7      $this
   8        ->setName('stop')
   9        ->setSynopsis(
  10          pht(
  11            'Stop all running daemons, or specific daemons identified by PIDs. '.
  12            'Use **phd status** to find PIDs.'))
  13        ->setArguments(
  14          array(
  15            array(
  16              'name' => 'graceful',
  17              'param' => 'seconds',
  18              'help' => pht(
  19                'Grace period for daemons to attempt a clean shutdown, in '.
  20                'seconds. Defaults to __15__ seconds.'),
  21              'default' => 15,
  22            ),
  23            array(
  24              'name' => 'force',
  25              'help' => pht(
  26                'Also stop running processes that look like daemons but do '.
  27                'not have corresponding PID files.'),
  28            ),
  29            array(
  30              'name' => 'pids',
  31              'wildcard' => true,
  32            ),
  33          ));
  34    }
  35  
  36    public function execute(PhutilArgumentParser $args) {
  37      $pids = $args->getArg('pids');
  38      $graceful = $args->getArg('graceful');
  39      $force = $args->getArg('force');
  40      return $this->executeStopCommand($pids, $graceful, $force);
  41    }
  42  
  43  }


Generated: Sun Nov 30 09:20:46 2014 Cross-referenced by PHPXref 0.7.1