Lines 1-51
Link Here
|
1 |
; Sample supervisor config file. |
1 |
; Sample supervisor config file. |
|
|
2 |
; |
3 |
; For more information on the config file, please see: |
4 |
; http://supervisord.org/configuration.html |
5 |
; |
6 |
; Notes: |
7 |
; - Shell expansion ("~" or "$HOME") is not supported. Environment |
8 |
; variables can be expanded using this syntax: "%(ENV_HOME)s". |
9 |
; - Quotes around values are not supported, except in the case of |
10 |
; the environment= options as shown below. |
11 |
; - Comments must have a leading space: "a=b ;comment" not "a=b;comment". |
12 |
; - Command will be truncated if it looks like a config file comment, e.g. |
13 |
; "command=bash -c 'foo ; bar'" will truncate to "command=bash -c 'foo ". |
2 |
|
14 |
|
3 |
[unix_http_server] |
15 |
[unix_http_server] |
4 |
file=/var/run/supervisor/supervisor.sock ; (the path to the socket file) |
16 |
file=/tmp/supervisor.sock ; the path to the socket file |
5 |
;chmod=0700 ; sockef file mode (default 0700) |
17 |
;chmod=0700 ; socket file mode (default 0700) |
6 |
;chown=nobody:nogroup ; socket file uid:gid owner |
18 |
;chown=nobody:nogroup ; socket file uid:gid owner |
7 |
;username=user ; (default is no username (open server)) |
19 |
;username=user ; default is no username (open server) |
8 |
;password=123 ; (default is no password (open server)) |
20 |
;password=123 ; default is no password (open server) |
9 |
|
21 |
|
10 |
;[inet_http_server] ; inet (TCP) server disabled by default |
22 |
;[inet_http_server] ; inet (TCP) server disabled by default |
11 |
;port=127.0.0.1:9001 ; (ip_address:port specifier, *:port for all iface) |
23 |
;port=127.0.0.1:9001 ; ip_address:port specifier, *:port for all iface |
12 |
;username=user ; (default is no username (open server)) |
24 |
;username=user ; default is no username (open server) |
13 |
;password=123 ; (default is no password (open server)) |
25 |
;password=123 ; default is no password (open server) |
14 |
|
26 |
|
15 |
[supervisord] |
27 |
[supervisord] |
16 |
logfile=/var/log/supervisord.log ; (main log file;default $CWD/supervisord.log) |
28 |
logfile=/tmp/supervisord.log ; main log file; default $CWD/supervisord.log |
17 |
logfile_maxbytes=50MB ; (max main logfile bytes b4 rotation;default 50MB) |
29 |
logfile_maxbytes=50MB ; max main logfile bytes b4 rotation; default 50MB |
18 |
logfile_backups=10 ; (num of main logfile rotation backups;default 10) |
30 |
logfile_backups=10 ; # of main logfile backups; 0 means none, default 10 |
19 |
loglevel=info ; (log level;default info; others: debug,warn,trace) |
31 |
loglevel=info ; log level; default info; others: debug,warn,trace |
20 |
pidfile=/var/run/supervisor/supervisord.pid ; (supervisord pidfile;default supervisord.pid) |
32 |
pidfile=/tmp/supervisord.pid ; supervisord pidfile; default supervisord.pid |
21 |
nodaemon=false ; (start in foreground if true;default false) |
33 |
nodaemon=false ; start in foreground if true; default false |
22 |
minfds=1024 ; (min. avail startup file descriptors;default 1024) |
34 |
minfds=1024 ; min. avail startup file descriptors; default 1024 |
23 |
minprocs=200 ; (min. avail process descriptors;default 200) |
35 |
minprocs=200 ; min. avail process descriptors;default 200 |
24 |
;umask=022 ; (process file creation umask;default 022) |
36 |
;umask=022 ; process file creation umask; default 022 |
25 |
;user=chrism ; (default is current user, required if root) |
37 |
;user=chrism ; default is current user, required if root |
26 |
;identifier=supervisor ; (supervisord identifier, default is 'supervisor') |
38 |
;identifier=supervisor ; supervisord identifier, default is 'supervisor' |
27 |
;directory=/tmp ; (default is not to cd during start) |
39 |
;directory=/tmp ; default is not to cd during start |
28 |
;nocleanup=true ; (don't clean up tempfiles at start;default false) |
40 |
;nocleanup=true ; don't clean up tempfiles at start; default false |
29 |
;childlogdir=/tmp ; ('AUTO' child log dir, default $TEMP) |
41 |
;childlogdir=/tmp ; 'AUTO' child log dir, default $TEMP |
30 |
;environment=KEY=value ; (key value pairs to add to environment) |
42 |
;environment=KEY="value" ; key value pairs to add to environment |
31 |
;strip_ansi=false ; (strip ansi escape codes in logs; def. false) |
43 |
;strip_ansi=false ; strip ansi escape codes in logs; def. false |
32 |
|
44 |
|
33 |
; the below section must remain in the config file for RPC |
45 |
; The rpcinterface:supervisor section must remain in the config file for |
34 |
; (supervisorctl/web interface) to work, additional interfaces may be |
46 |
; RPC (supervisorctl/web interface) to work. Additional interfaces may be |
35 |
; added by defining them in separate rpcinterface: sections |
47 |
; added by defining them in separate [rpcinterface:x] sections. |
|
|
48 |
|
36 |
[rpcinterface:supervisor] |
49 |
[rpcinterface:supervisor] |
37 |
supervisor.rpcinterface_factory = supervisor.rpcinterface:make_main_rpcinterface |
50 |
supervisor.rpcinterface_factory = supervisor.rpcinterface:make_main_rpcinterface |
38 |
|
51 |
|
|
|
52 |
; The supervisorctl section configures how supervisorctl will connect to |
53 |
; supervisord. configure it match the settings in either the unix_http_server |
54 |
; or inet_http_server section. |
55 |
|
39 |
[supervisorctl] |
56 |
[supervisorctl] |
40 |
serverurl=unix:///var/run/supervisor/supervisor.sock ; use a unix:// URL for a unix socket |
57 |
serverurl=unix:///tmp/supervisor.sock ; use a unix:// URL for a unix socket |
41 |
;serverurl=http://127.0.0.1:9001 ; use an http:// url to specify an inet socket |
58 |
;serverurl=http://127.0.0.1:9001 ; use an http:// url to specify an inet socket |
42 |
;username=chris ; should be same as http_username if set |
59 |
;username=chris ; should be same as in [*_http_server] if set |
43 |
;password=123 ; should be same as http_password if set |
60 |
;password=123 ; should be same as in [*_http_server] if set |
44 |
;prompt=mysupervisor ; cmd line prompt (default "supervisor") |
61 |
;prompt=mysupervisor ; cmd line prompt (default "supervisor") |
45 |
;history_file=~/.sc_history ; use readline history if available |
62 |
;history_file=~/.sc_history ; use readline history if available |
46 |
|
63 |
|
47 |
; The below sample program section shows all possible program subsection values, |
64 |
; The sample program section below shows all possible program subsection values. |
48 |
; create one or more 'real' program: sections to be able to control them under |
65 |
; Create one or more 'real' program: sections to be able to control them under |
49 |
; supervisor. |
66 |
; supervisor. |
50 |
|
67 |
|
51 |
;[program:theprogramname] |
68 |
;[program:theprogramname] |
Lines 56-86
Link Here
|
56 |
;umask=022 ; umask for process (default None) |
73 |
;umask=022 ; umask for process (default None) |
57 |
;priority=999 ; the relative start priority (default 999) |
74 |
;priority=999 ; the relative start priority (default 999) |
58 |
;autostart=true ; start at supervisord start (default: true) |
75 |
;autostart=true ; start at supervisord start (default: true) |
59 |
;autorestart=true ; retstart at unexpected quit (default: true) |
76 |
;startsecs=1 ; # of secs prog must stay up to be running (def. 1) |
60 |
;startsecs=10 ; number of secs prog must stay running (def. 1) |
77 |
;startretries=3 ; max # of serial start failures when starting (default 3) |
61 |
;startretries=3 ; max # of serial start failures (default 3) |
78 |
;autorestart=unexpected ; when to restart if exited after running (def: unexpected) |
62 |
;exitcodes=0,2 ; 'expected' exit codes for process (default 0,2) |
79 |
;exitcodes=0,2 ; 'expected' exit codes used with autorestart (default 0,2) |
63 |
;stopsignal=QUIT ; signal used to kill process (default TERM) |
80 |
;stopsignal=QUIT ; signal used to kill process (default TERM) |
64 |
;stopwaitsecs=10 ; max num secs to wait b4 SIGKILL (default 10) |
81 |
;stopwaitsecs=10 ; max num secs to wait b4 SIGKILL (default 10) |
|
|
82 |
;stopasgroup=false ; send stop signal to the UNIX process group (default false) |
83 |
;killasgroup=false ; SIGKILL the UNIX process group (def false) |
65 |
;user=chrism ; setuid to this UNIX account to run the program |
84 |
;user=chrism ; setuid to this UNIX account to run the program |
66 |
;redirect_stderr=true ; redirect proc stderr to stdout (default false) |
85 |
;redirect_stderr=true ; redirect proc stderr to stdout (default false) |
67 |
;stdout_logfile=/a/path ; stdout log path, NONE for none; default AUTO |
86 |
;stdout_logfile=/a/path ; stdout log path, NONE for none; default AUTO |
68 |
;stdout_logfile_maxbytes=1MB ; max # logfile bytes b4 rotation (default 50MB) |
87 |
;stdout_logfile_maxbytes=1MB ; max # logfile bytes b4 rotation (default 50MB) |
69 |
;stdout_logfile_backups=10 ; # of stdout logfile backups (default 10) |
88 |
;stdout_logfile_backups=10 ; # of stdout logfile backups (0 means none, default 10) |
70 |
;stdout_capture_maxbytes=1MB ; number of bytes in 'capturemode' (default 0) |
89 |
;stdout_capture_maxbytes=1MB ; number of bytes in 'capturemode' (default 0) |
71 |
;stdout_events_enabled=false ; emit events on stdout writes (default false) |
90 |
;stdout_events_enabled=false ; emit events on stdout writes (default false) |
72 |
;stderr_logfile=/a/path ; stderr log path, NONE for none; default AUTO |
91 |
;stderr_logfile=/a/path ; stderr log path, NONE for none; default AUTO |
73 |
;stderr_logfile_maxbytes=1MB ; max # logfile bytes b4 rotation (default 50MB) |
92 |
;stderr_logfile_maxbytes=1MB ; max # logfile bytes b4 rotation (default 50MB) |
74 |
;stderr_logfile_backups=10 ; # of stderr logfile backups (default 10) |
93 |
;stderr_logfile_backups=10 ; # of stderr logfile backups (0 means none, default 10) |
75 |
;stderr_capture_maxbytes=1MB ; number of bytes in 'capturemode' (default 0) |
94 |
;stderr_capture_maxbytes=1MB ; number of bytes in 'capturemode' (default 0) |
76 |
;stderr_events_enabled=false ; emit events on stderr writes (default false) |
95 |
;stderr_events_enabled=false ; emit events on stderr writes (default false) |
77 |
;environment=A=1,B=2 ; process environment additions (def no adds) |
96 |
;environment=A="1",B="2" ; process environment additions (def no adds) |
78 |
;serverurl=AUTO ; override serverurl computation (childutils) |
97 |
;serverurl=AUTO ; override serverurl computation (childutils) |
79 |
|
98 |
|
80 |
; The below sample eventlistener section shows all possible |
99 |
; The sample eventlistener section below shows all possible eventlistener |
81 |
; eventlistener subsection values, create one or more 'real' |
100 |
; subsection values. Create one or more 'real' eventlistener: sections to be |
82 |
; eventlistener: sections to be able to handle event notifications |
101 |
; able to handle event notifications sent by supervisord. |
83 |
; sent by supervisor. |
|
|
84 |
|
102 |
|
85 |
;[eventlistener:theeventlistenername] |
103 |
;[eventlistener:theeventlistenername] |
86 |
;command=/bin/eventlistener ; the program (relative uses PATH, can take args) |
104 |
;command=/bin/eventlistener ; the program (relative uses PATH, can take args) |
Lines 92-119
Link Here
|
92 |
;umask=022 ; umask for process (default None) |
110 |
;umask=022 ; umask for process (default None) |
93 |
;priority=-1 ; the relative start priority (default -1) |
111 |
;priority=-1 ; the relative start priority (default -1) |
94 |
;autostart=true ; start at supervisord start (default: true) |
112 |
;autostart=true ; start at supervisord start (default: true) |
95 |
;autorestart=unexpected ; restart at unexpected quit (default: unexpected) |
113 |
;startsecs=1 ; # of secs prog must stay up to be running (def. 1) |
96 |
;startsecs=10 ; number of secs prog must stay running (def. 1) |
114 |
;startretries=3 ; max # of serial start failures when starting (default 3) |
97 |
;startretries=3 ; max # of serial start failures (default 3) |
115 |
;autorestart=unexpected ; autorestart if exited after running (def: unexpected) |
98 |
;exitcodes=0,2 ; 'expected' exit codes for process (default 0,2) |
116 |
;exitcodes=0,2 ; 'expected' exit codes used with autorestart (default 0,2) |
99 |
;stopsignal=QUIT ; signal used to kill process (default TERM) |
117 |
;stopsignal=QUIT ; signal used to kill process (default TERM) |
100 |
;stopwaitsecs=10 ; max num secs to wait b4 SIGKILL (default 10) |
118 |
;stopwaitsecs=10 ; max num secs to wait b4 SIGKILL (default 10) |
|
|
119 |
;stopasgroup=false ; send stop signal to the UNIX process group (default false) |
120 |
;killasgroup=false ; SIGKILL the UNIX process group (def false) |
101 |
;user=chrism ; setuid to this UNIX account to run the program |
121 |
;user=chrism ; setuid to this UNIX account to run the program |
102 |
;redirect_stderr=true ; redirect proc stderr to stdout (default false) |
122 |
;redirect_stderr=false ; redirect_stderr=true is not allowed for eventlisteners |
103 |
;stdout_logfile=/a/path ; stdout log path, NONE for none; default AUTO |
123 |
;stdout_logfile=/a/path ; stdout log path, NONE for none; default AUTO |
104 |
;stdout_logfile_maxbytes=1MB ; max # logfile bytes b4 rotation (default 50MB) |
124 |
;stdout_logfile_maxbytes=1MB ; max # logfile bytes b4 rotation (default 50MB) |
105 |
;stdout_logfile_backups=10 ; # of stdout logfile backups (default 10) |
125 |
;stdout_logfile_backups=10 ; # of stdout logfile backups (0 means none, default 10) |
106 |
;stdout_events_enabled=false ; emit events on stdout writes (default false) |
126 |
;stdout_events_enabled=false ; emit events on stdout writes (default false) |
107 |
;stderr_logfile=/a/path ; stderr log path, NONE for none; default AUTO |
127 |
;stderr_logfile=/a/path ; stderr log path, NONE for none; default AUTO |
108 |
;stderr_logfile_maxbytes=1MB ; max # logfile bytes b4 rotation (default 50MB) |
128 |
;stderr_logfile_maxbytes=1MB ; max # logfile bytes b4 rotation (default 50MB) |
109 |
;stderr_logfile_backups ; # of stderr logfile backups (default 10) |
129 |
;stderr_logfile_backups=10 ; # of stderr logfile backups (0 means none, default 10) |
110 |
;stderr_events_enabled=false ; emit events on stderr writes (default false) |
130 |
;stderr_events_enabled=false ; emit events on stderr writes (default false) |
111 |
;environment=A=1,B=2 ; process environment additions |
131 |
;environment=A="1",B="2" ; process environment additions |
112 |
;serverurl=AUTO ; override serverurl computation (childutils) |
132 |
;serverurl=AUTO ; override serverurl computation (childutils) |
113 |
|
133 |
|
114 |
; The below sample group section shows all possible group values, |
134 |
; The sample group section below shows all possible group values. Create one |
115 |
; create one or more 'real' group: sections to create "heterogeneous" |
135 |
; or more 'real' group: sections to create "heterogeneous" process groups. |
116 |
; process groups. |
|
|
117 |
|
136 |
|
118 |
;[group:thegroupname] |
137 |
;[group:thegroupname] |
119 |
;programs=progname1,progname2 ; each refers to 'x' in [program:x] definitions |
138 |
;programs=progname1,progname2 ; each refers to 'x' in [program:x] definitions |