Supervisor Module

Oh, god. Supervisord.

Installs Supervisord on the remote machine. Uses the standard config file produced by the echo_supervisord_conf command. This standard config is modified to point to your custom supervisord.conf template (that actually has the commands used for stopping/starting/etc a process).

Supervisor Module Settings

SUPERVISOR_TEMPLATE_PATH = "templates/supervisorctl.conf"  #PATH ON LOCAL DISK, RELATIVE TO THIS FILE
SUPERVISOR_INIT_TEMPLATE = "templates/supervisor-init"  #PATH ON LOCAL DISK, Relative to THIS file.
SUPERVISOR_DICT = {
    "gunicorn_port": DJANGO_GUNICORN_PORT,
    "gunicorn_workers": 3
}
modules.supervisor.bootstrap(deploy_level='staging')[source]

Installs supervisor, creates required directories (if they don’t exist). Points supervisord.conf to look in the correct folder for service info

modules.supervisor.setup_dirs()[source]

create (if necessary) and make writable uploaded media, log, etc. directories

modules.supervisor.upload_sup_template()[source]

Uploads the supervisor template to the server (while populating the template)

Table Of Contents

Previous topic

Packages Module

Next topic

Web Module

This Page