Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
How to use supervisord in centos/fedora/red hat like systems

Supervisord

Configure and install supervisord

https://www.digitalocean.com/community/tutorials/how-to-install-and-manage-supervisor-on-ubuntu-and-debian-vps http://supervisord.org/configuration.html https://github.com/strongloop/node-foreman

easy_install supervisor
echo_supervisord_conf > /etc/supervisord.conf
supervisord -c /etc/supervisord.conf

echo -e "\n[include]\nfiles = /etc/supervisor/conf.d/*" > /etc/supervisord.conf
mkdir -p /etc/supervisor/conf.d/

supervisorctl reload
supervisorctl reread

Add suppervisord init script, to start on boot:

curl https://raw.githubusercontent.com/Supervisor/initscripts/master/redhat-init-mingalevme > /etc/rc.d/init.d/supervisord
chmod 755 /etc/rc.d/init.d/supervisord
chkconfig --add supervisord
chkconfig --list supervisord
chkconfig supervisord on
service supervisord start

I also had to add this to the init script: . /etc/bashrc.

Use this to manage the init service:

service supervisord stop
service supervisord status
service supervisord restart

supervisorctl start 'cors:*'

supervisorctl update Restarts apps whose configurations has changed. http://www.onurguzel.com/supervisord-restarting-and-reloading/

@rip057

This comment has been minimized.

Copy link

@rip057 rip057 commented Jan 28, 2018

why on earth would you do this...

dnf install supervisor
systemctl enable supervisord.service
systemctl start supervisord.service

supervisord.conf is located in etc with every single other conf file God has ever thought of.
RedHat and Fedora and CentOS, as well as most of Linux has taken that deep dive off the cliff into systemd, you should learn it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment