Show More
@@ -0,0 +1,93 b'' | |||||
|
1 | ||||
|
2 | <table id="procList"> | |||
|
3 | <% | |||
|
4 | def get_name(proc): | |||
|
5 | cmd = ' '.join(proc.cmdline()) | |||
|
6 | if 'vcsserver.ini' in cmd: | |||
|
7 | return 'VCSServer' | |||
|
8 | elif 'rhodecode.ini' in cmd: | |||
|
9 | return 'RhodeCode' | |||
|
10 | return proc.name() | |||
|
11 | %> | |||
|
12 | <tr> | |||
|
13 | <td colspan="8"> | |||
|
14 | <span id="processTimeStamp">${h.format_date(h.datetime.now())}</span> | |||
|
15 | </td> | |||
|
16 | </tr> | |||
|
17 | % for proc in c.gunicorn_processes: | |||
|
18 | <% mem = proc.memory_info()%> | |||
|
19 | <% children = proc.children(recursive=True) %> | |||
|
20 | % if children: | |||
|
21 | ||||
|
22 | <tr> | |||
|
23 | <td> | |||
|
24 | <code> | |||
|
25 | ${proc.pid} - ${get_name(proc)} | |||
|
26 | </code> | |||
|
27 | </td> | |||
|
28 | <td> | |||
|
29 | <a href="#showCommand" onclick="$('#pid'+${proc.pid}).toggle();return false"> command </a> | |||
|
30 | <code id="pid${proc.pid}" style="display: none"> | |||
|
31 | ${' '.join(proc.cmdline())} | |||
|
32 | </code> | |||
|
33 | </td> | |||
|
34 | <td></td> | |||
|
35 | <td> | |||
|
36 | RSS:${h.format_byte_size_binary(mem.rss)} | |||
|
37 | </td> | |||
|
38 | <td> | |||
|
39 | VMS:${h.format_byte_size_binary(mem.vms)} | |||
|
40 | </td> | |||
|
41 | <td> | |||
|
42 | AGE: ${h.age_component(h.time_to_utcdatetime(proc.create_time()))} | |||
|
43 | </td> | |||
|
44 | <td> | |||
|
45 | MASTER | |||
|
46 | </td> | |||
|
47 | </tr> | |||
|
48 | <% mem_sum = 0 %> | |||
|
49 | % for proc_child in children: | |||
|
50 | <% mem = proc_child.memory_info()%> | |||
|
51 | <tr> | |||
|
52 | <td> | |||
|
53 | <code> | |||
|
54 | | ${proc_child.pid} - ${get_name(proc_child)} | |||
|
55 | </code> | |||
|
56 | </td> | |||
|
57 | <td> | |||
|
58 | <a href="#showCommand" onclick="$('#pid'+${proc_child.pid}).toggle();return false"> command </a> | |||
|
59 | <code id="pid${proc_child.pid}" style="display: none"> | |||
|
60 | ${' '.join(proc_child.cmdline())} | |||
|
61 | </code> | |||
|
62 | </td> | |||
|
63 | <td> | |||
|
64 | CPU: ${proc_child.cpu_percent()} % | |||
|
65 | </td> | |||
|
66 | <td> | |||
|
67 | RSS:${h.format_byte_size_binary(mem.rss)} | |||
|
68 | <% mem_sum += mem.rss %> | |||
|
69 | </td> | |||
|
70 | <td> | |||
|
71 | VMS:${h.format_byte_size_binary(mem.vms)} | |||
|
72 | </td> | |||
|
73 | <td> | |||
|
74 | AGE: ${h.age_component(h.time_to_utcdatetime(proc_child.create_time()))} | |||
|
75 | </td> | |||
|
76 | <td> | |||
|
77 | <a href="#restartProcess" onclick="restart(this, ${proc_child.pid});return false"> | |||
|
78 | restart | |||
|
79 | </a> | |||
|
80 | </td> | |||
|
81 | </tr> | |||
|
82 | % endfor | |||
|
83 | <tr> | |||
|
84 | <td colspan="2"><code>| total processes: ${len(children)}</code></td> | |||
|
85 | <td></td> | |||
|
86 | <td><strong>RSS:${h.format_byte_size_binary(mem_sum)}</strong></td> | |||
|
87 | <td></td> | |||
|
88 | </tr> | |||
|
89 | <tr><td> <code> -- </code> </td></tr> | |||
|
90 | ||||
|
91 | % endif | |||
|
92 | % endfor | |||
|
93 | </table> |
@@ -1,403 +1,406 b'' | |||||
1 | # -*- coding: utf-8 -*- |
|
1 | # -*- coding: utf-8 -*- | |
2 |
|
2 | |||
3 | # Copyright (C) 2016-2018 RhodeCode GmbH |
|
3 | # Copyright (C) 2016-2018 RhodeCode GmbH | |
4 | # |
|
4 | # | |
5 | # This program is free software: you can redistribute it and/or modify |
|
5 | # This program is free software: you can redistribute it and/or modify | |
6 | # it under the terms of the GNU Affero General Public License, version 3 |
|
6 | # it under the terms of the GNU Affero General Public License, version 3 | |
7 | # (only), as published by the Free Software Foundation. |
|
7 | # (only), as published by the Free Software Foundation. | |
8 | # |
|
8 | # | |
9 | # This program is distributed in the hope that it will be useful, |
|
9 | # This program is distributed in the hope that it will be useful, | |
10 | # but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
10 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | |
11 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
11 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
12 | # GNU General Public License for more details. |
|
12 | # GNU General Public License for more details. | |
13 | # |
|
13 | # | |
14 | # You should have received a copy of the GNU Affero General Public License |
|
14 | # You should have received a copy of the GNU Affero General Public License | |
15 | # along with this program. If not, see <http://www.gnu.org/licenses/>. |
|
15 | # along with this program. If not, see <http://www.gnu.org/licenses/>. | |
16 | # |
|
16 | # | |
17 | # This program is dual-licensed. If you wish to learn more about the |
|
17 | # This program is dual-licensed. If you wish to learn more about the | |
18 | # RhodeCode Enterprise Edition, including its added features, Support services, |
|
18 | # RhodeCode Enterprise Edition, including its added features, Support services, | |
19 | # and proprietary license terms, please see https://rhodecode.com/licenses/ |
|
19 | # and proprietary license terms, please see https://rhodecode.com/licenses/ | |
20 |
|
20 | |||
21 |
|
21 | |||
22 | from rhodecode.apps._base import ADMIN_PREFIX |
|
22 | from rhodecode.apps._base import ADMIN_PREFIX | |
23 |
|
23 | |||
24 |
|
24 | |||
25 | def admin_routes(config): |
|
25 | def admin_routes(config): | |
26 | """ |
|
26 | """ | |
27 | Admin prefixed routes |
|
27 | Admin prefixed routes | |
28 | """ |
|
28 | """ | |
29 |
|
29 | |||
30 | config.add_route( |
|
30 | config.add_route( | |
31 | name='admin_audit_logs', |
|
31 | name='admin_audit_logs', | |
32 | pattern='/audit_logs') |
|
32 | pattern='/audit_logs') | |
33 |
|
33 | |||
34 | config.add_route( |
|
34 | config.add_route( | |
35 | name='admin_audit_log_entry', |
|
35 | name='admin_audit_log_entry', | |
36 | pattern='/audit_logs/{audit_log_id}') |
|
36 | pattern='/audit_logs/{audit_log_id}') | |
37 |
|
37 | |||
38 | config.add_route( |
|
38 | config.add_route( | |
39 | name='pull_requests_global_0', # backward compat |
|
39 | name='pull_requests_global_0', # backward compat | |
40 | pattern='/pull_requests/{pull_request_id:\d+}') |
|
40 | pattern='/pull_requests/{pull_request_id:\d+}') | |
41 | config.add_route( |
|
41 | config.add_route( | |
42 | name='pull_requests_global_1', # backward compat |
|
42 | name='pull_requests_global_1', # backward compat | |
43 | pattern='/pull-requests/{pull_request_id:\d+}') |
|
43 | pattern='/pull-requests/{pull_request_id:\d+}') | |
44 | config.add_route( |
|
44 | config.add_route( | |
45 | name='pull_requests_global', |
|
45 | name='pull_requests_global', | |
46 | pattern='/pull-request/{pull_request_id:\d+}') |
|
46 | pattern='/pull-request/{pull_request_id:\d+}') | |
47 |
|
47 | |||
48 | config.add_route( |
|
48 | config.add_route( | |
49 | name='admin_settings_open_source', |
|
49 | name='admin_settings_open_source', | |
50 | pattern='/settings/open_source') |
|
50 | pattern='/settings/open_source') | |
51 | config.add_route( |
|
51 | config.add_route( | |
52 | name='admin_settings_vcs_svn_generate_cfg', |
|
52 | name='admin_settings_vcs_svn_generate_cfg', | |
53 | pattern='/settings/vcs/svn_generate_cfg') |
|
53 | pattern='/settings/vcs/svn_generate_cfg') | |
54 |
|
54 | |||
55 | config.add_route( |
|
55 | config.add_route( | |
56 | name='admin_settings_system', |
|
56 | name='admin_settings_system', | |
57 | pattern='/settings/system') |
|
57 | pattern='/settings/system') | |
58 | config.add_route( |
|
58 | config.add_route( | |
59 | name='admin_settings_system_update', |
|
59 | name='admin_settings_system_update', | |
60 | pattern='/settings/system/updates') |
|
60 | pattern='/settings/system/updates') | |
61 |
|
61 | |||
62 | config.add_route( |
|
62 | config.add_route( | |
63 | name='admin_settings_sessions', |
|
63 | name='admin_settings_sessions', | |
64 | pattern='/settings/sessions') |
|
64 | pattern='/settings/sessions') | |
65 | config.add_route( |
|
65 | config.add_route( | |
66 | name='admin_settings_sessions_cleanup', |
|
66 | name='admin_settings_sessions_cleanup', | |
67 | pattern='/settings/sessions/cleanup') |
|
67 | pattern='/settings/sessions/cleanup') | |
68 |
|
68 | |||
69 | config.add_route( |
|
69 | config.add_route( | |
70 | name='admin_settings_process_management', |
|
70 | name='admin_settings_process_management', | |
71 | pattern='/settings/process_management') |
|
71 | pattern='/settings/process_management') | |
72 | config.add_route( |
|
72 | config.add_route( | |
|
73 | name='admin_settings_process_management_data', | |||
|
74 | pattern='/settings/process_management/data') | |||
|
75 | config.add_route( | |||
73 | name='admin_settings_process_management_signal', |
|
76 | name='admin_settings_process_management_signal', | |
74 | pattern='/settings/process_management/signal') |
|
77 | pattern='/settings/process_management/signal') | |
75 |
|
78 | |||
76 | # default settings |
|
79 | # default settings | |
77 | config.add_route( |
|
80 | config.add_route( | |
78 | name='admin_defaults_repositories', |
|
81 | name='admin_defaults_repositories', | |
79 | pattern='/defaults/repositories') |
|
82 | pattern='/defaults/repositories') | |
80 | config.add_route( |
|
83 | config.add_route( | |
81 | name='admin_defaults_repositories_update', |
|
84 | name='admin_defaults_repositories_update', | |
82 | pattern='/defaults/repositories/update') |
|
85 | pattern='/defaults/repositories/update') | |
83 |
|
86 | |||
84 | # admin settings |
|
87 | # admin settings | |
85 |
|
88 | |||
86 | config.add_route( |
|
89 | config.add_route( | |
87 | name='admin_settings', |
|
90 | name='admin_settings', | |
88 | pattern='/settings') |
|
91 | pattern='/settings') | |
89 | config.add_route( |
|
92 | config.add_route( | |
90 | name='admin_settings_update', |
|
93 | name='admin_settings_update', | |
91 | pattern='/settings/update') |
|
94 | pattern='/settings/update') | |
92 |
|
95 | |||
93 | config.add_route( |
|
96 | config.add_route( | |
94 | name='admin_settings_global', |
|
97 | name='admin_settings_global', | |
95 | pattern='/settings/global') |
|
98 | pattern='/settings/global') | |
96 | config.add_route( |
|
99 | config.add_route( | |
97 | name='admin_settings_global_update', |
|
100 | name='admin_settings_global_update', | |
98 | pattern='/settings/global/update') |
|
101 | pattern='/settings/global/update') | |
99 |
|
102 | |||
100 | config.add_route( |
|
103 | config.add_route( | |
101 | name='admin_settings_vcs', |
|
104 | name='admin_settings_vcs', | |
102 | pattern='/settings/vcs') |
|
105 | pattern='/settings/vcs') | |
103 | config.add_route( |
|
106 | config.add_route( | |
104 | name='admin_settings_vcs_update', |
|
107 | name='admin_settings_vcs_update', | |
105 | pattern='/settings/vcs/update') |
|
108 | pattern='/settings/vcs/update') | |
106 | config.add_route( |
|
109 | config.add_route( | |
107 | name='admin_settings_vcs_svn_pattern_delete', |
|
110 | name='admin_settings_vcs_svn_pattern_delete', | |
108 | pattern='/settings/vcs/svn_pattern_delete') |
|
111 | pattern='/settings/vcs/svn_pattern_delete') | |
109 |
|
112 | |||
110 | config.add_route( |
|
113 | config.add_route( | |
111 | name='admin_settings_mapping', |
|
114 | name='admin_settings_mapping', | |
112 | pattern='/settings/mapping') |
|
115 | pattern='/settings/mapping') | |
113 | config.add_route( |
|
116 | config.add_route( | |
114 | name='admin_settings_mapping_update', |
|
117 | name='admin_settings_mapping_update', | |
115 | pattern='/settings/mapping/update') |
|
118 | pattern='/settings/mapping/update') | |
116 |
|
119 | |||
117 | config.add_route( |
|
120 | config.add_route( | |
118 | name='admin_settings_visual', |
|
121 | name='admin_settings_visual', | |
119 | pattern='/settings/visual') |
|
122 | pattern='/settings/visual') | |
120 | config.add_route( |
|
123 | config.add_route( | |
121 | name='admin_settings_visual_update', |
|
124 | name='admin_settings_visual_update', | |
122 | pattern='/settings/visual/update') |
|
125 | pattern='/settings/visual/update') | |
123 |
|
126 | |||
124 |
|
127 | |||
125 | config.add_route( |
|
128 | config.add_route( | |
126 | name='admin_settings_issuetracker', |
|
129 | name='admin_settings_issuetracker', | |
127 | pattern='/settings/issue-tracker') |
|
130 | pattern='/settings/issue-tracker') | |
128 | config.add_route( |
|
131 | config.add_route( | |
129 | name='admin_settings_issuetracker_update', |
|
132 | name='admin_settings_issuetracker_update', | |
130 | pattern='/settings/issue-tracker/update') |
|
133 | pattern='/settings/issue-tracker/update') | |
131 | config.add_route( |
|
134 | config.add_route( | |
132 | name='admin_settings_issuetracker_test', |
|
135 | name='admin_settings_issuetracker_test', | |
133 | pattern='/settings/issue-tracker/test') |
|
136 | pattern='/settings/issue-tracker/test') | |
134 | config.add_route( |
|
137 | config.add_route( | |
135 | name='admin_settings_issuetracker_delete', |
|
138 | name='admin_settings_issuetracker_delete', | |
136 | pattern='/settings/issue-tracker/delete') |
|
139 | pattern='/settings/issue-tracker/delete') | |
137 |
|
140 | |||
138 | config.add_route( |
|
141 | config.add_route( | |
139 | name='admin_settings_email', |
|
142 | name='admin_settings_email', | |
140 | pattern='/settings/email') |
|
143 | pattern='/settings/email') | |
141 | config.add_route( |
|
144 | config.add_route( | |
142 | name='admin_settings_email_update', |
|
145 | name='admin_settings_email_update', | |
143 | pattern='/settings/email/update') |
|
146 | pattern='/settings/email/update') | |
144 |
|
147 | |||
145 | config.add_route( |
|
148 | config.add_route( | |
146 | name='admin_settings_hooks', |
|
149 | name='admin_settings_hooks', | |
147 | pattern='/settings/hooks') |
|
150 | pattern='/settings/hooks') | |
148 | config.add_route( |
|
151 | config.add_route( | |
149 | name='admin_settings_hooks_update', |
|
152 | name='admin_settings_hooks_update', | |
150 | pattern='/settings/hooks/update') |
|
153 | pattern='/settings/hooks/update') | |
151 | config.add_route( |
|
154 | config.add_route( | |
152 | name='admin_settings_hooks_delete', |
|
155 | name='admin_settings_hooks_delete', | |
153 | pattern='/settings/hooks/delete') |
|
156 | pattern='/settings/hooks/delete') | |
154 |
|
157 | |||
155 | config.add_route( |
|
158 | config.add_route( | |
156 | name='admin_settings_search', |
|
159 | name='admin_settings_search', | |
157 | pattern='/settings/search') |
|
160 | pattern='/settings/search') | |
158 |
|
161 | |||
159 | config.add_route( |
|
162 | config.add_route( | |
160 | name='admin_settings_labs', |
|
163 | name='admin_settings_labs', | |
161 | pattern='/settings/labs') |
|
164 | pattern='/settings/labs') | |
162 | config.add_route( |
|
165 | config.add_route( | |
163 | name='admin_settings_labs_update', |
|
166 | name='admin_settings_labs_update', | |
164 | pattern='/settings/labs/update') |
|
167 | pattern='/settings/labs/update') | |
165 |
|
168 | |||
166 | # global permissions |
|
169 | # global permissions | |
167 |
|
170 | |||
168 | config.add_route( |
|
171 | config.add_route( | |
169 | name='admin_permissions_application', |
|
172 | name='admin_permissions_application', | |
170 | pattern='/permissions/application') |
|
173 | pattern='/permissions/application') | |
171 | config.add_route( |
|
174 | config.add_route( | |
172 | name='admin_permissions_application_update', |
|
175 | name='admin_permissions_application_update', | |
173 | pattern='/permissions/application/update') |
|
176 | pattern='/permissions/application/update') | |
174 |
|
177 | |||
175 | config.add_route( |
|
178 | config.add_route( | |
176 | name='admin_permissions_global', |
|
179 | name='admin_permissions_global', | |
177 | pattern='/permissions/global') |
|
180 | pattern='/permissions/global') | |
178 | config.add_route( |
|
181 | config.add_route( | |
179 | name='admin_permissions_global_update', |
|
182 | name='admin_permissions_global_update', | |
180 | pattern='/permissions/global/update') |
|
183 | pattern='/permissions/global/update') | |
181 |
|
184 | |||
182 | config.add_route( |
|
185 | config.add_route( | |
183 | name='admin_permissions_object', |
|
186 | name='admin_permissions_object', | |
184 | pattern='/permissions/object') |
|
187 | pattern='/permissions/object') | |
185 | config.add_route( |
|
188 | config.add_route( | |
186 | name='admin_permissions_object_update', |
|
189 | name='admin_permissions_object_update', | |
187 | pattern='/permissions/object/update') |
|
190 | pattern='/permissions/object/update') | |
188 |
|
191 | |||
189 | config.add_route( |
|
192 | config.add_route( | |
190 | name='admin_permissions_ips', |
|
193 | name='admin_permissions_ips', | |
191 | pattern='/permissions/ips') |
|
194 | pattern='/permissions/ips') | |
192 |
|
195 | |||
193 | config.add_route( |
|
196 | config.add_route( | |
194 | name='admin_permissions_overview', |
|
197 | name='admin_permissions_overview', | |
195 | pattern='/permissions/overview') |
|
198 | pattern='/permissions/overview') | |
196 |
|
199 | |||
197 | config.add_route( |
|
200 | config.add_route( | |
198 | name='admin_permissions_auth_token_access', |
|
201 | name='admin_permissions_auth_token_access', | |
199 | pattern='/permissions/auth_token_access') |
|
202 | pattern='/permissions/auth_token_access') | |
200 |
|
203 | |||
201 | config.add_route( |
|
204 | config.add_route( | |
202 | name='admin_permissions_ssh_keys', |
|
205 | name='admin_permissions_ssh_keys', | |
203 | pattern='/permissions/ssh_keys') |
|
206 | pattern='/permissions/ssh_keys') | |
204 | config.add_route( |
|
207 | config.add_route( | |
205 | name='admin_permissions_ssh_keys_data', |
|
208 | name='admin_permissions_ssh_keys_data', | |
206 | pattern='/permissions/ssh_keys/data') |
|
209 | pattern='/permissions/ssh_keys/data') | |
207 | config.add_route( |
|
210 | config.add_route( | |
208 | name='admin_permissions_ssh_keys_update', |
|
211 | name='admin_permissions_ssh_keys_update', | |
209 | pattern='/permissions/ssh_keys/update') |
|
212 | pattern='/permissions/ssh_keys/update') | |
210 |
|
213 | |||
211 | # users admin |
|
214 | # users admin | |
212 | config.add_route( |
|
215 | config.add_route( | |
213 | name='users', |
|
216 | name='users', | |
214 | pattern='/users') |
|
217 | pattern='/users') | |
215 |
|
218 | |||
216 | config.add_route( |
|
219 | config.add_route( | |
217 | name='users_data', |
|
220 | name='users_data', | |
218 | pattern='/users_data') |
|
221 | pattern='/users_data') | |
219 |
|
222 | |||
220 | config.add_route( |
|
223 | config.add_route( | |
221 | name='users_create', |
|
224 | name='users_create', | |
222 | pattern='/users/create') |
|
225 | pattern='/users/create') | |
223 |
|
226 | |||
224 | config.add_route( |
|
227 | config.add_route( | |
225 | name='users_new', |
|
228 | name='users_new', | |
226 | pattern='/users/new') |
|
229 | pattern='/users/new') | |
227 |
|
230 | |||
228 | # user management |
|
231 | # user management | |
229 | config.add_route( |
|
232 | config.add_route( | |
230 | name='user_edit', |
|
233 | name='user_edit', | |
231 | pattern='/users/{user_id:\d+}/edit', |
|
234 | pattern='/users/{user_id:\d+}/edit', | |
232 | user_route=True) |
|
235 | user_route=True) | |
233 | config.add_route( |
|
236 | config.add_route( | |
234 | name='user_edit_advanced', |
|
237 | name='user_edit_advanced', | |
235 | pattern='/users/{user_id:\d+}/edit/advanced', |
|
238 | pattern='/users/{user_id:\d+}/edit/advanced', | |
236 | user_route=True) |
|
239 | user_route=True) | |
237 | config.add_route( |
|
240 | config.add_route( | |
238 | name='user_edit_global_perms', |
|
241 | name='user_edit_global_perms', | |
239 | pattern='/users/{user_id:\d+}/edit/global_permissions', |
|
242 | pattern='/users/{user_id:\d+}/edit/global_permissions', | |
240 | user_route=True) |
|
243 | user_route=True) | |
241 | config.add_route( |
|
244 | config.add_route( | |
242 | name='user_edit_global_perms_update', |
|
245 | name='user_edit_global_perms_update', | |
243 | pattern='/users/{user_id:\d+}/edit/global_permissions/update', |
|
246 | pattern='/users/{user_id:\d+}/edit/global_permissions/update', | |
244 | user_route=True) |
|
247 | user_route=True) | |
245 | config.add_route( |
|
248 | config.add_route( | |
246 | name='user_update', |
|
249 | name='user_update', | |
247 | pattern='/users/{user_id:\d+}/update', |
|
250 | pattern='/users/{user_id:\d+}/update', | |
248 | user_route=True) |
|
251 | user_route=True) | |
249 | config.add_route( |
|
252 | config.add_route( | |
250 | name='user_delete', |
|
253 | name='user_delete', | |
251 | pattern='/users/{user_id:\d+}/delete', |
|
254 | pattern='/users/{user_id:\d+}/delete', | |
252 | user_route=True) |
|
255 | user_route=True) | |
253 | config.add_route( |
|
256 | config.add_route( | |
254 | name='user_force_password_reset', |
|
257 | name='user_force_password_reset', | |
255 | pattern='/users/{user_id:\d+}/password_reset', |
|
258 | pattern='/users/{user_id:\d+}/password_reset', | |
256 | user_route=True) |
|
259 | user_route=True) | |
257 | config.add_route( |
|
260 | config.add_route( | |
258 | name='user_create_personal_repo_group', |
|
261 | name='user_create_personal_repo_group', | |
259 | pattern='/users/{user_id:\d+}/create_repo_group', |
|
262 | pattern='/users/{user_id:\d+}/create_repo_group', | |
260 | user_route=True) |
|
263 | user_route=True) | |
261 |
|
264 | |||
262 | # user auth tokens |
|
265 | # user auth tokens | |
263 | config.add_route( |
|
266 | config.add_route( | |
264 | name='edit_user_auth_tokens', |
|
267 | name='edit_user_auth_tokens', | |
265 | pattern='/users/{user_id:\d+}/edit/auth_tokens', |
|
268 | pattern='/users/{user_id:\d+}/edit/auth_tokens', | |
266 | user_route=True) |
|
269 | user_route=True) | |
267 | config.add_route( |
|
270 | config.add_route( | |
268 | name='edit_user_auth_tokens_add', |
|
271 | name='edit_user_auth_tokens_add', | |
269 | pattern='/users/{user_id:\d+}/edit/auth_tokens/new', |
|
272 | pattern='/users/{user_id:\d+}/edit/auth_tokens/new', | |
270 | user_route=True) |
|
273 | user_route=True) | |
271 | config.add_route( |
|
274 | config.add_route( | |
272 | name='edit_user_auth_tokens_delete', |
|
275 | name='edit_user_auth_tokens_delete', | |
273 | pattern='/users/{user_id:\d+}/edit/auth_tokens/delete', |
|
276 | pattern='/users/{user_id:\d+}/edit/auth_tokens/delete', | |
274 | user_route=True) |
|
277 | user_route=True) | |
275 |
|
278 | |||
276 | # user ssh keys |
|
279 | # user ssh keys | |
277 | config.add_route( |
|
280 | config.add_route( | |
278 | name='edit_user_ssh_keys', |
|
281 | name='edit_user_ssh_keys', | |
279 | pattern='/users/{user_id:\d+}/edit/ssh_keys', |
|
282 | pattern='/users/{user_id:\d+}/edit/ssh_keys', | |
280 | user_route=True) |
|
283 | user_route=True) | |
281 | config.add_route( |
|
284 | config.add_route( | |
282 | name='edit_user_ssh_keys_generate_keypair', |
|
285 | name='edit_user_ssh_keys_generate_keypair', | |
283 | pattern='/users/{user_id:\d+}/edit/ssh_keys/generate', |
|
286 | pattern='/users/{user_id:\d+}/edit/ssh_keys/generate', | |
284 | user_route=True) |
|
287 | user_route=True) | |
285 | config.add_route( |
|
288 | config.add_route( | |
286 | name='edit_user_ssh_keys_add', |
|
289 | name='edit_user_ssh_keys_add', | |
287 | pattern='/users/{user_id:\d+}/edit/ssh_keys/new', |
|
290 | pattern='/users/{user_id:\d+}/edit/ssh_keys/new', | |
288 | user_route=True) |
|
291 | user_route=True) | |
289 | config.add_route( |
|
292 | config.add_route( | |
290 | name='edit_user_ssh_keys_delete', |
|
293 | name='edit_user_ssh_keys_delete', | |
291 | pattern='/users/{user_id:\d+}/edit/ssh_keys/delete', |
|
294 | pattern='/users/{user_id:\d+}/edit/ssh_keys/delete', | |
292 | user_route=True) |
|
295 | user_route=True) | |
293 |
|
296 | |||
294 | # user emails |
|
297 | # user emails | |
295 | config.add_route( |
|
298 | config.add_route( | |
296 | name='edit_user_emails', |
|
299 | name='edit_user_emails', | |
297 | pattern='/users/{user_id:\d+}/edit/emails', |
|
300 | pattern='/users/{user_id:\d+}/edit/emails', | |
298 | user_route=True) |
|
301 | user_route=True) | |
299 | config.add_route( |
|
302 | config.add_route( | |
300 | name='edit_user_emails_add', |
|
303 | name='edit_user_emails_add', | |
301 | pattern='/users/{user_id:\d+}/edit/emails/new', |
|
304 | pattern='/users/{user_id:\d+}/edit/emails/new', | |
302 | user_route=True) |
|
305 | user_route=True) | |
303 | config.add_route( |
|
306 | config.add_route( | |
304 | name='edit_user_emails_delete', |
|
307 | name='edit_user_emails_delete', | |
305 | pattern='/users/{user_id:\d+}/edit/emails/delete', |
|
308 | pattern='/users/{user_id:\d+}/edit/emails/delete', | |
306 | user_route=True) |
|
309 | user_route=True) | |
307 |
|
310 | |||
308 | # user IPs |
|
311 | # user IPs | |
309 | config.add_route( |
|
312 | config.add_route( | |
310 | name='edit_user_ips', |
|
313 | name='edit_user_ips', | |
311 | pattern='/users/{user_id:\d+}/edit/ips', |
|
314 | pattern='/users/{user_id:\d+}/edit/ips', | |
312 | user_route=True) |
|
315 | user_route=True) | |
313 | config.add_route( |
|
316 | config.add_route( | |
314 | name='edit_user_ips_add', |
|
317 | name='edit_user_ips_add', | |
315 | pattern='/users/{user_id:\d+}/edit/ips/new', |
|
318 | pattern='/users/{user_id:\d+}/edit/ips/new', | |
316 | user_route_with_default=True) # enabled for default user too |
|
319 | user_route_with_default=True) # enabled for default user too | |
317 | config.add_route( |
|
320 | config.add_route( | |
318 | name='edit_user_ips_delete', |
|
321 | name='edit_user_ips_delete', | |
319 | pattern='/users/{user_id:\d+}/edit/ips/delete', |
|
322 | pattern='/users/{user_id:\d+}/edit/ips/delete', | |
320 | user_route_with_default=True) # enabled for default user too |
|
323 | user_route_with_default=True) # enabled for default user too | |
321 |
|
324 | |||
322 | # user perms |
|
325 | # user perms | |
323 | config.add_route( |
|
326 | config.add_route( | |
324 | name='edit_user_perms_summary', |
|
327 | name='edit_user_perms_summary', | |
325 | pattern='/users/{user_id:\d+}/edit/permissions_summary', |
|
328 | pattern='/users/{user_id:\d+}/edit/permissions_summary', | |
326 | user_route=True) |
|
329 | user_route=True) | |
327 | config.add_route( |
|
330 | config.add_route( | |
328 | name='edit_user_perms_summary_json', |
|
331 | name='edit_user_perms_summary_json', | |
329 | pattern='/users/{user_id:\d+}/edit/permissions_summary/json', |
|
332 | pattern='/users/{user_id:\d+}/edit/permissions_summary/json', | |
330 | user_route=True) |
|
333 | user_route=True) | |
331 |
|
334 | |||
332 | # user user groups management |
|
335 | # user user groups management | |
333 | config.add_route( |
|
336 | config.add_route( | |
334 | name='edit_user_groups_management', |
|
337 | name='edit_user_groups_management', | |
335 | pattern='/users/{user_id:\d+}/edit/groups_management', |
|
338 | pattern='/users/{user_id:\d+}/edit/groups_management', | |
336 | user_route=True) |
|
339 | user_route=True) | |
337 |
|
340 | |||
338 | config.add_route( |
|
341 | config.add_route( | |
339 | name='edit_user_groups_management_updates', |
|
342 | name='edit_user_groups_management_updates', | |
340 | pattern='/users/{user_id:\d+}/edit/edit_user_groups_management/updates', |
|
343 | pattern='/users/{user_id:\d+}/edit/edit_user_groups_management/updates', | |
341 | user_route=True) |
|
344 | user_route=True) | |
342 |
|
345 | |||
343 | # user audit logs |
|
346 | # user audit logs | |
344 | config.add_route( |
|
347 | config.add_route( | |
345 | name='edit_user_audit_logs', |
|
348 | name='edit_user_audit_logs', | |
346 | pattern='/users/{user_id:\d+}/edit/audit', user_route=True) |
|
349 | pattern='/users/{user_id:\d+}/edit/audit', user_route=True) | |
347 |
|
350 | |||
348 | # user-groups admin |
|
351 | # user-groups admin | |
349 | config.add_route( |
|
352 | config.add_route( | |
350 | name='user_groups', |
|
353 | name='user_groups', | |
351 | pattern='/user_groups') |
|
354 | pattern='/user_groups') | |
352 |
|
355 | |||
353 | config.add_route( |
|
356 | config.add_route( | |
354 | name='user_groups_data', |
|
357 | name='user_groups_data', | |
355 | pattern='/user_groups_data') |
|
358 | pattern='/user_groups_data') | |
356 |
|
359 | |||
357 | config.add_route( |
|
360 | config.add_route( | |
358 | name='user_groups_new', |
|
361 | name='user_groups_new', | |
359 | pattern='/user_groups/new') |
|
362 | pattern='/user_groups/new') | |
360 |
|
363 | |||
361 | config.add_route( |
|
364 | config.add_route( | |
362 | name='user_groups_create', |
|
365 | name='user_groups_create', | |
363 | pattern='/user_groups/create') |
|
366 | pattern='/user_groups/create') | |
364 |
|
367 | |||
365 | # repos admin |
|
368 | # repos admin | |
366 | config.add_route( |
|
369 | config.add_route( | |
367 | name='repos', |
|
370 | name='repos', | |
368 | pattern='/repos') |
|
371 | pattern='/repos') | |
369 |
|
372 | |||
370 | config.add_route( |
|
373 | config.add_route( | |
371 | name='repo_new', |
|
374 | name='repo_new', | |
372 | pattern='/repos/new') |
|
375 | pattern='/repos/new') | |
373 |
|
376 | |||
374 | config.add_route( |
|
377 | config.add_route( | |
375 | name='repo_create', |
|
378 | name='repo_create', | |
376 | pattern='/repos/create') |
|
379 | pattern='/repos/create') | |
377 |
|
380 | |||
378 | # repo groups admin |
|
381 | # repo groups admin | |
379 | config.add_route( |
|
382 | config.add_route( | |
380 | name='repo_groups', |
|
383 | name='repo_groups', | |
381 | pattern='/repo_groups') |
|
384 | pattern='/repo_groups') | |
382 |
|
385 | |||
383 | config.add_route( |
|
386 | config.add_route( | |
384 | name='repo_group_new', |
|
387 | name='repo_group_new', | |
385 | pattern='/repo_group/new') |
|
388 | pattern='/repo_group/new') | |
386 |
|
389 | |||
387 | config.add_route( |
|
390 | config.add_route( | |
388 | name='repo_group_create', |
|
391 | name='repo_group_create', | |
389 | pattern='/repo_group/create') |
|
392 | pattern='/repo_group/create') | |
390 |
|
393 | |||
391 |
|
394 | |||
392 | def includeme(config): |
|
395 | def includeme(config): | |
393 | from rhodecode.apps.admin.navigation import includeme as nav_includeme |
|
396 | from rhodecode.apps.admin.navigation import includeme as nav_includeme | |
394 |
|
397 | |||
395 | # Create admin navigation registry and add it to the pyramid registry. |
|
398 | # Create admin navigation registry and add it to the pyramid registry. | |
396 | nav_includeme(config) |
|
399 | nav_includeme(config) | |
397 |
|
400 | |||
398 | # main admin routes |
|
401 | # main admin routes | |
399 | config.add_route(name='admin_home', pattern=ADMIN_PREFIX) |
|
402 | config.add_route(name='admin_home', pattern=ADMIN_PREFIX) | |
400 | config.include(admin_routes, route_prefix=ADMIN_PREFIX) |
|
403 | config.include(admin_routes, route_prefix=ADMIN_PREFIX) | |
401 |
|
404 | |||
402 | # Scan module for configuration decorators. |
|
405 | # Scan module for configuration decorators. | |
403 | config.scan('.views', ignore='.tests') |
|
406 | config.scan('.views', ignore='.tests') |
@@ -1,91 +1,103 b'' | |||||
1 | # -*- coding: utf-8 -*- |
|
1 | # -*- coding: utf-8 -*- | |
2 |
|
2 | |||
3 | # Copyright (C) 2016-2018 RhodeCode GmbH |
|
3 | # Copyright (C) 2016-2018 RhodeCode GmbH | |
4 | # |
|
4 | # | |
5 | # This program is free software: you can redistribute it and/or modify |
|
5 | # This program is free software: you can redistribute it and/or modify | |
6 | # it under the terms of the GNU Affero General Public License, version 3 |
|
6 | # it under the terms of the GNU Affero General Public License, version 3 | |
7 | # (only), as published by the Free Software Foundation. |
|
7 | # (only), as published by the Free Software Foundation. | |
8 | # |
|
8 | # | |
9 | # This program is distributed in the hope that it will be useful, |
|
9 | # This program is distributed in the hope that it will be useful, | |
10 | # but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
10 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | |
11 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
11 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
12 | # GNU General Public License for more details. |
|
12 | # GNU General Public License for more details. | |
13 | # |
|
13 | # | |
14 | # You should have received a copy of the GNU Affero General Public License |
|
14 | # You should have received a copy of the GNU Affero General Public License | |
15 | # along with this program. If not, see <http://www.gnu.org/licenses/>. |
|
15 | # along with this program. If not, see <http://www.gnu.org/licenses/>. | |
16 | # |
|
16 | # | |
17 | # This program is dual-licensed. If you wish to learn more about the |
|
17 | # This program is dual-licensed. If you wish to learn more about the | |
18 | # RhodeCode Enterprise Edition, including its added features, Support services, |
|
18 | # RhodeCode Enterprise Edition, including its added features, Support services, | |
19 | # and proprietary license terms, please see https://rhodecode.com/licenses/ |
|
19 | # and proprietary license terms, please see https://rhodecode.com/licenses/ | |
20 |
|
20 | |||
21 | import logging |
|
21 | import logging | |
22 |
|
22 | |||
23 | import psutil |
|
23 | import psutil | |
24 | from pyramid.view import view_config |
|
24 | from pyramid.view import view_config | |
25 |
|
25 | |||
26 | from rhodecode.apps._base import BaseAppView |
|
26 | from rhodecode.apps._base import BaseAppView | |
27 | from rhodecode.apps.admin.navigation import navigation_list |
|
27 | from rhodecode.apps.admin.navigation import navigation_list | |
28 | from rhodecode.lib.auth import ( |
|
28 | from rhodecode.lib.auth import ( | |
29 | LoginRequired, HasPermissionAllDecorator, CSRFRequired) |
|
29 | LoginRequired, HasPermissionAllDecorator, CSRFRequired) | |
30 | from rhodecode.lib.utils2 import safe_int |
|
30 | from rhodecode.lib.utils2 import safe_int | |
31 |
|
31 | |||
32 | log = logging.getLogger(__name__) |
|
32 | log = logging.getLogger(__name__) | |
33 |
|
33 | |||
34 |
|
34 | |||
35 | class AdminProcessManagementView(BaseAppView): |
|
35 | class AdminProcessManagementView(BaseAppView): | |
36 | def load_default_context(self): |
|
36 | def load_default_context(self): | |
37 | c = self._get_local_tmpl_context() |
|
37 | c = self._get_local_tmpl_context() | |
38 |
|
38 | |||
39 | return c |
|
39 | return c | |
40 |
|
40 | |||
41 | @LoginRequired() |
|
41 | @LoginRequired() | |
42 | @HasPermissionAllDecorator('hg.admin') |
|
42 | @HasPermissionAllDecorator('hg.admin') | |
43 | @view_config( |
|
43 | @view_config( | |
44 | route_name='admin_settings_process_management', request_method='GET', |
|
44 | route_name='admin_settings_process_management', request_method='GET', | |
45 | renderer='rhodecode:templates/admin/settings/settings.mako') |
|
45 | renderer='rhodecode:templates/admin/settings/settings.mako') | |
46 | def process_management(self): |
|
46 | def process_management(self): | |
47 | _ = self.request.translate |
|
47 | _ = self.request.translate | |
48 | c = self.load_default_context() |
|
48 | c = self.load_default_context() | |
49 |
|
49 | |||
50 | c.active = 'process_management' |
|
50 | c.active = 'process_management' | |
51 | c.navlist = navigation_list(self.request) |
|
51 | c.navlist = navigation_list(self.request) | |
52 | c.gunicorn_processes = ( |
|
52 | c.gunicorn_processes = ( | |
53 | p for p in psutil.process_iter() if 'gunicorn' in p.name()) |
|
53 | p for p in psutil.process_iter() if 'gunicorn' in p.name()) | |
54 | return self._get_template_context(c) |
|
54 | return self._get_template_context(c) | |
55 |
|
55 | |||
56 | @LoginRequired() |
|
56 | @LoginRequired() | |
57 | @HasPermissionAllDecorator('hg.admin') |
|
57 | @HasPermissionAllDecorator('hg.admin') | |
|
58 | @view_config( | |||
|
59 | route_name='admin_settings_process_management_data', request_method='GET', | |||
|
60 | renderer='rhodecode:templates/admin/settings/settings_process_management_data.mako') | |||
|
61 | def process_management_data(self): | |||
|
62 | _ = self.request.translate | |||
|
63 | c = self.load_default_context() | |||
|
64 | c.gunicorn_processes = ( | |||
|
65 | p for p in psutil.process_iter() if 'gunicorn' in p.name()) | |||
|
66 | return self._get_template_context(c) | |||
|
67 | ||||
|
68 | @LoginRequired() | |||
|
69 | @HasPermissionAllDecorator('hg.admin') | |||
58 | @CSRFRequired() |
|
70 | @CSRFRequired() | |
59 | @view_config( |
|
71 | @view_config( | |
60 | route_name='admin_settings_process_management_signal', |
|
72 | route_name='admin_settings_process_management_signal', | |
61 | request_method='POST', renderer='json_ext') |
|
73 | request_method='POST', renderer='json_ext') | |
62 | def process_management_signal(self): |
|
74 | def process_management_signal(self): | |
63 | pids = self.request.json.get('pids', []) |
|
75 | pids = self.request.json.get('pids', []) | |
64 | result = [] |
|
76 | result = [] | |
65 | def on_terminate(proc): |
|
77 | def on_terminate(proc): | |
66 | msg = "process `PID:{}` terminated with exit code {}".format( |
|
78 | msg = "process `PID:{}` terminated with exit code {}".format( | |
67 | proc.pid, proc.returncode) |
|
79 | proc.pid, proc.returncode) | |
68 | result.append(msg) |
|
80 | result.append(msg) | |
69 |
|
81 | |||
70 | procs = [] |
|
82 | procs = [] | |
71 | for pid in pids: |
|
83 | for pid in pids: | |
72 | pid = safe_int(pid) |
|
84 | pid = safe_int(pid) | |
73 | if pid: |
|
85 | if pid: | |
74 | try: |
|
86 | try: | |
75 | proc = psutil.Process(pid) |
|
87 | proc = psutil.Process(pid) | |
76 | except psutil.NoSuchProcess: |
|
88 | except psutil.NoSuchProcess: | |
77 | continue |
|
89 | continue | |
78 |
|
90 | |||
79 | children = proc.children(recursive=True) |
|
91 | children = proc.children(recursive=True) | |
80 | if children: |
|
92 | if children: | |
81 | print('Wont kill Master Process') |
|
93 | print('Wont kill Master Process') | |
82 | else: |
|
94 | else: | |
83 | procs.append(proc) |
|
95 | procs.append(proc) | |
84 |
|
96 | |||
85 | for p in procs: |
|
97 | for p in procs: | |
86 | p.terminate() |
|
98 | p.terminate() | |
87 | gone, alive = psutil.wait_procs(procs, timeout=10, callback=on_terminate) |
|
99 | gone, alive = psutil.wait_procs(procs, timeout=10, callback=on_terminate) | |
88 | for p in alive: |
|
100 | for p in alive: | |
89 | p.kill() |
|
101 | p.kill() | |
90 |
|
102 | |||
91 | return {'result': result} |
|
103 | return {'result': result} |
@@ -1,316 +1,318 b'' | |||||
1 |
|
1 | |||
2 | /****************************************************************************** |
|
2 | /****************************************************************************** | |
3 | * * |
|
3 | * * | |
4 | * DO NOT CHANGE THIS FILE MANUALLY * |
|
4 | * DO NOT CHANGE THIS FILE MANUALLY * | |
5 | * * |
|
5 | * * | |
6 | * * |
|
6 | * * | |
7 | * This file is automatically generated when the app starts up with * |
|
7 | * This file is automatically generated when the app starts up with * | |
8 | * generate_js_files = true * |
|
8 | * generate_js_files = true * | |
9 | * * |
|
9 | * * | |
10 | * To add a route here pass jsroute=True to the route definition in the app * |
|
10 | * To add a route here pass jsroute=True to the route definition in the app * | |
11 | * * |
|
11 | * * | |
12 | ******************************************************************************/ |
|
12 | ******************************************************************************/ | |
13 | function registerRCRoutes() { |
|
13 | function registerRCRoutes() { | |
14 | // routes registration |
|
14 | // routes registration | |
15 | pyroutes.register('favicon', '/favicon.ico', []); |
|
15 | pyroutes.register('favicon', '/favicon.ico', []); | |
16 | pyroutes.register('robots', '/robots.txt', []); |
|
16 | pyroutes.register('robots', '/robots.txt', []); | |
17 | pyroutes.register('auth_home', '/_admin/auth*traverse', []); |
|
17 | pyroutes.register('auth_home', '/_admin/auth*traverse', []); | |
18 | pyroutes.register('global_integrations_new', '/_admin/integrations/new', []); |
|
18 | pyroutes.register('global_integrations_new', '/_admin/integrations/new', []); | |
19 | pyroutes.register('global_integrations_home', '/_admin/integrations', []); |
|
19 | pyroutes.register('global_integrations_home', '/_admin/integrations', []); | |
20 | pyroutes.register('global_integrations_list', '/_admin/integrations/%(integration)s', ['integration']); |
|
20 | pyroutes.register('global_integrations_list', '/_admin/integrations/%(integration)s', ['integration']); | |
21 | pyroutes.register('global_integrations_create', '/_admin/integrations/%(integration)s/new', ['integration']); |
|
21 | pyroutes.register('global_integrations_create', '/_admin/integrations/%(integration)s/new', ['integration']); | |
22 | pyroutes.register('global_integrations_edit', '/_admin/integrations/%(integration)s/%(integration_id)s', ['integration', 'integration_id']); |
|
22 | pyroutes.register('global_integrations_edit', '/_admin/integrations/%(integration)s/%(integration_id)s', ['integration', 'integration_id']); | |
23 | pyroutes.register('repo_group_integrations_home', '/%(repo_group_name)s/_settings/integrations', ['repo_group_name']); |
|
23 | pyroutes.register('repo_group_integrations_home', '/%(repo_group_name)s/_settings/integrations', ['repo_group_name']); | |
24 | pyroutes.register('repo_group_integrations_new', '/%(repo_group_name)s/_settings/integrations/new', ['repo_group_name']); |
|
24 | pyroutes.register('repo_group_integrations_new', '/%(repo_group_name)s/_settings/integrations/new', ['repo_group_name']); | |
25 | pyroutes.register('repo_group_integrations_list', '/%(repo_group_name)s/_settings/integrations/%(integration)s', ['repo_group_name', 'integration']); |
|
25 | pyroutes.register('repo_group_integrations_list', '/%(repo_group_name)s/_settings/integrations/%(integration)s', ['repo_group_name', 'integration']); | |
26 | pyroutes.register('repo_group_integrations_create', '/%(repo_group_name)s/_settings/integrations/%(integration)s/new', ['repo_group_name', 'integration']); |
|
26 | pyroutes.register('repo_group_integrations_create', '/%(repo_group_name)s/_settings/integrations/%(integration)s/new', ['repo_group_name', 'integration']); | |
27 | pyroutes.register('repo_group_integrations_edit', '/%(repo_group_name)s/_settings/integrations/%(integration)s/%(integration_id)s', ['repo_group_name', 'integration', 'integration_id']); |
|
27 | pyroutes.register('repo_group_integrations_edit', '/%(repo_group_name)s/_settings/integrations/%(integration)s/%(integration_id)s', ['repo_group_name', 'integration', 'integration_id']); | |
28 | pyroutes.register('repo_integrations_home', '/%(repo_name)s/settings/integrations', ['repo_name']); |
|
28 | pyroutes.register('repo_integrations_home', '/%(repo_name)s/settings/integrations', ['repo_name']); | |
29 | pyroutes.register('repo_integrations_new', '/%(repo_name)s/settings/integrations/new', ['repo_name']); |
|
29 | pyroutes.register('repo_integrations_new', '/%(repo_name)s/settings/integrations/new', ['repo_name']); | |
30 | pyroutes.register('repo_integrations_list', '/%(repo_name)s/settings/integrations/%(integration)s', ['repo_name', 'integration']); |
|
30 | pyroutes.register('repo_integrations_list', '/%(repo_name)s/settings/integrations/%(integration)s', ['repo_name', 'integration']); | |
31 | pyroutes.register('repo_integrations_create', '/%(repo_name)s/settings/integrations/%(integration)s/new', ['repo_name', 'integration']); |
|
31 | pyroutes.register('repo_integrations_create', '/%(repo_name)s/settings/integrations/%(integration)s/new', ['repo_name', 'integration']); | |
32 | pyroutes.register('repo_integrations_edit', '/%(repo_name)s/settings/integrations/%(integration)s/%(integration_id)s', ['repo_name', 'integration', 'integration_id']); |
|
32 | pyroutes.register('repo_integrations_edit', '/%(repo_name)s/settings/integrations/%(integration)s/%(integration_id)s', ['repo_name', 'integration', 'integration_id']); | |
33 | pyroutes.register('ops_ping', '/_admin/ops/ping', []); |
|
33 | pyroutes.register('ops_ping', '/_admin/ops/ping', []); | |
34 | pyroutes.register('ops_error_test', '/_admin/ops/error', []); |
|
34 | pyroutes.register('ops_error_test', '/_admin/ops/error', []); | |
35 | pyroutes.register('ops_redirect_test', '/_admin/ops/redirect', []); |
|
35 | pyroutes.register('ops_redirect_test', '/_admin/ops/redirect', []); | |
36 | pyroutes.register('ops_ping_legacy', '/_admin/ping', []); |
|
36 | pyroutes.register('ops_ping_legacy', '/_admin/ping', []); | |
37 | pyroutes.register('ops_error_test_legacy', '/_admin/error_test', []); |
|
37 | pyroutes.register('ops_error_test_legacy', '/_admin/error_test', []); | |
38 | pyroutes.register('admin_home', '/_admin', []); |
|
38 | pyroutes.register('admin_home', '/_admin', []); | |
39 | pyroutes.register('admin_audit_logs', '/_admin/audit_logs', []); |
|
39 | pyroutes.register('admin_audit_logs', '/_admin/audit_logs', []); | |
40 | pyroutes.register('admin_audit_log_entry', '/_admin/audit_logs/%(audit_log_id)s', ['audit_log_id']); |
|
40 | pyroutes.register('admin_audit_log_entry', '/_admin/audit_logs/%(audit_log_id)s', ['audit_log_id']); | |
41 | pyroutes.register('pull_requests_global_0', '/_admin/pull_requests/%(pull_request_id)s', ['pull_request_id']); |
|
41 | pyroutes.register('pull_requests_global_0', '/_admin/pull_requests/%(pull_request_id)s', ['pull_request_id']); | |
42 | pyroutes.register('pull_requests_global_1', '/_admin/pull-requests/%(pull_request_id)s', ['pull_request_id']); |
|
42 | pyroutes.register('pull_requests_global_1', '/_admin/pull-requests/%(pull_request_id)s', ['pull_request_id']); | |
43 | pyroutes.register('pull_requests_global', '/_admin/pull-request/%(pull_request_id)s', ['pull_request_id']); |
|
43 | pyroutes.register('pull_requests_global', '/_admin/pull-request/%(pull_request_id)s', ['pull_request_id']); | |
44 | pyroutes.register('admin_settings_open_source', '/_admin/settings/open_source', []); |
|
44 | pyroutes.register('admin_settings_open_source', '/_admin/settings/open_source', []); | |
45 | pyroutes.register('admin_settings_vcs_svn_generate_cfg', '/_admin/settings/vcs/svn_generate_cfg', []); |
|
45 | pyroutes.register('admin_settings_vcs_svn_generate_cfg', '/_admin/settings/vcs/svn_generate_cfg', []); | |
46 | pyroutes.register('admin_settings_system', '/_admin/settings/system', []); |
|
46 | pyroutes.register('admin_settings_system', '/_admin/settings/system', []); | |
47 | pyroutes.register('admin_settings_system_update', '/_admin/settings/system/updates', []); |
|
47 | pyroutes.register('admin_settings_system_update', '/_admin/settings/system/updates', []); | |
48 | pyroutes.register('admin_settings_sessions', '/_admin/settings/sessions', []); |
|
48 | pyroutes.register('admin_settings_sessions', '/_admin/settings/sessions', []); | |
49 | pyroutes.register('admin_settings_sessions_cleanup', '/_admin/settings/sessions/cleanup', []); |
|
49 | pyroutes.register('admin_settings_sessions_cleanup', '/_admin/settings/sessions/cleanup', []); | |
50 | pyroutes.register('admin_settings_process_management', '/_admin/settings/process_management', []); |
|
50 | pyroutes.register('admin_settings_process_management', '/_admin/settings/process_management', []); | |
|
51 | pyroutes.register('admin_settings_process_management_data', '/_admin/settings/process_management/data', []); | |||
51 | pyroutes.register('admin_settings_process_management_signal', '/_admin/settings/process_management/signal', []); |
|
52 | pyroutes.register('admin_settings_process_management_signal', '/_admin/settings/process_management/signal', []); | |
52 | pyroutes.register('admin_defaults_repositories', '/_admin/defaults/repositories', []); |
|
53 | pyroutes.register('admin_defaults_repositories', '/_admin/defaults/repositories', []); | |
53 | pyroutes.register('admin_defaults_repositories_update', '/_admin/defaults/repositories/update', []); |
|
54 | pyroutes.register('admin_defaults_repositories_update', '/_admin/defaults/repositories/update', []); | |
54 | pyroutes.register('admin_settings', '/_admin/settings', []); |
|
55 | pyroutes.register('admin_settings', '/_admin/settings', []); | |
55 | pyroutes.register('admin_settings_update', '/_admin/settings/update', []); |
|
56 | pyroutes.register('admin_settings_update', '/_admin/settings/update', []); | |
56 | pyroutes.register('admin_settings_global', '/_admin/settings/global', []); |
|
57 | pyroutes.register('admin_settings_global', '/_admin/settings/global', []); | |
57 | pyroutes.register('admin_settings_global_update', '/_admin/settings/global/update', []); |
|
58 | pyroutes.register('admin_settings_global_update', '/_admin/settings/global/update', []); | |
58 | pyroutes.register('admin_settings_vcs', '/_admin/settings/vcs', []); |
|
59 | pyroutes.register('admin_settings_vcs', '/_admin/settings/vcs', []); | |
59 | pyroutes.register('admin_settings_vcs_update', '/_admin/settings/vcs/update', []); |
|
60 | pyroutes.register('admin_settings_vcs_update', '/_admin/settings/vcs/update', []); | |
60 | pyroutes.register('admin_settings_vcs_svn_pattern_delete', '/_admin/settings/vcs/svn_pattern_delete', []); |
|
61 | pyroutes.register('admin_settings_vcs_svn_pattern_delete', '/_admin/settings/vcs/svn_pattern_delete', []); | |
61 | pyroutes.register('admin_settings_mapping', '/_admin/settings/mapping', []); |
|
62 | pyroutes.register('admin_settings_mapping', '/_admin/settings/mapping', []); | |
62 | pyroutes.register('admin_settings_mapping_update', '/_admin/settings/mapping/update', []); |
|
63 | pyroutes.register('admin_settings_mapping_update', '/_admin/settings/mapping/update', []); | |
63 | pyroutes.register('admin_settings_visual', '/_admin/settings/visual', []); |
|
64 | pyroutes.register('admin_settings_visual', '/_admin/settings/visual', []); | |
64 | pyroutes.register('admin_settings_visual_update', '/_admin/settings/visual/update', []); |
|
65 | pyroutes.register('admin_settings_visual_update', '/_admin/settings/visual/update', []); | |
65 | pyroutes.register('admin_settings_issuetracker', '/_admin/settings/issue-tracker', []); |
|
66 | pyroutes.register('admin_settings_issuetracker', '/_admin/settings/issue-tracker', []); | |
66 | pyroutes.register('admin_settings_issuetracker_update', '/_admin/settings/issue-tracker/update', []); |
|
67 | pyroutes.register('admin_settings_issuetracker_update', '/_admin/settings/issue-tracker/update', []); | |
67 | pyroutes.register('admin_settings_issuetracker_test', '/_admin/settings/issue-tracker/test', []); |
|
68 | pyroutes.register('admin_settings_issuetracker_test', '/_admin/settings/issue-tracker/test', []); | |
68 | pyroutes.register('admin_settings_issuetracker_delete', '/_admin/settings/issue-tracker/delete', []); |
|
69 | pyroutes.register('admin_settings_issuetracker_delete', '/_admin/settings/issue-tracker/delete', []); | |
69 | pyroutes.register('admin_settings_email', '/_admin/settings/email', []); |
|
70 | pyroutes.register('admin_settings_email', '/_admin/settings/email', []); | |
70 | pyroutes.register('admin_settings_email_update', '/_admin/settings/email/update', []); |
|
71 | pyroutes.register('admin_settings_email_update', '/_admin/settings/email/update', []); | |
71 | pyroutes.register('admin_settings_hooks', '/_admin/settings/hooks', []); |
|
72 | pyroutes.register('admin_settings_hooks', '/_admin/settings/hooks', []); | |
72 | pyroutes.register('admin_settings_hooks_update', '/_admin/settings/hooks/update', []); |
|
73 | pyroutes.register('admin_settings_hooks_update', '/_admin/settings/hooks/update', []); | |
73 | pyroutes.register('admin_settings_hooks_delete', '/_admin/settings/hooks/delete', []); |
|
74 | pyroutes.register('admin_settings_hooks_delete', '/_admin/settings/hooks/delete', []); | |
74 | pyroutes.register('admin_settings_search', '/_admin/settings/search', []); |
|
75 | pyroutes.register('admin_settings_search', '/_admin/settings/search', []); | |
75 | pyroutes.register('admin_settings_labs', '/_admin/settings/labs', []); |
|
76 | pyroutes.register('admin_settings_labs', '/_admin/settings/labs', []); | |
76 | pyroutes.register('admin_settings_labs_update', '/_admin/settings/labs/update', []); |
|
77 | pyroutes.register('admin_settings_labs_update', '/_admin/settings/labs/update', []); | |
77 | pyroutes.register('admin_permissions_application', '/_admin/permissions/application', []); |
|
78 | pyroutes.register('admin_permissions_application', '/_admin/permissions/application', []); | |
78 | pyroutes.register('admin_permissions_application_update', '/_admin/permissions/application/update', []); |
|
79 | pyroutes.register('admin_permissions_application_update', '/_admin/permissions/application/update', []); | |
79 | pyroutes.register('admin_permissions_global', '/_admin/permissions/global', []); |
|
80 | pyroutes.register('admin_permissions_global', '/_admin/permissions/global', []); | |
80 | pyroutes.register('admin_permissions_global_update', '/_admin/permissions/global/update', []); |
|
81 | pyroutes.register('admin_permissions_global_update', '/_admin/permissions/global/update', []); | |
81 | pyroutes.register('admin_permissions_object', '/_admin/permissions/object', []); |
|
82 | pyroutes.register('admin_permissions_object', '/_admin/permissions/object', []); | |
82 | pyroutes.register('admin_permissions_object_update', '/_admin/permissions/object/update', []); |
|
83 | pyroutes.register('admin_permissions_object_update', '/_admin/permissions/object/update', []); | |
83 | pyroutes.register('admin_permissions_ips', '/_admin/permissions/ips', []); |
|
84 | pyroutes.register('admin_permissions_ips', '/_admin/permissions/ips', []); | |
84 | pyroutes.register('admin_permissions_overview', '/_admin/permissions/overview', []); |
|
85 | pyroutes.register('admin_permissions_overview', '/_admin/permissions/overview', []); | |
85 | pyroutes.register('admin_permissions_auth_token_access', '/_admin/permissions/auth_token_access', []); |
|
86 | pyroutes.register('admin_permissions_auth_token_access', '/_admin/permissions/auth_token_access', []); | |
86 | pyroutes.register('admin_permissions_ssh_keys', '/_admin/permissions/ssh_keys', []); |
|
87 | pyroutes.register('admin_permissions_ssh_keys', '/_admin/permissions/ssh_keys', []); | |
87 | pyroutes.register('admin_permissions_ssh_keys_data', '/_admin/permissions/ssh_keys/data', []); |
|
88 | pyroutes.register('admin_permissions_ssh_keys_data', '/_admin/permissions/ssh_keys/data', []); | |
88 | pyroutes.register('admin_permissions_ssh_keys_update', '/_admin/permissions/ssh_keys/update', []); |
|
89 | pyroutes.register('admin_permissions_ssh_keys_update', '/_admin/permissions/ssh_keys/update', []); | |
89 | pyroutes.register('users', '/_admin/users', []); |
|
90 | pyroutes.register('users', '/_admin/users', []); | |
90 | pyroutes.register('users_data', '/_admin/users_data', []); |
|
91 | pyroutes.register('users_data', '/_admin/users_data', []); | |
91 | pyroutes.register('users_create', '/_admin/users/create', []); |
|
92 | pyroutes.register('users_create', '/_admin/users/create', []); | |
92 | pyroutes.register('users_new', '/_admin/users/new', []); |
|
93 | pyroutes.register('users_new', '/_admin/users/new', []); | |
93 | pyroutes.register('user_edit', '/_admin/users/%(user_id)s/edit', ['user_id']); |
|
94 | pyroutes.register('user_edit', '/_admin/users/%(user_id)s/edit', ['user_id']); | |
94 | pyroutes.register('user_edit_advanced', '/_admin/users/%(user_id)s/edit/advanced', ['user_id']); |
|
95 | pyroutes.register('user_edit_advanced', '/_admin/users/%(user_id)s/edit/advanced', ['user_id']); | |
95 | pyroutes.register('user_edit_global_perms', '/_admin/users/%(user_id)s/edit/global_permissions', ['user_id']); |
|
96 | pyroutes.register('user_edit_global_perms', '/_admin/users/%(user_id)s/edit/global_permissions', ['user_id']); | |
96 | pyroutes.register('user_edit_global_perms_update', '/_admin/users/%(user_id)s/edit/global_permissions/update', ['user_id']); |
|
97 | pyroutes.register('user_edit_global_perms_update', '/_admin/users/%(user_id)s/edit/global_permissions/update', ['user_id']); | |
97 | pyroutes.register('user_update', '/_admin/users/%(user_id)s/update', ['user_id']); |
|
98 | pyroutes.register('user_update', '/_admin/users/%(user_id)s/update', ['user_id']); | |
98 | pyroutes.register('user_delete', '/_admin/users/%(user_id)s/delete', ['user_id']); |
|
99 | pyroutes.register('user_delete', '/_admin/users/%(user_id)s/delete', ['user_id']); | |
99 | pyroutes.register('user_force_password_reset', '/_admin/users/%(user_id)s/password_reset', ['user_id']); |
|
100 | pyroutes.register('user_force_password_reset', '/_admin/users/%(user_id)s/password_reset', ['user_id']); | |
100 | pyroutes.register('user_create_personal_repo_group', '/_admin/users/%(user_id)s/create_repo_group', ['user_id']); |
|
101 | pyroutes.register('user_create_personal_repo_group', '/_admin/users/%(user_id)s/create_repo_group', ['user_id']); | |
101 | pyroutes.register('edit_user_auth_tokens', '/_admin/users/%(user_id)s/edit/auth_tokens', ['user_id']); |
|
102 | pyroutes.register('edit_user_auth_tokens', '/_admin/users/%(user_id)s/edit/auth_tokens', ['user_id']); | |
102 | pyroutes.register('edit_user_auth_tokens_add', '/_admin/users/%(user_id)s/edit/auth_tokens/new', ['user_id']); |
|
103 | pyroutes.register('edit_user_auth_tokens_add', '/_admin/users/%(user_id)s/edit/auth_tokens/new', ['user_id']); | |
103 | pyroutes.register('edit_user_auth_tokens_delete', '/_admin/users/%(user_id)s/edit/auth_tokens/delete', ['user_id']); |
|
104 | pyroutes.register('edit_user_auth_tokens_delete', '/_admin/users/%(user_id)s/edit/auth_tokens/delete', ['user_id']); | |
104 | pyroutes.register('edit_user_ssh_keys', '/_admin/users/%(user_id)s/edit/ssh_keys', ['user_id']); |
|
105 | pyroutes.register('edit_user_ssh_keys', '/_admin/users/%(user_id)s/edit/ssh_keys', ['user_id']); | |
105 | pyroutes.register('edit_user_ssh_keys_generate_keypair', '/_admin/users/%(user_id)s/edit/ssh_keys/generate', ['user_id']); |
|
106 | pyroutes.register('edit_user_ssh_keys_generate_keypair', '/_admin/users/%(user_id)s/edit/ssh_keys/generate', ['user_id']); | |
106 | pyroutes.register('edit_user_ssh_keys_add', '/_admin/users/%(user_id)s/edit/ssh_keys/new', ['user_id']); |
|
107 | pyroutes.register('edit_user_ssh_keys_add', '/_admin/users/%(user_id)s/edit/ssh_keys/new', ['user_id']); | |
107 | pyroutes.register('edit_user_ssh_keys_delete', '/_admin/users/%(user_id)s/edit/ssh_keys/delete', ['user_id']); |
|
108 | pyroutes.register('edit_user_ssh_keys_delete', '/_admin/users/%(user_id)s/edit/ssh_keys/delete', ['user_id']); | |
108 | pyroutes.register('edit_user_emails', '/_admin/users/%(user_id)s/edit/emails', ['user_id']); |
|
109 | pyroutes.register('edit_user_emails', '/_admin/users/%(user_id)s/edit/emails', ['user_id']); | |
109 | pyroutes.register('edit_user_emails_add', '/_admin/users/%(user_id)s/edit/emails/new', ['user_id']); |
|
110 | pyroutes.register('edit_user_emails_add', '/_admin/users/%(user_id)s/edit/emails/new', ['user_id']); | |
110 | pyroutes.register('edit_user_emails_delete', '/_admin/users/%(user_id)s/edit/emails/delete', ['user_id']); |
|
111 | pyroutes.register('edit_user_emails_delete', '/_admin/users/%(user_id)s/edit/emails/delete', ['user_id']); | |
111 | pyroutes.register('edit_user_ips', '/_admin/users/%(user_id)s/edit/ips', ['user_id']); |
|
112 | pyroutes.register('edit_user_ips', '/_admin/users/%(user_id)s/edit/ips', ['user_id']); | |
112 | pyroutes.register('edit_user_ips_add', '/_admin/users/%(user_id)s/edit/ips/new', ['user_id']); |
|
113 | pyroutes.register('edit_user_ips_add', '/_admin/users/%(user_id)s/edit/ips/new', ['user_id']); | |
113 | pyroutes.register('edit_user_ips_delete', '/_admin/users/%(user_id)s/edit/ips/delete', ['user_id']); |
|
114 | pyroutes.register('edit_user_ips_delete', '/_admin/users/%(user_id)s/edit/ips/delete', ['user_id']); | |
114 | pyroutes.register('edit_user_perms_summary', '/_admin/users/%(user_id)s/edit/permissions_summary', ['user_id']); |
|
115 | pyroutes.register('edit_user_perms_summary', '/_admin/users/%(user_id)s/edit/permissions_summary', ['user_id']); | |
115 | pyroutes.register('edit_user_perms_summary_json', '/_admin/users/%(user_id)s/edit/permissions_summary/json', ['user_id']); |
|
116 | pyroutes.register('edit_user_perms_summary_json', '/_admin/users/%(user_id)s/edit/permissions_summary/json', ['user_id']); | |
116 | pyroutes.register('edit_user_groups_management', '/_admin/users/%(user_id)s/edit/groups_management', ['user_id']); |
|
117 | pyroutes.register('edit_user_groups_management', '/_admin/users/%(user_id)s/edit/groups_management', ['user_id']); | |
117 | pyroutes.register('edit_user_groups_management_updates', '/_admin/users/%(user_id)s/edit/edit_user_groups_management/updates', ['user_id']); |
|
118 | pyroutes.register('edit_user_groups_management_updates', '/_admin/users/%(user_id)s/edit/edit_user_groups_management/updates', ['user_id']); | |
118 | pyroutes.register('edit_user_audit_logs', '/_admin/users/%(user_id)s/edit/audit', ['user_id']); |
|
119 | pyroutes.register('edit_user_audit_logs', '/_admin/users/%(user_id)s/edit/audit', ['user_id']); | |
119 | pyroutes.register('user_groups', '/_admin/user_groups', []); |
|
120 | pyroutes.register('user_groups', '/_admin/user_groups', []); | |
120 | pyroutes.register('user_groups_data', '/_admin/user_groups_data', []); |
|
121 | pyroutes.register('user_groups_data', '/_admin/user_groups_data', []); | |
121 | pyroutes.register('user_groups_new', '/_admin/user_groups/new', []); |
|
122 | pyroutes.register('user_groups_new', '/_admin/user_groups/new', []); | |
122 | pyroutes.register('user_groups_create', '/_admin/user_groups/create', []); |
|
123 | pyroutes.register('user_groups_create', '/_admin/user_groups/create', []); | |
123 | pyroutes.register('repos', '/_admin/repos', []); |
|
124 | pyroutes.register('repos', '/_admin/repos', []); | |
124 | pyroutes.register('repo_new', '/_admin/repos/new', []); |
|
125 | pyroutes.register('repo_new', '/_admin/repos/new', []); | |
125 | pyroutes.register('repo_create', '/_admin/repos/create', []); |
|
126 | pyroutes.register('repo_create', '/_admin/repos/create', []); | |
126 | pyroutes.register('repo_groups', '/_admin/repo_groups', []); |
|
127 | pyroutes.register('repo_groups', '/_admin/repo_groups', []); | |
127 | pyroutes.register('repo_group_new', '/_admin/repo_group/new', []); |
|
128 | pyroutes.register('repo_group_new', '/_admin/repo_group/new', []); | |
128 | pyroutes.register('repo_group_create', '/_admin/repo_group/create', []); |
|
129 | pyroutes.register('repo_group_create', '/_admin/repo_group/create', []); | |
129 | pyroutes.register('channelstream_connect', '/_admin/channelstream/connect', []); |
|
130 | pyroutes.register('channelstream_connect', '/_admin/channelstream/connect', []); | |
130 | pyroutes.register('channelstream_subscribe', '/_admin/channelstream/subscribe', []); |
|
131 | pyroutes.register('channelstream_subscribe', '/_admin/channelstream/subscribe', []); | |
131 | pyroutes.register('channelstream_proxy', '/_channelstream', []); |
|
132 | pyroutes.register('channelstream_proxy', '/_channelstream', []); | |
132 | pyroutes.register('login', '/_admin/login', []); |
|
133 | pyroutes.register('login', '/_admin/login', []); | |
133 | pyroutes.register('logout', '/_admin/logout', []); |
|
134 | pyroutes.register('logout', '/_admin/logout', []); | |
134 | pyroutes.register('register', '/_admin/register', []); |
|
135 | pyroutes.register('register', '/_admin/register', []); | |
135 | pyroutes.register('reset_password', '/_admin/password_reset', []); |
|
136 | pyroutes.register('reset_password', '/_admin/password_reset', []); | |
136 | pyroutes.register('reset_password_confirmation', '/_admin/password_reset_confirmation', []); |
|
137 | pyroutes.register('reset_password_confirmation', '/_admin/password_reset_confirmation', []); | |
137 | pyroutes.register('home', '/', []); |
|
138 | pyroutes.register('home', '/', []); | |
138 | pyroutes.register('user_autocomplete_data', '/_users', []); |
|
139 | pyroutes.register('user_autocomplete_data', '/_users', []); | |
139 | pyroutes.register('user_group_autocomplete_data', '/_user_groups', []); |
|
140 | pyroutes.register('user_group_autocomplete_data', '/_user_groups', []); | |
140 | pyroutes.register('repo_list_data', '/_repos', []); |
|
141 | pyroutes.register('repo_list_data', '/_repos', []); | |
141 | pyroutes.register('goto_switcher_data', '/_goto_data', []); |
|
142 | pyroutes.register('goto_switcher_data', '/_goto_data', []); | |
142 | pyroutes.register('journal', '/_admin/journal', []); |
|
143 | pyroutes.register('journal', '/_admin/journal', []); | |
143 | pyroutes.register('journal_rss', '/_admin/journal/rss', []); |
|
144 | pyroutes.register('journal_rss', '/_admin/journal/rss', []); | |
144 | pyroutes.register('journal_atom', '/_admin/journal/atom', []); |
|
145 | pyroutes.register('journal_atom', '/_admin/journal/atom', []); | |
145 | pyroutes.register('journal_public', '/_admin/public_journal', []); |
|
146 | pyroutes.register('journal_public', '/_admin/public_journal', []); | |
146 | pyroutes.register('journal_public_atom', '/_admin/public_journal/atom', []); |
|
147 | pyroutes.register('journal_public_atom', '/_admin/public_journal/atom', []); | |
147 | pyroutes.register('journal_public_atom_old', '/_admin/public_journal_atom', []); |
|
148 | pyroutes.register('journal_public_atom_old', '/_admin/public_journal_atom', []); | |
148 | pyroutes.register('journal_public_rss', '/_admin/public_journal/rss', []); |
|
149 | pyroutes.register('journal_public_rss', '/_admin/public_journal/rss', []); | |
149 | pyroutes.register('journal_public_rss_old', '/_admin/public_journal_rss', []); |
|
150 | pyroutes.register('journal_public_rss_old', '/_admin/public_journal_rss', []); | |
150 | pyroutes.register('toggle_following', '/_admin/toggle_following', []); |
|
151 | pyroutes.register('toggle_following', '/_admin/toggle_following', []); | |
151 | pyroutes.register('repo_creating', '/%(repo_name)s/repo_creating', ['repo_name']); |
|
152 | pyroutes.register('repo_creating', '/%(repo_name)s/repo_creating', ['repo_name']); | |
152 | pyroutes.register('repo_creating_check', '/%(repo_name)s/repo_creating_check', ['repo_name']); |
|
153 | pyroutes.register('repo_creating_check', '/%(repo_name)s/repo_creating_check', ['repo_name']); | |
153 | pyroutes.register('repo_summary_explicit', '/%(repo_name)s/summary', ['repo_name']); |
|
154 | pyroutes.register('repo_summary_explicit', '/%(repo_name)s/summary', ['repo_name']); | |
154 | pyroutes.register('repo_summary_commits', '/%(repo_name)s/summary-commits', ['repo_name']); |
|
155 | pyroutes.register('repo_summary_commits', '/%(repo_name)s/summary-commits', ['repo_name']); | |
155 | pyroutes.register('repo_commit', '/%(repo_name)s/changeset/%(commit_id)s', ['repo_name', 'commit_id']); |
|
156 | pyroutes.register('repo_commit', '/%(repo_name)s/changeset/%(commit_id)s', ['repo_name', 'commit_id']); | |
156 | pyroutes.register('repo_commit_children', '/%(repo_name)s/changeset_children/%(commit_id)s', ['repo_name', 'commit_id']); |
|
157 | pyroutes.register('repo_commit_children', '/%(repo_name)s/changeset_children/%(commit_id)s', ['repo_name', 'commit_id']); | |
157 | pyroutes.register('repo_commit_parents', '/%(repo_name)s/changeset_parents/%(commit_id)s', ['repo_name', 'commit_id']); |
|
158 | pyroutes.register('repo_commit_parents', '/%(repo_name)s/changeset_parents/%(commit_id)s', ['repo_name', 'commit_id']); | |
158 | pyroutes.register('repo_commit_raw', '/%(repo_name)s/changeset-diff/%(commit_id)s', ['repo_name', 'commit_id']); |
|
159 | pyroutes.register('repo_commit_raw', '/%(repo_name)s/changeset-diff/%(commit_id)s', ['repo_name', 'commit_id']); | |
159 | pyroutes.register('repo_commit_patch', '/%(repo_name)s/changeset-patch/%(commit_id)s', ['repo_name', 'commit_id']); |
|
160 | pyroutes.register('repo_commit_patch', '/%(repo_name)s/changeset-patch/%(commit_id)s', ['repo_name', 'commit_id']); | |
160 | pyroutes.register('repo_commit_download', '/%(repo_name)s/changeset-download/%(commit_id)s', ['repo_name', 'commit_id']); |
|
161 | pyroutes.register('repo_commit_download', '/%(repo_name)s/changeset-download/%(commit_id)s', ['repo_name', 'commit_id']); | |
161 | pyroutes.register('repo_commit_data', '/%(repo_name)s/changeset-data/%(commit_id)s', ['repo_name', 'commit_id']); |
|
162 | pyroutes.register('repo_commit_data', '/%(repo_name)s/changeset-data/%(commit_id)s', ['repo_name', 'commit_id']); | |
162 | pyroutes.register('repo_commit_comment_create', '/%(repo_name)s/changeset/%(commit_id)s/comment/create', ['repo_name', 'commit_id']); |
|
163 | pyroutes.register('repo_commit_comment_create', '/%(repo_name)s/changeset/%(commit_id)s/comment/create', ['repo_name', 'commit_id']); | |
163 | pyroutes.register('repo_commit_comment_preview', '/%(repo_name)s/changeset/%(commit_id)s/comment/preview', ['repo_name', 'commit_id']); |
|
164 | pyroutes.register('repo_commit_comment_preview', '/%(repo_name)s/changeset/%(commit_id)s/comment/preview', ['repo_name', 'commit_id']); | |
164 | pyroutes.register('repo_commit_comment_delete', '/%(repo_name)s/changeset/%(commit_id)s/comment/%(comment_id)s/delete', ['repo_name', 'commit_id', 'comment_id']); |
|
165 | pyroutes.register('repo_commit_comment_delete', '/%(repo_name)s/changeset/%(commit_id)s/comment/%(comment_id)s/delete', ['repo_name', 'commit_id', 'comment_id']); | |
165 | pyroutes.register('repo_commit_raw_deprecated', '/%(repo_name)s/raw-changeset/%(commit_id)s', ['repo_name', 'commit_id']); |
|
166 | pyroutes.register('repo_commit_raw_deprecated', '/%(repo_name)s/raw-changeset/%(commit_id)s', ['repo_name', 'commit_id']); | |
166 | pyroutes.register('repo_archivefile', '/%(repo_name)s/archive/%(fname)s', ['repo_name', 'fname']); |
|
167 | pyroutes.register('repo_archivefile', '/%(repo_name)s/archive/%(fname)s', ['repo_name', 'fname']); | |
167 | pyroutes.register('repo_files_diff', '/%(repo_name)s/diff/%(f_path)s', ['repo_name', 'f_path']); |
|
168 | pyroutes.register('repo_files_diff', '/%(repo_name)s/diff/%(f_path)s', ['repo_name', 'f_path']); | |
168 | pyroutes.register('repo_files_diff_2way_redirect', '/%(repo_name)s/diff-2way/%(f_path)s', ['repo_name', 'f_path']); |
|
169 | pyroutes.register('repo_files_diff_2way_redirect', '/%(repo_name)s/diff-2way/%(f_path)s', ['repo_name', 'f_path']); | |
169 | pyroutes.register('repo_files', '/%(repo_name)s/files/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); |
|
170 | pyroutes.register('repo_files', '/%(repo_name)s/files/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); | |
170 | pyroutes.register('repo_files:default_path', '/%(repo_name)s/files/%(commit_id)s/', ['repo_name', 'commit_id']); |
|
171 | pyroutes.register('repo_files:default_path', '/%(repo_name)s/files/%(commit_id)s/', ['repo_name', 'commit_id']); | |
171 | pyroutes.register('repo_files:default_commit', '/%(repo_name)s/files', ['repo_name']); |
|
172 | pyroutes.register('repo_files:default_commit', '/%(repo_name)s/files', ['repo_name']); | |
172 | pyroutes.register('repo_files:rendered', '/%(repo_name)s/render/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); |
|
173 | pyroutes.register('repo_files:rendered', '/%(repo_name)s/render/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); | |
173 | pyroutes.register('repo_files:annotated', '/%(repo_name)s/annotate/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); |
|
174 | pyroutes.register('repo_files:annotated', '/%(repo_name)s/annotate/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); | |
174 | pyroutes.register('repo_files:annotated_previous', '/%(repo_name)s/annotate-previous/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); |
|
175 | pyroutes.register('repo_files:annotated_previous', '/%(repo_name)s/annotate-previous/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); | |
175 | pyroutes.register('repo_nodetree_full', '/%(repo_name)s/nodetree_full/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); |
|
176 | pyroutes.register('repo_nodetree_full', '/%(repo_name)s/nodetree_full/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); | |
176 | pyroutes.register('repo_nodetree_full:default_path', '/%(repo_name)s/nodetree_full/%(commit_id)s/', ['repo_name', 'commit_id']); |
|
177 | pyroutes.register('repo_nodetree_full:default_path', '/%(repo_name)s/nodetree_full/%(commit_id)s/', ['repo_name', 'commit_id']); | |
177 | pyroutes.register('repo_files_nodelist', '/%(repo_name)s/nodelist/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); |
|
178 | pyroutes.register('repo_files_nodelist', '/%(repo_name)s/nodelist/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); | |
178 | pyroutes.register('repo_file_raw', '/%(repo_name)s/raw/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); |
|
179 | pyroutes.register('repo_file_raw', '/%(repo_name)s/raw/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); | |
179 | pyroutes.register('repo_file_download', '/%(repo_name)s/download/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); |
|
180 | pyroutes.register('repo_file_download', '/%(repo_name)s/download/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); | |
180 | pyroutes.register('repo_file_download:legacy', '/%(repo_name)s/rawfile/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); |
|
181 | pyroutes.register('repo_file_download:legacy', '/%(repo_name)s/rawfile/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); | |
181 | pyroutes.register('repo_file_history', '/%(repo_name)s/history/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); |
|
182 | pyroutes.register('repo_file_history', '/%(repo_name)s/history/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); | |
182 | pyroutes.register('repo_file_authors', '/%(repo_name)s/authors/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); |
|
183 | pyroutes.register('repo_file_authors', '/%(repo_name)s/authors/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); | |
183 | pyroutes.register('repo_files_remove_file', '/%(repo_name)s/remove_file/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); |
|
184 | pyroutes.register('repo_files_remove_file', '/%(repo_name)s/remove_file/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); | |
184 | pyroutes.register('repo_files_delete_file', '/%(repo_name)s/delete_file/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); |
|
185 | pyroutes.register('repo_files_delete_file', '/%(repo_name)s/delete_file/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); | |
185 | pyroutes.register('repo_files_edit_file', '/%(repo_name)s/edit_file/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); |
|
186 | pyroutes.register('repo_files_edit_file', '/%(repo_name)s/edit_file/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); | |
186 | pyroutes.register('repo_files_update_file', '/%(repo_name)s/update_file/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); |
|
187 | pyroutes.register('repo_files_update_file', '/%(repo_name)s/update_file/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); | |
187 | pyroutes.register('repo_files_add_file', '/%(repo_name)s/add_file/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); |
|
188 | pyroutes.register('repo_files_add_file', '/%(repo_name)s/add_file/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); | |
188 | pyroutes.register('repo_files_create_file', '/%(repo_name)s/create_file/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); |
|
189 | pyroutes.register('repo_files_create_file', '/%(repo_name)s/create_file/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); | |
189 | pyroutes.register('repo_refs_data', '/%(repo_name)s/refs-data', ['repo_name']); |
|
190 | pyroutes.register('repo_refs_data', '/%(repo_name)s/refs-data', ['repo_name']); | |
190 | pyroutes.register('repo_refs_changelog_data', '/%(repo_name)s/refs-data-changelog', ['repo_name']); |
|
191 | pyroutes.register('repo_refs_changelog_data', '/%(repo_name)s/refs-data-changelog', ['repo_name']); | |
191 | pyroutes.register('repo_stats', '/%(repo_name)s/repo_stats/%(commit_id)s', ['repo_name', 'commit_id']); |
|
192 | pyroutes.register('repo_stats', '/%(repo_name)s/repo_stats/%(commit_id)s', ['repo_name', 'commit_id']); | |
192 | pyroutes.register('repo_changelog', '/%(repo_name)s/changelog', ['repo_name']); |
|
193 | pyroutes.register('repo_changelog', '/%(repo_name)s/changelog', ['repo_name']); | |
193 | pyroutes.register('repo_changelog_file', '/%(repo_name)s/changelog/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); |
|
194 | pyroutes.register('repo_changelog_file', '/%(repo_name)s/changelog/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); | |
194 | pyroutes.register('repo_changelog_elements', '/%(repo_name)s/changelog_elements', ['repo_name']); |
|
195 | pyroutes.register('repo_changelog_elements', '/%(repo_name)s/changelog_elements', ['repo_name']); | |
195 | pyroutes.register('repo_changelog_elements_file', '/%(repo_name)s/changelog_elements/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); |
|
196 | pyroutes.register('repo_changelog_elements_file', '/%(repo_name)s/changelog_elements/%(commit_id)s/%(f_path)s', ['repo_name', 'commit_id', 'f_path']); | |
196 | pyroutes.register('repo_compare_select', '/%(repo_name)s/compare', ['repo_name']); |
|
197 | pyroutes.register('repo_compare_select', '/%(repo_name)s/compare', ['repo_name']); | |
197 | pyroutes.register('repo_compare', '/%(repo_name)s/compare/%(source_ref_type)s@%(source_ref)s...%(target_ref_type)s@%(target_ref)s', ['repo_name', 'source_ref_type', 'source_ref', 'target_ref_type', 'target_ref']); |
|
198 | pyroutes.register('repo_compare', '/%(repo_name)s/compare/%(source_ref_type)s@%(source_ref)s...%(target_ref_type)s@%(target_ref)s', ['repo_name', 'source_ref_type', 'source_ref', 'target_ref_type', 'target_ref']); | |
198 | pyroutes.register('tags_home', '/%(repo_name)s/tags', ['repo_name']); |
|
199 | pyroutes.register('tags_home', '/%(repo_name)s/tags', ['repo_name']); | |
199 | pyroutes.register('branches_home', '/%(repo_name)s/branches', ['repo_name']); |
|
200 | pyroutes.register('branches_home', '/%(repo_name)s/branches', ['repo_name']); | |
200 | pyroutes.register('bookmarks_home', '/%(repo_name)s/bookmarks', ['repo_name']); |
|
201 | pyroutes.register('bookmarks_home', '/%(repo_name)s/bookmarks', ['repo_name']); | |
201 | pyroutes.register('repo_fork_new', '/%(repo_name)s/fork', ['repo_name']); |
|
202 | pyroutes.register('repo_fork_new', '/%(repo_name)s/fork', ['repo_name']); | |
202 | pyroutes.register('repo_fork_create', '/%(repo_name)s/fork/create', ['repo_name']); |
|
203 | pyroutes.register('repo_fork_create', '/%(repo_name)s/fork/create', ['repo_name']); | |
203 | pyroutes.register('repo_forks_show_all', '/%(repo_name)s/forks', ['repo_name']); |
|
204 | pyroutes.register('repo_forks_show_all', '/%(repo_name)s/forks', ['repo_name']); | |
204 | pyroutes.register('repo_forks_data', '/%(repo_name)s/forks/data', ['repo_name']); |
|
205 | pyroutes.register('repo_forks_data', '/%(repo_name)s/forks/data', ['repo_name']); | |
205 | pyroutes.register('pullrequest_show', '/%(repo_name)s/pull-request/%(pull_request_id)s', ['repo_name', 'pull_request_id']); |
|
206 | pyroutes.register('pullrequest_show', '/%(repo_name)s/pull-request/%(pull_request_id)s', ['repo_name', 'pull_request_id']); | |
206 | pyroutes.register('pullrequest_show_all', '/%(repo_name)s/pull-request', ['repo_name']); |
|
207 | pyroutes.register('pullrequest_show_all', '/%(repo_name)s/pull-request', ['repo_name']); | |
207 | pyroutes.register('pullrequest_show_all_data', '/%(repo_name)s/pull-request-data', ['repo_name']); |
|
208 | pyroutes.register('pullrequest_show_all_data', '/%(repo_name)s/pull-request-data', ['repo_name']); | |
208 | pyroutes.register('pullrequest_repo_refs', '/%(repo_name)s/pull-request/refs/%(target_repo_name)s', ['repo_name', 'target_repo_name']); |
|
209 | pyroutes.register('pullrequest_repo_refs', '/%(repo_name)s/pull-request/refs/%(target_repo_name)s', ['repo_name', 'target_repo_name']); | |
209 | pyroutes.register('pullrequest_repo_destinations', '/%(repo_name)s/pull-request/repo-destinations', ['repo_name']); |
|
210 | pyroutes.register('pullrequest_repo_destinations', '/%(repo_name)s/pull-request/repo-destinations', ['repo_name']); | |
210 | pyroutes.register('pullrequest_new', '/%(repo_name)s/pull-request/new', ['repo_name']); |
|
211 | pyroutes.register('pullrequest_new', '/%(repo_name)s/pull-request/new', ['repo_name']); | |
211 | pyroutes.register('pullrequest_create', '/%(repo_name)s/pull-request/create', ['repo_name']); |
|
212 | pyroutes.register('pullrequest_create', '/%(repo_name)s/pull-request/create', ['repo_name']); | |
212 | pyroutes.register('pullrequest_update', '/%(repo_name)s/pull-request/%(pull_request_id)s/update', ['repo_name', 'pull_request_id']); |
|
213 | pyroutes.register('pullrequest_update', '/%(repo_name)s/pull-request/%(pull_request_id)s/update', ['repo_name', 'pull_request_id']); | |
213 | pyroutes.register('pullrequest_merge', '/%(repo_name)s/pull-request/%(pull_request_id)s/merge', ['repo_name', 'pull_request_id']); |
|
214 | pyroutes.register('pullrequest_merge', '/%(repo_name)s/pull-request/%(pull_request_id)s/merge', ['repo_name', 'pull_request_id']); | |
214 | pyroutes.register('pullrequest_delete', '/%(repo_name)s/pull-request/%(pull_request_id)s/delete', ['repo_name', 'pull_request_id']); |
|
215 | pyroutes.register('pullrequest_delete', '/%(repo_name)s/pull-request/%(pull_request_id)s/delete', ['repo_name', 'pull_request_id']); | |
215 | pyroutes.register('pullrequest_comment_create', '/%(repo_name)s/pull-request/%(pull_request_id)s/comment', ['repo_name', 'pull_request_id']); |
|
216 | pyroutes.register('pullrequest_comment_create', '/%(repo_name)s/pull-request/%(pull_request_id)s/comment', ['repo_name', 'pull_request_id']); | |
216 | pyroutes.register('pullrequest_comment_delete', '/%(repo_name)s/pull-request/%(pull_request_id)s/comment/%(comment_id)s/delete', ['repo_name', 'pull_request_id', 'comment_id']); |
|
217 | pyroutes.register('pullrequest_comment_delete', '/%(repo_name)s/pull-request/%(pull_request_id)s/comment/%(comment_id)s/delete', ['repo_name', 'pull_request_id', 'comment_id']); | |
217 | pyroutes.register('edit_repo', '/%(repo_name)s/settings', ['repo_name']); |
|
218 | pyroutes.register('edit_repo', '/%(repo_name)s/settings', ['repo_name']); | |
218 | pyroutes.register('edit_repo_advanced', '/%(repo_name)s/settings/advanced', ['repo_name']); |
|
219 | pyroutes.register('edit_repo_advanced', '/%(repo_name)s/settings/advanced', ['repo_name']); | |
219 | pyroutes.register('edit_repo_advanced_delete', '/%(repo_name)s/settings/advanced/delete', ['repo_name']); |
|
220 | pyroutes.register('edit_repo_advanced_delete', '/%(repo_name)s/settings/advanced/delete', ['repo_name']); | |
220 | pyroutes.register('edit_repo_advanced_locking', '/%(repo_name)s/settings/advanced/locking', ['repo_name']); |
|
221 | pyroutes.register('edit_repo_advanced_locking', '/%(repo_name)s/settings/advanced/locking', ['repo_name']); | |
221 | pyroutes.register('edit_repo_advanced_journal', '/%(repo_name)s/settings/advanced/journal', ['repo_name']); |
|
222 | pyroutes.register('edit_repo_advanced_journal', '/%(repo_name)s/settings/advanced/journal', ['repo_name']); | |
222 | pyroutes.register('edit_repo_advanced_fork', '/%(repo_name)s/settings/advanced/fork', ['repo_name']); |
|
223 | pyroutes.register('edit_repo_advanced_fork', '/%(repo_name)s/settings/advanced/fork', ['repo_name']); | |
223 | pyroutes.register('edit_repo_caches', '/%(repo_name)s/settings/caches', ['repo_name']); |
|
224 | pyroutes.register('edit_repo_caches', '/%(repo_name)s/settings/caches', ['repo_name']); | |
224 | pyroutes.register('edit_repo_perms', '/%(repo_name)s/settings/permissions', ['repo_name']); |
|
225 | pyroutes.register('edit_repo_perms', '/%(repo_name)s/settings/permissions', ['repo_name']); | |
225 | pyroutes.register('edit_repo_maintenance', '/%(repo_name)s/settings/maintenance', ['repo_name']); |
|
226 | pyroutes.register('edit_repo_maintenance', '/%(repo_name)s/settings/maintenance', ['repo_name']); | |
226 | pyroutes.register('edit_repo_maintenance_execute', '/%(repo_name)s/settings/maintenance/execute', ['repo_name']); |
|
227 | pyroutes.register('edit_repo_maintenance_execute', '/%(repo_name)s/settings/maintenance/execute', ['repo_name']); | |
227 | pyroutes.register('edit_repo_fields', '/%(repo_name)s/settings/fields', ['repo_name']); |
|
228 | pyroutes.register('edit_repo_fields', '/%(repo_name)s/settings/fields', ['repo_name']); | |
228 | pyroutes.register('edit_repo_fields_create', '/%(repo_name)s/settings/fields/create', ['repo_name']); |
|
229 | pyroutes.register('edit_repo_fields_create', '/%(repo_name)s/settings/fields/create', ['repo_name']); | |
229 | pyroutes.register('edit_repo_fields_delete', '/%(repo_name)s/settings/fields/%(field_id)s/delete', ['repo_name', 'field_id']); |
|
230 | pyroutes.register('edit_repo_fields_delete', '/%(repo_name)s/settings/fields/%(field_id)s/delete', ['repo_name', 'field_id']); | |
230 | pyroutes.register('repo_edit_toggle_locking', '/%(repo_name)s/settings/toggle_locking', ['repo_name']); |
|
231 | pyroutes.register('repo_edit_toggle_locking', '/%(repo_name)s/settings/toggle_locking', ['repo_name']); | |
231 | pyroutes.register('edit_repo_remote', '/%(repo_name)s/settings/remote', ['repo_name']); |
|
232 | pyroutes.register('edit_repo_remote', '/%(repo_name)s/settings/remote', ['repo_name']); | |
232 | pyroutes.register('edit_repo_remote_pull', '/%(repo_name)s/settings/remote/pull', ['repo_name']); |
|
233 | pyroutes.register('edit_repo_remote_pull', '/%(repo_name)s/settings/remote/pull', ['repo_name']); | |
233 | pyroutes.register('edit_repo_statistics', '/%(repo_name)s/settings/statistics', ['repo_name']); |
|
234 | pyroutes.register('edit_repo_statistics', '/%(repo_name)s/settings/statistics', ['repo_name']); | |
234 | pyroutes.register('edit_repo_statistics_reset', '/%(repo_name)s/settings/statistics/update', ['repo_name']); |
|
235 | pyroutes.register('edit_repo_statistics_reset', '/%(repo_name)s/settings/statistics/update', ['repo_name']); | |
235 | pyroutes.register('edit_repo_issuetracker', '/%(repo_name)s/settings/issue_trackers', ['repo_name']); |
|
236 | pyroutes.register('edit_repo_issuetracker', '/%(repo_name)s/settings/issue_trackers', ['repo_name']); | |
236 | pyroutes.register('edit_repo_issuetracker_test', '/%(repo_name)s/settings/issue_trackers/test', ['repo_name']); |
|
237 | pyroutes.register('edit_repo_issuetracker_test', '/%(repo_name)s/settings/issue_trackers/test', ['repo_name']); | |
237 | pyroutes.register('edit_repo_issuetracker_delete', '/%(repo_name)s/settings/issue_trackers/delete', ['repo_name']); |
|
238 | pyroutes.register('edit_repo_issuetracker_delete', '/%(repo_name)s/settings/issue_trackers/delete', ['repo_name']); | |
238 | pyroutes.register('edit_repo_issuetracker_update', '/%(repo_name)s/settings/issue_trackers/update', ['repo_name']); |
|
239 | pyroutes.register('edit_repo_issuetracker_update', '/%(repo_name)s/settings/issue_trackers/update', ['repo_name']); | |
239 | pyroutes.register('edit_repo_vcs', '/%(repo_name)s/settings/vcs', ['repo_name']); |
|
240 | pyroutes.register('edit_repo_vcs', '/%(repo_name)s/settings/vcs', ['repo_name']); | |
240 | pyroutes.register('edit_repo_vcs_update', '/%(repo_name)s/settings/vcs/update', ['repo_name']); |
|
241 | pyroutes.register('edit_repo_vcs_update', '/%(repo_name)s/settings/vcs/update', ['repo_name']); | |
241 | pyroutes.register('edit_repo_vcs_svn_pattern_delete', '/%(repo_name)s/settings/vcs/svn_pattern/delete', ['repo_name']); |
|
242 | pyroutes.register('edit_repo_vcs_svn_pattern_delete', '/%(repo_name)s/settings/vcs/svn_pattern/delete', ['repo_name']); | |
242 | pyroutes.register('repo_reviewers', '/%(repo_name)s/settings/review/rules', ['repo_name']); |
|
243 | pyroutes.register('repo_reviewers', '/%(repo_name)s/settings/review/rules', ['repo_name']); | |
243 | pyroutes.register('repo_default_reviewers_data', '/%(repo_name)s/settings/review/default-reviewers', ['repo_name']); |
|
244 | pyroutes.register('repo_default_reviewers_data', '/%(repo_name)s/settings/review/default-reviewers', ['repo_name']); | |
244 | pyroutes.register('edit_repo_strip', '/%(repo_name)s/settings/strip', ['repo_name']); |
|
245 | pyroutes.register('edit_repo_strip', '/%(repo_name)s/settings/strip', ['repo_name']); | |
245 | pyroutes.register('strip_check', '/%(repo_name)s/settings/strip_check', ['repo_name']); |
|
246 | pyroutes.register('strip_check', '/%(repo_name)s/settings/strip_check', ['repo_name']); | |
246 | pyroutes.register('strip_execute', '/%(repo_name)s/settings/strip_execute', ['repo_name']); |
|
247 | pyroutes.register('strip_execute', '/%(repo_name)s/settings/strip_execute', ['repo_name']); | |
247 | pyroutes.register('edit_repo_audit_logs', '/%(repo_name)s/settings/audit_logs', ['repo_name']); |
|
248 | pyroutes.register('edit_repo_audit_logs', '/%(repo_name)s/settings/audit_logs', ['repo_name']); | |
248 | pyroutes.register('rss_feed_home', '/%(repo_name)s/feed/rss', ['repo_name']); |
|
249 | pyroutes.register('rss_feed_home', '/%(repo_name)s/feed/rss', ['repo_name']); | |
249 | pyroutes.register('atom_feed_home', '/%(repo_name)s/feed/atom', ['repo_name']); |
|
250 | pyroutes.register('atom_feed_home', '/%(repo_name)s/feed/atom', ['repo_name']); | |
250 | pyroutes.register('repo_summary', '/%(repo_name)s', ['repo_name']); |
|
251 | pyroutes.register('repo_summary', '/%(repo_name)s', ['repo_name']); | |
251 | pyroutes.register('repo_summary_slash', '/%(repo_name)s/', ['repo_name']); |
|
252 | pyroutes.register('repo_summary_slash', '/%(repo_name)s/', ['repo_name']); | |
252 | pyroutes.register('edit_repo_group', '/%(repo_group_name)s/_edit', ['repo_group_name']); |
|
253 | pyroutes.register('edit_repo_group', '/%(repo_group_name)s/_edit', ['repo_group_name']); | |
253 | pyroutes.register('edit_repo_group_advanced', '/%(repo_group_name)s/_settings/advanced', ['repo_group_name']); |
|
254 | pyroutes.register('edit_repo_group_advanced', '/%(repo_group_name)s/_settings/advanced', ['repo_group_name']); | |
254 | pyroutes.register('edit_repo_group_advanced_delete', '/%(repo_group_name)s/_settings/advanced/delete', ['repo_group_name']); |
|
255 | pyroutes.register('edit_repo_group_advanced_delete', '/%(repo_group_name)s/_settings/advanced/delete', ['repo_group_name']); | |
255 | pyroutes.register('edit_repo_group_perms', '/%(repo_group_name)s/_settings/permissions', ['repo_group_name']); |
|
256 | pyroutes.register('edit_repo_group_perms', '/%(repo_group_name)s/_settings/permissions', ['repo_group_name']); | |
256 | pyroutes.register('edit_repo_group_perms_update', '/%(repo_group_name)s/_settings/permissions/update', ['repo_group_name']); |
|
257 | pyroutes.register('edit_repo_group_perms_update', '/%(repo_group_name)s/_settings/permissions/update', ['repo_group_name']); | |
257 | pyroutes.register('repo_group_home', '/%(repo_group_name)s', ['repo_group_name']); |
|
258 | pyroutes.register('repo_group_home', '/%(repo_group_name)s', ['repo_group_name']); | |
258 | pyroutes.register('repo_group_home_slash', '/%(repo_group_name)s/', ['repo_group_name']); |
|
259 | pyroutes.register('repo_group_home_slash', '/%(repo_group_name)s/', ['repo_group_name']); | |
259 | pyroutes.register('user_group_members_data', '/_admin/user_groups/%(user_group_id)s/members', ['user_group_id']); |
|
260 | pyroutes.register('user_group_members_data', '/_admin/user_groups/%(user_group_id)s/members', ['user_group_id']); | |
260 | pyroutes.register('edit_user_group_perms_summary', '/_admin/user_groups/%(user_group_id)s/edit/permissions_summary', ['user_group_id']); |
|
261 | pyroutes.register('edit_user_group_perms_summary', '/_admin/user_groups/%(user_group_id)s/edit/permissions_summary', ['user_group_id']); | |
261 | pyroutes.register('edit_user_group_perms_summary_json', '/_admin/user_groups/%(user_group_id)s/edit/permissions_summary/json', ['user_group_id']); |
|
262 | pyroutes.register('edit_user_group_perms_summary_json', '/_admin/user_groups/%(user_group_id)s/edit/permissions_summary/json', ['user_group_id']); | |
262 | pyroutes.register('edit_user_group', '/_admin/user_groups/%(user_group_id)s/edit', ['user_group_id']); |
|
263 | pyroutes.register('edit_user_group', '/_admin/user_groups/%(user_group_id)s/edit', ['user_group_id']); | |
263 | pyroutes.register('user_groups_update', '/_admin/user_groups/%(user_group_id)s/update', ['user_group_id']); |
|
264 | pyroutes.register('user_groups_update', '/_admin/user_groups/%(user_group_id)s/update', ['user_group_id']); | |
264 | pyroutes.register('edit_user_group_global_perms', '/_admin/user_groups/%(user_group_id)s/edit/global_permissions', ['user_group_id']); |
|
265 | pyroutes.register('edit_user_group_global_perms', '/_admin/user_groups/%(user_group_id)s/edit/global_permissions', ['user_group_id']); | |
265 | pyroutes.register('edit_user_group_global_perms_update', '/_admin/user_groups/%(user_group_id)s/edit/global_permissions/update', ['user_group_id']); |
|
266 | pyroutes.register('edit_user_group_global_perms_update', '/_admin/user_groups/%(user_group_id)s/edit/global_permissions/update', ['user_group_id']); | |
266 | pyroutes.register('edit_user_group_perms', '/_admin/user_groups/%(user_group_id)s/edit/permissions', ['user_group_id']); |
|
267 | pyroutes.register('edit_user_group_perms', '/_admin/user_groups/%(user_group_id)s/edit/permissions', ['user_group_id']); | |
267 | pyroutes.register('edit_user_group_perms_update', '/_admin/user_groups/%(user_group_id)s/edit/permissions/update', ['user_group_id']); |
|
268 | pyroutes.register('edit_user_group_perms_update', '/_admin/user_groups/%(user_group_id)s/edit/permissions/update', ['user_group_id']); | |
268 | pyroutes.register('edit_user_group_advanced', '/_admin/user_groups/%(user_group_id)s/edit/advanced', ['user_group_id']); |
|
269 | pyroutes.register('edit_user_group_advanced', '/_admin/user_groups/%(user_group_id)s/edit/advanced', ['user_group_id']); | |
269 | pyroutes.register('edit_user_group_advanced_sync', '/_admin/user_groups/%(user_group_id)s/edit/advanced/sync', ['user_group_id']); |
|
270 | pyroutes.register('edit_user_group_advanced_sync', '/_admin/user_groups/%(user_group_id)s/edit/advanced/sync', ['user_group_id']); | |
270 | pyroutes.register('user_groups_delete', '/_admin/user_groups/%(user_group_id)s/delete', ['user_group_id']); |
|
271 | pyroutes.register('user_groups_delete', '/_admin/user_groups/%(user_group_id)s/delete', ['user_group_id']); | |
271 | pyroutes.register('search', '/_admin/search', []); |
|
272 | pyroutes.register('search', '/_admin/search', []); | |
272 | pyroutes.register('search_repo', '/%(repo_name)s/search', ['repo_name']); |
|
273 | pyroutes.register('search_repo', '/%(repo_name)s/search', ['repo_name']); | |
273 | pyroutes.register('user_profile', '/_profiles/%(username)s', ['username']); |
|
274 | pyroutes.register('user_profile', '/_profiles/%(username)s', ['username']); | |
274 | pyroutes.register('my_account_profile', '/_admin/my_account/profile', []); |
|
275 | pyroutes.register('my_account_profile', '/_admin/my_account/profile', []); | |
275 | pyroutes.register('my_account_edit', '/_admin/my_account/edit', []); |
|
276 | pyroutes.register('my_account_edit', '/_admin/my_account/edit', []); | |
276 | pyroutes.register('my_account_update', '/_admin/my_account/update', []); |
|
277 | pyroutes.register('my_account_update', '/_admin/my_account/update', []); | |
277 | pyroutes.register('my_account_password', '/_admin/my_account/password', []); |
|
278 | pyroutes.register('my_account_password', '/_admin/my_account/password', []); | |
278 | pyroutes.register('my_account_password_update', '/_admin/my_account/password/update', []); |
|
279 | pyroutes.register('my_account_password_update', '/_admin/my_account/password/update', []); | |
279 | pyroutes.register('my_account_auth_tokens', '/_admin/my_account/auth_tokens', []); |
|
280 | pyroutes.register('my_account_auth_tokens', '/_admin/my_account/auth_tokens', []); | |
280 | pyroutes.register('my_account_auth_tokens_add', '/_admin/my_account/auth_tokens/new', []); |
|
281 | pyroutes.register('my_account_auth_tokens_add', '/_admin/my_account/auth_tokens/new', []); | |
281 | pyroutes.register('my_account_auth_tokens_delete', '/_admin/my_account/auth_tokens/delete', []); |
|
282 | pyroutes.register('my_account_auth_tokens_delete', '/_admin/my_account/auth_tokens/delete', []); | |
282 | pyroutes.register('my_account_ssh_keys', '/_admin/my_account/ssh_keys', []); |
|
283 | pyroutes.register('my_account_ssh_keys', '/_admin/my_account/ssh_keys', []); | |
283 | pyroutes.register('my_account_ssh_keys_generate', '/_admin/my_account/ssh_keys/generate', []); |
|
284 | pyroutes.register('my_account_ssh_keys_generate', '/_admin/my_account/ssh_keys/generate', []); | |
284 | pyroutes.register('my_account_ssh_keys_add', '/_admin/my_account/ssh_keys/new', []); |
|
285 | pyroutes.register('my_account_ssh_keys_add', '/_admin/my_account/ssh_keys/new', []); | |
285 | pyroutes.register('my_account_ssh_keys_delete', '/_admin/my_account/ssh_keys/delete', []); |
|
286 | pyroutes.register('my_account_ssh_keys_delete', '/_admin/my_account/ssh_keys/delete', []); | |
|
287 | pyroutes.register('my_account_user_group_membership', '/_admin/my_account/user_group_membership', []); | |||
286 | pyroutes.register('my_account_emails', '/_admin/my_account/emails', []); |
|
288 | pyroutes.register('my_account_emails', '/_admin/my_account/emails', []); | |
287 | pyroutes.register('my_account_emails_add', '/_admin/my_account/emails/new', []); |
|
289 | pyroutes.register('my_account_emails_add', '/_admin/my_account/emails/new', []); | |
288 | pyroutes.register('my_account_emails_delete', '/_admin/my_account/emails/delete', []); |
|
290 | pyroutes.register('my_account_emails_delete', '/_admin/my_account/emails/delete', []); | |
289 | pyroutes.register('my_account_repos', '/_admin/my_account/repos', []); |
|
291 | pyroutes.register('my_account_repos', '/_admin/my_account/repos', []); | |
290 | pyroutes.register('my_account_watched', '/_admin/my_account/watched', []); |
|
292 | pyroutes.register('my_account_watched', '/_admin/my_account/watched', []); | |
291 | pyroutes.register('my_account_perms', '/_admin/my_account/perms', []); |
|
293 | pyroutes.register('my_account_perms', '/_admin/my_account/perms', []); | |
292 | pyroutes.register('my_account_notifications', '/_admin/my_account/notifications', []); |
|
294 | pyroutes.register('my_account_notifications', '/_admin/my_account/notifications', []); | |
293 | pyroutes.register('my_account_notifications_toggle_visibility', '/_admin/my_account/toggle_visibility', []); |
|
295 | pyroutes.register('my_account_notifications_toggle_visibility', '/_admin/my_account/toggle_visibility', []); | |
294 | pyroutes.register('my_account_pullrequests', '/_admin/my_account/pull_requests', []); |
|
296 | pyroutes.register('my_account_pullrequests', '/_admin/my_account/pull_requests', []); | |
295 | pyroutes.register('my_account_pullrequests_data', '/_admin/my_account/pull_requests/data', []); |
|
297 | pyroutes.register('my_account_pullrequests_data', '/_admin/my_account/pull_requests/data', []); | |
296 | pyroutes.register('notifications_show_all', '/_admin/notifications', []); |
|
298 | pyroutes.register('notifications_show_all', '/_admin/notifications', []); | |
297 | pyroutes.register('notifications_mark_all_read', '/_admin/notifications/mark_all_read', []); |
|
299 | pyroutes.register('notifications_mark_all_read', '/_admin/notifications/mark_all_read', []); | |
298 | pyroutes.register('notifications_show', '/_admin/notifications/%(notification_id)s', ['notification_id']); |
|
300 | pyroutes.register('notifications_show', '/_admin/notifications/%(notification_id)s', ['notification_id']); | |
299 | pyroutes.register('notifications_update', '/_admin/notifications/%(notification_id)s/update', ['notification_id']); |
|
301 | pyroutes.register('notifications_update', '/_admin/notifications/%(notification_id)s/update', ['notification_id']); | |
300 | pyroutes.register('notifications_delete', '/_admin/notifications/%(notification_id)s/delete', ['notification_id']); |
|
302 | pyroutes.register('notifications_delete', '/_admin/notifications/%(notification_id)s/delete', ['notification_id']); | |
301 | pyroutes.register('my_account_notifications_test_channelstream', '/_admin/my_account/test_channelstream', []); |
|
303 | pyroutes.register('my_account_notifications_test_channelstream', '/_admin/my_account/test_channelstream', []); | |
302 | pyroutes.register('gists_show', '/_admin/gists', []); |
|
304 | pyroutes.register('gists_show', '/_admin/gists', []); | |
303 | pyroutes.register('gists_new', '/_admin/gists/new', []); |
|
305 | pyroutes.register('gists_new', '/_admin/gists/new', []); | |
304 | pyroutes.register('gists_create', '/_admin/gists/create', []); |
|
306 | pyroutes.register('gists_create', '/_admin/gists/create', []); | |
305 | pyroutes.register('gist_show', '/_admin/gists/%(gist_id)s', ['gist_id']); |
|
307 | pyroutes.register('gist_show', '/_admin/gists/%(gist_id)s', ['gist_id']); | |
306 | pyroutes.register('gist_delete', '/_admin/gists/%(gist_id)s/delete', ['gist_id']); |
|
308 | pyroutes.register('gist_delete', '/_admin/gists/%(gist_id)s/delete', ['gist_id']); | |
307 | pyroutes.register('gist_edit', '/_admin/gists/%(gist_id)s/edit', ['gist_id']); |
|
309 | pyroutes.register('gist_edit', '/_admin/gists/%(gist_id)s/edit', ['gist_id']); | |
308 | pyroutes.register('gist_edit_check_revision', '/_admin/gists/%(gist_id)s/edit/check_revision', ['gist_id']); |
|
310 | pyroutes.register('gist_edit_check_revision', '/_admin/gists/%(gist_id)s/edit/check_revision', ['gist_id']); | |
309 | pyroutes.register('gist_update', '/_admin/gists/%(gist_id)s/update', ['gist_id']); |
|
311 | pyroutes.register('gist_update', '/_admin/gists/%(gist_id)s/update', ['gist_id']); | |
310 | pyroutes.register('gist_show_rev', '/_admin/gists/%(gist_id)s/%(revision)s', ['gist_id', 'revision']); |
|
312 | pyroutes.register('gist_show_rev', '/_admin/gists/%(gist_id)s/%(revision)s', ['gist_id', 'revision']); | |
311 | pyroutes.register('gist_show_formatted', '/_admin/gists/%(gist_id)s/%(revision)s/%(format)s', ['gist_id', 'revision', 'format']); |
|
313 | pyroutes.register('gist_show_formatted', '/_admin/gists/%(gist_id)s/%(revision)s/%(format)s', ['gist_id', 'revision', 'format']); | |
312 | pyroutes.register('gist_show_formatted_path', '/_admin/gists/%(gist_id)s/%(revision)s/%(format)s/%(f_path)s', ['gist_id', 'revision', 'format', 'f_path']); |
|
314 | pyroutes.register('gist_show_formatted_path', '/_admin/gists/%(gist_id)s/%(revision)s/%(format)s/%(f_path)s', ['gist_id', 'revision', 'format', 'f_path']); | |
313 | pyroutes.register('debug_style_home', '/_admin/debug_style', []); |
|
315 | pyroutes.register('debug_style_home', '/_admin/debug_style', []); | |
314 | pyroutes.register('debug_style_template', '/_admin/debug_style/t/%(t_path)s', ['t_path']); |
|
316 | pyroutes.register('debug_style_template', '/_admin/debug_style/t/%(t_path)s', ['t_path']); | |
315 | pyroutes.register('apiv2', '/_admin/api', []); |
|
317 | pyroutes.register('apiv2', '/_admin/api', []); | |
316 | } |
|
318 | } |
@@ -1,141 +1,109 b'' | |||||
1 |
|
1 | |||
2 | <div id="update_notice" style="display: none; margin: -40px 0px 20px 0px"> |
|
2 | <div id="update_notice" style="display: none; margin: -40px 0px 20px 0px"> | |
3 | <div>${_('Checking for updates...')}</div> |
|
3 | <div>${_('Checking for updates...')}</div> | |
4 | </div> |
|
4 | </div> | |
5 |
|
5 | |||
6 |
|
6 | |||
7 | <div class="panel panel-default"> |
|
7 | <div class="panel panel-default"> | |
8 | <div class="panel-heading"> |
|
8 | <div class="panel-heading"> | |
9 | <h3 class="panel-title">${_('Gunicorn process management')}</h3> |
|
9 | <h3 class="panel-title">${_('Gunicorn process management')}</h3> | |
10 |
|
10 | <div class="pull-right"> | ||
|
11 | <a id="autoRefreshEnable" href="#autoRefreshEnable" onclick="enableAutoRefresh(); return false">${_('start auto refresh')}</a> | |||
|
12 | <a id="autoRefreshDisable" href="#autoRefreshDisable" onclick="disableAutoRefresh(); return false" style="display: none">${_('stop auto refresh')}</a> | |||
|
13 | </div> | |||
11 | </div> |
|
14 | </div> | |
12 | <div class="panel-body" id="app"> |
|
15 | <div class="panel-body" id="app"> | |
13 | <h3>List of Gunicorn processes on this machine</h3> |
|
16 | <h3>List of Gunicorn processes on this machine</h3> | |
14 | <% |
|
17 | <% | |
15 | def get_name(proc): |
|
18 | def get_name(proc): | |
16 | cmd = ' '.join(proc.cmdline()) |
|
19 | cmd = ' '.join(proc.cmdline()) | |
17 | if 'vcsserver.ini' in cmd: |
|
20 | if 'vcsserver.ini' in cmd: | |
18 | return 'VCSServer' |
|
21 | return 'VCSServer' | |
19 | elif 'rhodecode.ini' in cmd: |
|
22 | elif 'rhodecode.ini' in cmd: | |
20 | return 'RhodeCode' |
|
23 | return 'RhodeCode' | |
21 | return proc.name() |
|
24 | return proc.name() | |
22 | %> |
|
25 | %> | |
23 | <table> |
|
26 | <%include file='settings_process_management_data.mako'/> | |
24 | % for proc in c.gunicorn_processes: |
|
|||
25 | <% mem = proc.memory_info()%> |
|
|||
26 | <% children = proc.children(recursive=True) %> |
|
|||
27 | % if children: |
|
|||
28 |
|
||||
29 | <tr> |
|
|||
30 | <td> |
|
|||
31 | <code> |
|
|||
32 | ${proc.pid} - ${get_name(proc)} |
|
|||
33 | </code> |
|
|||
34 | </td> |
|
|||
35 | <td> |
|
|||
36 | <a href="#showCommand" onclick="$('#pid'+${proc.pid}).toggle();return false"> command </a> |
|
|||
37 | <code id="pid${proc.pid}" style="display: none"> |
|
|||
38 | ${' '.join(proc.cmdline())} |
|
|||
39 | </code> |
|
|||
40 | </td> |
|
|||
41 | <td></td> |
|
|||
42 | <td> |
|
|||
43 | RSS:${h.format_byte_size_binary(mem.rss)} |
|
|||
44 | </td> |
|
|||
45 | <td> |
|
|||
46 | VMS:${h.format_byte_size_binary(mem.vms)} |
|
|||
47 | </td> |
|
|||
48 | <td> |
|
|||
49 | AGE: ${h.age_component(h.time_to_utcdatetime(proc.create_time()))} |
|
|||
50 | </td> |
|
|||
51 | <td> |
|
|||
52 | MASTER |
|
|||
53 | </td> |
|
|||
54 | </tr> |
|
|||
55 | <% mem_sum = 0 %> |
|
|||
56 | % for proc_child in children: |
|
|||
57 | <% mem = proc_child.memory_info()%> |
|
|||
58 | <tr> |
|
|||
59 | <td> |
|
|||
60 | <code> |
|
|||
61 | | ${proc_child.pid} - ${get_name(proc_child)} |
|
|||
62 | </code> |
|
|||
63 | </td> |
|
|||
64 | <td> |
|
|||
65 | <a href="#showCommand" onclick="$('#pid'+${proc_child.pid}).toggle();return false"> command </a> |
|
|||
66 | <code id="pid${proc_child.pid}" style="display: none"> |
|
|||
67 | ${' '.join(proc_child.cmdline())} |
|
|||
68 | </code> |
|
|||
69 | </td> |
|
|||
70 | <td> |
|
|||
71 | CPU: ${proc_child.cpu_percent()} % |
|
|||
72 | </td> |
|
|||
73 | <td> |
|
|||
74 | RSS:${h.format_byte_size_binary(mem.rss)} |
|
|||
75 | <% mem_sum += mem.rss %> |
|
|||
76 | </td> |
|
|||
77 | <td> |
|
|||
78 | VMS:${h.format_byte_size_binary(mem.vms)} |
|
|||
79 | </td> |
|
|||
80 | <td> |
|
|||
81 | AGE: ${h.age_component(h.time_to_utcdatetime(proc_child.create_time()))} |
|
|||
82 | </td> |
|
|||
83 | <td> |
|
|||
84 | <a href="#restartProcess" onclick="restart(this, ${proc_child.pid});return false"> |
|
|||
85 | restart |
|
|||
86 | </a> |
|
|||
87 | </td> |
|
|||
88 | </tr> |
|
|||
89 | % endfor |
|
|||
90 | <tr> |
|
|||
91 | <td colspan="2"><code>| total processes: ${len(children)}</code></td> |
|
|||
92 | <td></td> |
|
|||
93 | <td><strong>RSS:${h.format_byte_size_binary(mem_sum)}</strong></td> |
|
|||
94 | <td></td> |
|
|||
95 | </tr> |
|
|||
96 | <tr><td> <code> -- </code> </td></tr> |
|
|||
97 |
|
||||
98 | % endif |
|
|||
99 | % endfor |
|
|||
100 | </table> |
|
|||
101 | </div> |
|
27 | </div> | |
102 | </div> |
|
28 | </div> | |
103 |
|
29 | |||
104 |
|
||||
105 | <script> |
|
30 | <script> | |
106 |
|
31 | |||
107 |
|
32 | |||
108 | restart = function(elem, pid) { |
|
33 | restart = function(elem, pid) { | |
109 |
|
34 | |||
110 | if ($(elem).hasClass('disabled')){ |
|
35 | if ($(elem).hasClass('disabled')){ | |
111 | return; |
|
36 | return; | |
112 | } |
|
37 | } | |
113 | $(elem).addClass('disabled'); |
|
38 | $(elem).addClass('disabled'); | |
114 | $(elem).html('processing...'); |
|
39 | $(elem).html('processing...'); | |
115 |
|
40 | |||
116 | $.ajax({ |
|
41 | $.ajax({ | |
117 | url: pyroutes.url('admin_settings_process_management_signal'), |
|
42 | url: pyroutes.url('admin_settings_process_management_signal'), | |
118 | headers: { |
|
43 | headers: { | |
119 | "X-CSRF-Token": CSRF_TOKEN, |
|
44 | "X-CSRF-Token": CSRF_TOKEN, | |
120 | }, |
|
45 | }, | |
121 | data: JSON.stringify({'pids': [pid]}), |
|
46 | data: JSON.stringify({'pids': [pid]}), | |
122 | dataType: 'json', |
|
47 | dataType: 'json', | |
123 | type: 'POST', |
|
48 | type: 'POST', | |
124 | contentType: "application/json; charset=utf-8", |
|
49 | contentType: "application/json; charset=utf-8", | |
125 | success: function (data) { |
|
50 | success: function (data) { | |
126 | $(elem).html(data.result); |
|
51 | $(elem).html(data.result); | |
127 | $(elem).removeClass('disabled'); |
|
52 | $(elem).removeClass('disabled'); | |
128 | }, |
|
53 | }, | |
129 | failure: function (data) { |
|
54 | failure: function (data) { | |
130 | $(elem).text('FAILED TO LOAD RESULT'); |
|
55 | $(elem).text('FAILED TO LOAD RESULT'); | |
131 | $(elem).removeClass('disabled'); |
|
56 | $(elem).removeClass('disabled'); | |
132 | }, |
|
57 | }, | |
133 | error: function (data) { |
|
58 | error: function (data) { | |
134 | $(elem).text('FAILED TO LOAD RESULT'); |
|
59 | $(elem).text('FAILED TO LOAD RESULT'); | |
135 | $(elem).removeClass('disabled'); |
|
60 | $(elem).removeClass('disabled'); | |
136 | } |
|
61 | } | |
137 | }) |
|
62 | }) | |
|
63 | }; | |||
|
64 | ||||
|
65 | var intervalID = null; | |||
|
66 | var currentRequest = null; | |||
|
67 | ||||
|
68 | autoRefresh = function(value) { | |||
|
69 | var url = pyroutes.url('admin_settings_process_management_data'); | |||
|
70 | var loadData = function() { | |||
|
71 | currentRequest = $.get(url) | |||
|
72 | .done(function(data) { | |||
|
73 | currentRequest = null; | |||
|
74 | $('#procList').html(data); | |||
|
75 | timeagoActivate(); | |||
|
76 | var beat = function(doCallback) { | |||
|
77 | var callback = function () {}; | |||
|
78 | if (doCallback){ | |||
|
79 | var callback = function () {beat(false)}; | |||
138 | } |
|
80 | } | |
|
81 | $('#processTimeStamp').animate({ | |||
|
82 | opacity: $('#processTimeStamp').css('opacity') == '1' ? '0.3' : '1' | |||
|
83 | }, 500, callback); | |||
|
84 | }; | |||
|
85 | beat(true) | |||
|
86 | }); | |||
|
87 | }; | |||
|
88 | ||||
|
89 | if (value) { | |||
|
90 | intervalID = setInterval(loadData, 5000); | |||
|
91 | } else { | |||
|
92 | clearInterval(intervalID); | |||
|
93 | } | |||
|
94 | }; | |||
|
95 | ||||
|
96 | enableAutoRefresh = function() { | |||
|
97 | $('#autoRefreshEnable').hide(); | |||
|
98 | $('#autoRefreshDisable').show(); | |||
|
99 | autoRefresh(true) | |||
|
100 | }; | |||
|
101 | ||||
|
102 | disableAutoRefresh = function() { | |||
|
103 | $('#autoRefreshEnable').show(); | |||
|
104 | $('#autoRefreshDisable').hide(); | |||
|
105 | autoRefresh(false) | |||
|
106 | }; | |||
139 |
|
107 | |||
140 |
|
108 | |||
141 | </script> |
|
109 | </script> |
General Comments 0
You need to be logged in to leave comments.
Login now