View | Details | Raw Unified | Return to bug 221539 | Differences between
and this patch

Collapse All | Expand All

(-)Makefile (-1 / +1 lines)
Lines 2-8 Link Here
2
# $FreeBSD$
2
# $FreeBSD$
3
3
4
PORTNAME=	supervisor
4
PORTNAME=	supervisor
5
PORTVERSION=	3.3.0
5
PORTVERSION=	3.3.3
6
PORTEPOCH=	1
6
PORTEPOCH=	1
7
CATEGORIES=	sysutils python
7
CATEGORIES=	sysutils python
8
MASTER_SITES=	CHEESESHOP
8
MASTER_SITES=	CHEESESHOP
(-)distinfo (-3 / +3 lines)
Lines 1-3 Link Here
1
TIMESTAMP = 1465394448
1
TIMESTAMP = 1502190315
2
SHA256 (supervisor-3.3.0.tar.gz) = 3176fb8a78c60164020e252e4a2b50b039cfec1f410b4562a843b66186188652
2
SHA256 (supervisor-3.3.3.tar.gz) = 96287ebfabf9a6923f74123b056c4da39c617fef367980f007cac02fba6527ad
3
SIZE (supervisor-3.3.0.tar.gz) = 416329
3
SIZE (supervisor-3.3.3.tar.gz) = 418354
(-)files/patch-supervisor-tests-test_options.py (-19 / +17 lines)
Lines 1-6 Link Here
1
--- supervisor/tests/test_options.py.orig	2016-05-14 21:19:49.000000000 +0300
1
--- supervisor/tests/test_options.py.orig	2017-07-24 19:48:01 UTC
2
+++ supervisor/tests/test_options.py	2016-06-08 17:05:08.114929000 +0300
2
+++ supervisor/tests/test_options.py
3
@@ -157,15 +157,15 @@ class OptionTests(unittest.TestCase):
3
@@ -158,15 +158,15 @@ class OptionTests(unittest.TestCase):
4
             short=False,
4
             short=False,
5
             )
5
             )
6
 
6
 
Lines 25-31 Link Here
25
 
25
 
26
     def test_options_and_args_order(self):
26
     def test_options_and_args_order(self):
27
         # Only config file exists
27
         # Only config file exists
28
@@ -352,17 +352,17 @@ class ClientOptionsTests(unittest.TestCa
28
@@ -353,17 +353,17 @@ class ClientOptionsTests(unittest.TestCa
29
         except ValueError, exc:
29
         except ValueError, exc:
30
             self.assertTrue("could not find config file" in exc.args[0])
30
             self.assertTrue("could not find config file" in exc.args[0])
31
 
31
 
Lines 34-51 Link Here
34
-        def dummy_open(fn, mode):
34
-        def dummy_open(fn, mode):
35
-            raise IOError(errno.EACCES, 'Permission denied: %s' % fn)
35
-            raise IOError(errno.EACCES, 'Permission denied: %s' % fn)
36
-        instance.open = dummy_open
36
-        instance.open = dummy_open
37
-
37
+#    def test_read_config_unreadable(self):
38
+#        instance = self._makeOne()
39
+#        def dummy_open(fn, mode):
40
+#            raise IOError(errno.EACCES, 'Permission denied: %s' % fn)
41
+#        instance.open = dummy_open
42
 
38
-        try:
43
-        try:
39
-            instance.read_config(__file__)
44
-            instance.read_config(__file__)
40
-            self.fail("expected exception")
45
-            self.fail("expected exception")
41
-        except ValueError, exc:
46
-        except ValueError, exc:
42
-            self.assertTrue("could not read config file" in exc.args[0])
47
-            self.assertTrue("could not read config file" in exc.args[0])
43
+#    def test_read_config_unreadable(self):
44
+#        instance = self._makeOne()
45
+#        def dummy_open(fn, mode):
46
+#            raise IOError(errno.EACCES, 'Permission denied: %s' % fn)
47
+#        instance.open = dummy_open
48
+
49
+#        try:
48
+#        try:
50
+#            instance.read_config(__file__)
49
+#            instance.read_config(__file__)
51
+#            self.fail("expected exception")
50
+#            self.fail("expected exception")
Lines 54-60 Link Here
54
 
53
 
55
     def test_read_config_no_supervisord_section_raises_valueerror(self):
54
     def test_read_config_no_supervisord_section_raises_valueerror(self):
56
         instance = self._makeOne()
55
         instance = self._makeOne()
57
@@ -803,17 +803,17 @@ class ServerOptionsTests(unittest.TestCa
56
@@ -804,17 +804,17 @@ class ServerOptionsTests(unittest.TestCa
58
         except ValueError, exc:
57
         except ValueError, exc:
59
             self.assertTrue("could not find config file" in exc.args[0])
58
             self.assertTrue("could not find config file" in exc.args[0])
60
 
59
 
Lines 63-80 Link Here
63
-        def dummy_open(fn, mode):
62
-        def dummy_open(fn, mode):
64
-            raise IOError(errno.EACCES, 'Permission denied: %s' % fn)
63
-            raise IOError(errno.EACCES, 'Permission denied: %s' % fn)
65
-        instance.open = dummy_open
64
-        instance.open = dummy_open
66
-
65
+#    def test_read_config_unreadable(self):
66
+#        instance = self._makeOne()
67
+#        def dummy_open(fn, mode):
68
+#            raise IOError(errno.EACCES, 'Permission denied: %s' % fn)
69
+#        instance.open = dummy_open
70
 
67
-        try:
71
-        try:
68
-            instance.read_config(__file__)
72
-            instance.read_config(__file__)
69
-            self.fail("nothing raised")
73
-            self.fail("nothing raised")
70
-        except ValueError, exc:
74
-        except ValueError, exc:
71
-            self.assertTrue("could not read config file" in exc.args[0])
75
-            self.assertTrue("could not read config file" in exc.args[0])
72
+#    def test_read_config_unreadable(self):
73
+#        instance = self._makeOne()
74
+#        def dummy_open(fn, mode):
75
+#            raise IOError(errno.EACCES, 'Permission denied: %s' % fn)
76
+#        instance.open = dummy_open
77
+
78
+#        try:
76
+#        try:
79
+#            instance.read_config(__file__)
77
+#            instance.read_config(__file__)
80
+#            self.fail("nothing raised")
78
+#            self.fail("nothing raised")
(-)files/patch-supervisor-tests-test_supervisorctl.py (-3 / +3 lines)
Lines 1-6 Link Here
1
--- supervisor/tests/test_supervisorctl.py.orig	2016-06-08 17:08:09.404989000 +0300
1
--- supervisor/tests/test_supervisorctl.py.orig	2017-07-24 19:48:01 UTC
2
+++ supervisor/tests/test_supervisorctl.py	2016-06-08 17:08:32.361939000 +0300
2
+++ supervisor/tests/test_supervisorctl.py
3
@@ -1562,23 +1562,23 @@ class TestDefaultControllerPlugin(unitte
3
@@ -1600,23 +1600,23 @@ class TestDefaultControllerPlugin(unitte
4
         val = plugin.ctl.stdout.getvalue()
4
         val = plugin.ctl.stdout.getvalue()
5
         self.assertTrue(val.startswith('Error: bad argument wrong'), val)
5
         self.assertTrue(val.startswith('Error: bad argument wrong'), val)
6
 
6
 
(-)files/patch-supervisor_options.py (-3 / +3 lines)
Lines 1-5 Link Here
1
--- supervisor/options.py.orig	2016-06-08 17:09:41.213297000 +0300
1
--- supervisor/options.py.orig	2017-07-24 19:48:00 UTC
2
+++ supervisor/options.py	2016-06-08 17:10:18.970354000 +0300
2
+++ supervisor/options.py
3
@@ -96,13 +96,7 @@ class Options:
3
@@ -96,13 +96,7 @@ class Options:
4
         self.add("configfile", None, "c:", "configuration=")
4
         self.add("configfile", None, "c:", "configuration=")
5
 
5
 
Lines 11-17 Link Here
11
-                       '/etc/supervisord.conf',
11
-                       '/etc/supervisord.conf',
12
-                       '/etc/supervisor/supervisord.conf',
12
-                       '/etc/supervisor/supervisord.conf',
13
-                       ]
13
-                       ]
14
+        searchpaths = [ '%%PREFIX%%/etc/supervisord.conf' ]
14
+        searchpaths = [ '/usr/local/etc/supervisord.conf' ]
15
         self.searchpaths = searchpaths
15
         self.searchpaths = searchpaths
16
 
16
 
17
         self.environ_expansions = {}
17
         self.environ_expansions = {}
(-)files/supervisord.conf.sample (-53 / +72 lines)
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

Return to bug 221539