Developed with love by KnpLabs Hire us for your project!
18

SupervisorBundle

by ivan1986

bundle for control Supervisor

Supervisor Control Bundle

SensioLabsInsight
Scrutinizer Quality Score

knpbundles.com

This bundle for quick configure and usage separate instance of supervisord.

All Symfony2 commands run supervisor from kernel.root dir path.
If use config created by supervisor:init use local configure file.

install default by composer:

"ivan1986/supervisor": "*",

Initialize the bundle:

new Ivan1986\SupervisorBundle\SupervisorBundle(),

Bundle has commands:

  • supervisor:init
    • create supervisord.conf file and supervisor folder in app folder
  • supervisor:run
    • check instance of supervisord and run it if need
    • add this command to cron - simple quick watchdog for supervisord
  • supervisor:control
    • run any supervisorCtl command
  • supervisor:gen
    • generate simple programm section for symfony2 console command

Example code for rabbitmq scale workers.

$this->get('supervisor')->genProgrammConf('worker', array(
    'name' => 'worker',
    'command' => 'rabbitmq:consumer sender',
    'numprocs' => $this->getNeedWorkersCount(),
));
$this->get('supervisor')->run();
$this->get('supervisor')->reloadAndUpdate();

Service supervisor may run daemon, execute any command, and generate files for supervisord.

Also supervisord run with -i, configured by parameter. Without this list of
/usr/bin/python /usr/bin/supervisord in process list - great looking :)

DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004

Copyright (C) 2013 Ivan Borzenkov <ivan.borzenkov@gmail.com>

Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.

DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION

0. You just DO WHAT THE FUCK YOU WANT TO.
supervisor:
name: symfony2
  • Merge pull request #4 from ivan1986/scrutinizer-patch-1
    By web-flow, 3 years ago
  • Scrutinizer Auto-Fixes
    By scrutinizer-auto-fixer, 3 years ago
  • update composer
    By ivan1986, 3 years ago
  • SL lab fix - end line
    By ivan1986, 4 years ago
  • Merge pull request #1 from pborreli/patch-1
    By ivan1986, 5 years ago
  • Fixed typos
    By pborreli, 5 years ago
  • Опция имени перенесена в настройки
    By ivan1986, 5 years ago
  • add -i in run supervisord (for proc list)
    By ivan1986, 5 years ago
  • fix run
    By ivan1986, 5 years ago
  • init bundle (for quick copypaste)
    By ivan1986, 5 years ago
  • fix gen command
    By ivan1986, 6 years ago
  • cs fix 2
    By ivan1986, 6 years ago
  • php-cs-fixer
    By ivan1986, 6 years ago
  • reorder bages
    By ivan1986, 6 years ago
  • scrutinizer
    By ivan1986, 6 years ago
  • create scrutinizer file
    By ivan1986, 6 years ago
  • knp
    By ivan1986, 6 years ago
  • add bages
    By ivan1986, 6 years ago
  • remove std files
    By ivan1986, 6 years ago
  • unused code
    By ivan1986, 6 years ago
  • fix composer
    By ivan1986, 6 years ago
  • add example
    By ivan1986, 6 years ago
  • install bu composer
    By ivan1986, 6 years ago
  • fix comma
    By ivan1986, 6 years ago
  • LICENSE
    By ivan1986, 6 years ago
  • composer
    By ivan1986, 6 years ago
  • readme
    By ivan1986, 6 years ago
  • main functional
    By ivan1986, 6 years ago
  • init commit
    By ivan1986, 6 years ago