Articles in this section

What is the right way to run multiple processes from my start command?

This article has moved. Read the current version of What is the right way to run multiple processes from my start command? on Upsun Support.

Using a worker or multiple application containers is the recommended way of starting more than one process. But if you are not able to use a worker and have no other way, it is technically possible to use supervisord to start multiple processes. Please only use this as a last resort.

Example of running supervisord to run both PHP and dropboxd

dependencies:
  python:
    supervisor: '*'

web:
    commands:
        start: "supervisord -n -c supervisor.conf"

supervisor.conf gets committed to the repository and looks like this:

[supervisord]
logfile=/tmp/supervisord.log
nodaemon=true
minfds=1024
pidfile=/tmp/supervisord.pid

[program:php]
command=/usr/bin/start-php-app
process_name=%(program_name)s
autostart=true
autorestart=true

[program:dropbox]
process_name=%(program_name)s
command=/app/.dropbox-dist/dropboxd
autostart=true
autorestart=true
Was this article helpful?
0 out of 0 found this helpful

Comments

0 comments

Please sign in to leave a comment.