Ejemplo n.º 1
0
 public function showSetup()
 {
     $poudriere = new Poudriere();
     $this->writeln(sprintf('%-25s%-25s', 'POUDRIERE JAIL', 'REDPORTS QUEUE'));
     foreach ($poudriere->getAllJails() as $jail) {
         $queue = $jail->getQueue() ? $jail->getQueue() : '-';
         $this->writeln(sprintf('%-25s%-25s', $jail->getJailname(), $queue));
     }
     return 0;
 }
Ejemplo n.º 2
0
 public function execute($options, $arguments)
 {
     $logger = Config::getLogger();
     $pm = new ProcessManager();
     $poudriere = new Poudriere();
     foreach ($poudriere->getAllJails() as $jail) {
         if ($jail->getQueue() === null) {
             $logger->warning('Ignoring Jail ' . $jail->getJailname() . ' because Queue is not defined');
         } else {
             $logger->info('Adding Jail ' . $jail->getJailname() . ' to Queue ' . $jail->getQueue());
             $pm->addJail($jail);
         }
     }
     $pm->run();
 }