##// END OF EJS Templates
added uwsgi config into mako ini template
marcink -
r4067:20c21b8f default
parent child Browse files
Show More
@@ -1,548 +1,601 b''
1 ## -*- coding: utf-8 -*-
1 ## -*- coding: utf-8 -*-
2 <%text>
2 <%text>
3 ################################################################################
3 ################################################################################
4 ################################################################################
4 ################################################################################
5 # RhodeCode - Example config #
5 # RhodeCode - Example config #
6 # Built-in functions and variables #
6 # Built-in functions and variables #
7 # The ${here} variable will be replaced with the parent directory of this file #
7 # The ${here} variable will be replaced with the parent directory of this file #
8 # ${uuid()} function will generate a unique hash #
8 # ${uuid()} function will generate a unique hash #
9 ################################################################################
9 ################################################################################
10 </%text>
10 </%text>
11 [DEFAULT]
11 [DEFAULT]
12 debug = true
12 debug = true
13 pdebug = false
13 pdebug = false
14 <%text>
14 <%text>
15 ################################################################################
15 ################################################################################
16 ## Uncomment and replace with the address which should receive ##
16 ## Uncomment and replace with the address which should receive ##
17 ## any error reports after application crash ##
17 ## any error reports after application crash ##
18 ## Additionally those settings will be used by RhodeCode mailing system ##
18 ## Additionally those settings will be used by RhodeCode mailing system ##
19 ################################################################################
19 ################################################################################
20 </%text>
20 </%text>
21 #email_to = admin@localhost
21 #email_to = admin@localhost
22 #error_email_from = paste_error@localhost
22 #error_email_from = paste_error@localhost
23 #app_email_from = rhodecode-noreply@localhost
23 #app_email_from = rhodecode-noreply@localhost
24 #error_message =
24 #error_message =
25 #email_prefix = [RhodeCode]
25 #email_prefix = [RhodeCode]
26
26
27 #smtp_server = mail.server.com
27 #smtp_server = mail.server.com
28 #smtp_username =
28 #smtp_username =
29 #smtp_password =
29 #smtp_password =
30 #smtp_port =
30 #smtp_port =
31 #smtp_use_tls = false
31 #smtp_use_tls = false
32 #smtp_use_ssl = true
32 #smtp_use_ssl = true
33 <%text>## Specify available auth parameters here (e.g. LOGIN PLAIN CRAM-MD5, etc.)</%text>
33 <%text>## Specify available auth parameters here (e.g. LOGIN PLAIN CRAM-MD5, etc.)</%text>
34 #smtp_auth =
34 #smtp_auth =
35
35
36 [server:main]
36 [server:main]
37 %if http_server == 'paste':
37 %if http_server == 'paste':
38 <%text>## PASTE ##</%text>
38 <%text>## PASTE ##</%text>
39 use = egg:Paste#http
39 use = egg:Paste#http
40 <%text>## nr of worker threads to spawn</%text>
40 <%text>## nr of worker threads to spawn</%text>
41 threadpool_workers = 5
41 threadpool_workers = 5
42 <%text>## max request before thread respawn</%text>
42 <%text>## max request before thread respawn</%text>
43 threadpool_max_requests = 10
43 threadpool_max_requests = 10
44 <%text>## option to use threads of process</%text>
44 <%text>## option to use threads of process</%text>
45 use_threadpool = true
45 use_threadpool = true
46 %endif
46 %endif
47 %if http_server == 'waitress':
47 %if http_server == 'waitress':
48 <%text>## WAITRESS ##</%text>
48 <%text>## WAITRESS ##</%text>
49 use = egg:waitress#main
49 use = egg:waitress#main
50 <%text>## number of worker threads</%text>
50 <%text>## number of worker threads</%text>
51 threads = 5
51 threads = 5
52 <%text>## MAX BODY SIZE 100GB</%text>
52 <%text>## MAX BODY SIZE 100GB</%text>
53 max_request_body_size = 107374182400
53 max_request_body_size = 107374182400
54 <%text>## use poll instead of select, fixes fd limits, may not work on old</%text>
54 <%text>## use poll instead of select, fixes fd limits, may not work on old</%text>
55 <%text>## windows systems.</%text>
55 <%text>## windows systems.</%text>
56 #asyncore_use_poll = True
56 #asyncore_use_poll = True
57 %endif
57 %endif
58 %if http_server == 'gunicorn':
58 %if http_server == 'gunicorn':
59 <%text>## GUNICORN ##</%text>
59 <%text>## GUNICORN ##</%text>
60 use = egg:gunicorn#main
60 use = egg:gunicorn#main
61 <%text>## number of process workers. You must set `instance_id = *` when this option</%text>
61 <%text>## number of process workers. You must set `instance_id = *` when this option</%text>
62 <%text>## is set to more than one worker</%text>
62 <%text>## is set to more than one worker</%text>
63 workers = 1
63 workers = 1
64 <%text>## process name</%text>
64 <%text>## process name</%text>
65 proc_name = rhodecode
65 proc_name = rhodecode
66 <%text>## type of worker class, one of sync, eventlet, gevent, tornado</%text>
66 <%text>## type of worker class, one of sync, eventlet, gevent, tornado</%text>
67 <%text>## recommended for bigger setup is using of of other than sync one</%text>
67 <%text>## recommended for bigger setup is using of of other than sync one</%text>
68 worker_class = sync
68 worker_class = sync
69 max_requests = 1000
69 max_requests = 1000
70 <%text>## ammount of time a worker can handle request before it get's killed and</%text>
70 <%text>## ammount of time a worker can handle request before it get's killed and</%text>
71 <%text>## restarted</%text>
71 <%text>## restarted</%text>
72 timeout = 3600
72 timeout = 3600
73 %endif
73 %endif
74 %if http_server == 'uwsgi':
75 <%text>## UWSGI ##</%text>
76 <%text>## run with uwsgi --ini-paste-logged <inifile.ini></%text>
77 [uwsgi]
78 socket = /tmp/uwsgi.sock
79 master = true
80 http = 0.0.0.0:5000
81
82 <%text>## set as deamon and redirect all output to file</%text>
83 #daemonize = ./uwsgi_rhodecode.log
84
85 <%text>## master process PID</%text>
86 pidfile = ./uwsgi_rhodecode.pid
87
88 <%text>## stats server with workers statistics, use uwsgitop</%text>
89 <%text>## for monitoring</%text>
90 stats = 127.0.0.1:1717
91
92 <%text>## log 5XX errors</%text>
93 log-5xx = true
94
95 <%text>## Set the socket listen queue size.</%text>
96 listen = 256
97
98 <%text>## Gracefully Reload workers after the specified amount of managed requests</%text>
99 <%text>## (avoid memory leaks).</%text>
100 max-requests = 1000
101
102 <%text>## Log requests slower than the specified number of milliseconds.</%text>
103 log-slow = 10
104
105 <%text>## Exit if no app can be loaded.</%text>
106 need-app = true
107
108 <%text>## Set lazy mode (load apps in workers instead of master).</%text>
109 lazy = true
110
111 <%text>## scaling ##</%text>
112 <%text>## set cheaper algorithm to use, if not set default will be used</%text>
113 cheaper-algo = spare
114
115 <%text>## minimum number of workers to keep at all times</%text>
116 cheaper = 1
117
118 <%text>## number of workers to spawn at startup</%text>
119 cheaper-initial = 1
120
121 <%text>## maximum number of workers that can be spawned</%text>
122 workers = 4
123
124 <%text>## how many workers should be spawned at a time</%text>
125 cheaper-step = 1
126 %endif
74 <%text>## COMMON ##</%text>
127 <%text>## COMMON ##</%text>
75 host = ${host}
128 host = ${host}
76 port = ${port}
129 port = ${port}
77
130
78 <%text>## prefix middleware for rc</%text>
131 <%text>## prefix middleware for rc</%text>
79 #[filter:proxy-prefix]
132 #[filter:proxy-prefix]
80 #use = egg:PasteDeploy#prefix
133 #use = egg:PasteDeploy#prefix
81 #prefix = /<your-prefix>
134 #prefix = /<your-prefix>
82
135
83 [app:main]
136 [app:main]
84 use = egg:rhodecode
137 use = egg:rhodecode
85 <%text>## enable proxy prefix middleware</%text>
138 <%text>## enable proxy prefix middleware</%text>
86 #filter-with = proxy-prefix
139 #filter-with = proxy-prefix
87
140
88 full_stack = true
141 full_stack = true
89 static_files = true
142 static_files = true
90 <%text>## Optional Languages</%text>
143 <%text>## Optional Languages</%text>
91 <%text>## en, fr, ja, pt_BR, zh_CN, zh_TW, pl, ru</%text>
144 <%text>## en, fr, ja, pt_BR, zh_CN, zh_TW, pl, ru</%text>
92 lang = ${lang}
145 lang = ${lang}
93 cache_dir = ${here}/data
146 cache_dir = ${here}/data
94 index_dir = ${here}/data/index
147 index_dir = ${here}/data/index
95
148
96 <%text>## perform a full repository scan on each server start, this should be</%text>
149 <%text>## perform a full repository scan on each server start, this should be</%text>
97 <%text>## set to false after first startup, to allow faster server restarts.</%text>
150 <%text>## set to false after first startup, to allow faster server restarts.</%text>
98 initial_repo_scan = false
151 initial_repo_scan = false
99
152
100 <%text>## uncomment and set this path to use archive download cache</%text>
153 <%text>## uncomment and set this path to use archive download cache</%text>
101 archive_cache_dir = ${here}/tarballcache
154 archive_cache_dir = ${here}/tarballcache
102
155
103 <%text>## change this to unique ID for security</%text>
156 <%text>## change this to unique ID for security</%text>
104 app_instance_uuid = ${uuid()}
157 app_instance_uuid = ${uuid()}
105
158
106 <%text>## cut off limit for large diffs (size in bytes)</%text>
159 <%text>## cut off limit for large diffs (size in bytes)</%text>
107 cut_off_limit = 256000
160 cut_off_limit = 256000
108
161
109 <%text>## use cache version of scm repo everywhere</%text>
162 <%text>## use cache version of scm repo everywhere</%text>
110 vcs_full_cache = true
163 vcs_full_cache = true
111
164
112 <%text>## force https in RhodeCode, fixes https redirects, assumes it's always https</%text>
165 <%text>## force https in RhodeCode, fixes https redirects, assumes it's always https</%text>
113 force_https = false
166 force_https = false
114
167
115 <%text>## use Strict-Transport-Security headers</%text>
168 <%text>## use Strict-Transport-Security headers</%text>
116 use_htsts = false
169 use_htsts = false
117
170
118 <%text>## number of commits stats will parse on each iteration</%text>
171 <%text>## number of commits stats will parse on each iteration</%text>
119 commit_parse_limit = 25
172 commit_parse_limit = 25
120
173
121 <%text>## use gravatar service to display avatars</%text>
174 <%text>## use gravatar service to display avatars</%text>
122 use_gravatar = true
175 use_gravatar = true
123
176
124 <%text>## path to git executable</%text>
177 <%text>## path to git executable</%text>
125 git_path = git
178 git_path = git
126
179
127 <%text>## git rev filter option, --all is the default filter, if you need to</%text>
180 <%text>## git rev filter option, --all is the default filter, if you need to</%text>
128 <%text>## hide all refs in changelog switch this to --branches --tags</%text>
181 <%text>## hide all refs in changelog switch this to --branches --tags</%text>
129 git_rev_filter=--branches --tags
182 git_rev_filter=--branches --tags
130
183
131 <%text>## RSS feed options</%text>
184 <%text>## RSS feed options</%text>
132 rss_cut_off_limit = 256000
185 rss_cut_off_limit = 256000
133 rss_items_per_page = 10
186 rss_items_per_page = 10
134 rss_include_diff = false
187 rss_include_diff = false
135
188
136 <%text>## options for showing and identifying changesets</%text>
189 <%text>## options for showing and identifying changesets</%text>
137 show_sha_length = 12
190 show_sha_length = 12
138 show_revision_number = true
191 show_revision_number = true
139
192
140 <%text>## gist URL alias, used to create nicer urls for gist. This should be an</%text>
193 <%text>## gist URL alias, used to create nicer urls for gist. This should be an</%text>
141 <%text>## url that does rewrites to _admin/gists/<gistid>.</%text>
194 <%text>## url that does rewrites to _admin/gists/<gistid>.</%text>
142 <%text>## example: http://gist.rhodecode.org/{gistid}. Empty means use the internal</%text>
195 <%text>## example: http://gist.rhodecode.org/{gistid}. Empty means use the internal</%text>
143 <%text>## RhodeCode url, ie. http[s]://rhodecode.server/_admin/gists/<gistid></%text>
196 <%text>## RhodeCode url, ie. http[s]://rhodecode.server/_admin/gists/<gistid></%text>
144 gist_alias_url =
197 gist_alias_url =
145
198
146 <%text>## white list of API enabled controllers. This allows to add list of</%text>
199 <%text>## white list of API enabled controllers. This allows to add list of</%text>
147 <%text>## controllers to which access will be enabled by api_key. eg: to enable</%text>
200 <%text>## controllers to which access will be enabled by api_key. eg: to enable</%text>
148 <%text>## api access to raw_files put `FilesController:raw`, to enable access to patches</%text>
201 <%text>## api access to raw_files put `FilesController:raw`, to enable access to patches</%text>
149 <%text>## add `ChangesetController:changeset_patch`. This list should be "," separated</%text>
202 <%text>## add `ChangesetController:changeset_patch`. This list should be "," separated</%text>
150 <%text>## Syntax is <ControllerClass>:<function>. Check debug logs for generated names</%text>
203 <%text>## Syntax is <ControllerClass>:<function>. Check debug logs for generated names</%text>
151 api_access_controllers_whitelist =
204 api_access_controllers_whitelist =
152
205
153 <%text>## alternative_gravatar_url allows you to use your own avatar server application</%text>
206 <%text>## alternative_gravatar_url allows you to use your own avatar server application</%text>
154 <%text>## the following parts of the URL will be replaced</%text>
207 <%text>## the following parts of the URL will be replaced</%text>
155 <%text>## {email} user email</%text>
208 <%text>## {email} user email</%text>
156 <%text>## {md5email} md5 hash of the user email (like at gravatar.com)</%text>
209 <%text>## {md5email} md5 hash of the user email (like at gravatar.com)</%text>
157 <%text>## {size} size of the image that is expected from the server application</%text>
210 <%text>## {size} size of the image that is expected from the server application</%text>
158 <%text>## {scheme} http/https from RhodeCode server</%text>
211 <%text>## {scheme} http/https from RhodeCode server</%text>
159 <%text>## {netloc} network location from RhodeCode server</%text>
212 <%text>## {netloc} network location from RhodeCode server</%text>
160 #alternative_gravatar_url = http://myavatarserver.com/getbyemail/{email}/{size}
213 #alternative_gravatar_url = http://myavatarserver.com/getbyemail/{email}/{size}
161 #alternative_gravatar_url = http://myavatarserver.com/getbymd5/{md5email}?s={size}
214 #alternative_gravatar_url = http://myavatarserver.com/getbymd5/{md5email}?s={size}
162
215
163
216
164 <%text>## container auth options</%text>
217 <%text>## container auth options</%text>
165 container_auth_enabled = false
218 container_auth_enabled = false
166 proxypass_auth_enabled = false
219 proxypass_auth_enabled = false
167
220
168 <%text>## default encoding used to convert from and to unicode</%text>
221 <%text>## default encoding used to convert from and to unicode</%text>
169 <%text>## can be also a comma seperated list of encoding in case of mixed encodings</%text>
222 <%text>## can be also a comma seperated list of encoding in case of mixed encodings</%text>
170 default_encoding = utf8
223 default_encoding = utf8
171
224
172 <%text>## overwrite schema of clone url</%text>
225 <%text>## overwrite schema of clone url</%text>
173 <%text>## available vars:</%text>
226 <%text>## available vars:</%text>
174 <%text>## scheme - http/https</%text>
227 <%text>## scheme - http/https</%text>
175 <%text>## user - current user</%text>
228 <%text>## user - current user</%text>
176 <%text>## pass - password</%text>
229 <%text>## pass - password</%text>
177 <%text>## netloc - network location</%text>
230 <%text>## netloc - network location</%text>
178 <%text>## path - usually repo_name</%text>
231 <%text>## path - usually repo_name</%text>
179
232
180 #clone_uri = {scheme}://{user}{pass}{netloc}{path}
233 #clone_uri = {scheme}://{user}{pass}{netloc}{path}
181
234
182 <%text>## issue tracker for RhodeCode (leave blank to disable, absent for default)</%text>
235 <%text>## issue tracker for RhodeCode (leave blank to disable, absent for default)</%text>
183 #bugtracker = http://bitbucket.org/marcinkuzminski/rhodecode/issues
236 #bugtracker = http://bitbucket.org/marcinkuzminski/rhodecode/issues
184
237
185 <%text>## issue tracking mapping for commits messages</%text>
238 <%text>## issue tracking mapping for commits messages</%text>
186 <%text>## comment out issue_pat, issue_server, issue_prefix to enable</%text>
239 <%text>## comment out issue_pat, issue_server, issue_prefix to enable</%text>
187
240
188 <%text>## pattern to get the issues from commit messages</%text>
241 <%text>## pattern to get the issues from commit messages</%text>
189 <%text>## default one used here is #<numbers> with a regex passive group for `#`</%text>
242 <%text>## default one used here is #<numbers> with a regex passive group for `#`</%text>
190 <%text>## {id} will be all groups matched from this pattern</%text>
243 <%text>## {id} will be all groups matched from this pattern</%text>
191
244
192 issue_pat = (?:\s*#)(\d+)
245 issue_pat = (?:\s*#)(\d+)
193
246
194 <%text>## server url to the issue, each {id} will be replaced with match</%text>
247 <%text>## server url to the issue, each {id} will be replaced with match</%text>
195 <%text>## fetched from the regex and {repo} is replaced with full repository name</%text>
248 <%text>## fetched from the regex and {repo} is replaced with full repository name</%text>
196 <%text>## including groups {repo_name} is replaced with just name of repo</%text>
249 <%text>## including groups {repo_name} is replaced with just name of repo</%text>
197
250
198 issue_server_link = https://myissueserver.com/{repo}/issue/{id}
251 issue_server_link = https://myissueserver.com/{repo}/issue/{id}
199
252
200 <%text>## prefix to add to link to indicate it's an url</%text>
253 <%text>## prefix to add to link to indicate it's an url</%text>
201 <%text>## #314 will be replaced by <issue_prefix><id></%text>
254 <%text>## #314 will be replaced by <issue_prefix><id></%text>
202
255
203 issue_prefix = #
256 issue_prefix = #
204
257
205 <%text>## issue_pat, issue_server_link, issue_prefix can have suffixes to specify</%text>
258 <%text>## issue_pat, issue_server_link, issue_prefix can have suffixes to specify</%text>
206 <%text>## multiple patterns, to other issues server, wiki or others</%text>
259 <%text>## multiple patterns, to other issues server, wiki or others</%text>
207 <%text>## below an example how to create a wiki pattern</%text>
260 <%text>## below an example how to create a wiki pattern</%text>
208 <%text>## wiki-some-id -> https://mywiki.com/some-id</%text>
261 <%text>## wiki-some-id -> https://mywiki.com/some-id</%text>
209
262
210 #issue_pat_wiki = (?:wiki-)(.+)
263 #issue_pat_wiki = (?:wiki-)(.+)
211 #issue_server_link_wiki = https://mywiki.com/{id}
264 #issue_server_link_wiki = https://mywiki.com/{id}
212 #issue_prefix_wiki = WIKI-
265 #issue_prefix_wiki = WIKI-
213
266
214
267
215 <%text>## instance-id prefix</%text>
268 <%text>## instance-id prefix</%text>
216 <%text>## a prefix key for this instance used for cache invalidation when running</%text>
269 <%text>## a prefix key for this instance used for cache invalidation when running</%text>
217 <%text>## multiple instances of rhodecode, make sure it's globally unique for</%text>
270 <%text>## multiple instances of rhodecode, make sure it's globally unique for</%text>
218 <%text>## all running rhodecode instances. Leave empty if you don't use it</%text>
271 <%text>## all running rhodecode instances. Leave empty if you don't use it</%text>
219 instance_id =
272 instance_id =
220
273
221 <%text>## alternative return HTTP header for failed authentication. Default HTTP</%text>
274 <%text>## alternative return HTTP header for failed authentication. Default HTTP</%text>
222 <%text>## response is 401 HTTPUnauthorized. Currently HG clients have troubles with</%text>
275 <%text>## response is 401 HTTPUnauthorized. Currently HG clients have troubles with</%text>
223 <%text>## handling that. Set this variable to 403 to return HTTPForbidden</%text>
276 <%text>## handling that. Set this variable to 403 to return HTTPForbidden</%text>
224 auth_ret_code =
277 auth_ret_code =
225
278
226 <%text>## locking return code. When repository is locked return this HTTP code. 2XX</%text>
279 <%text>## locking return code. When repository is locked return this HTTP code. 2XX</%text>
227 <%text>## codes don't break the transactions while 4XX codes do</%text>
280 <%text>## codes don't break the transactions while 4XX codes do</%text>
228 lock_ret_code = 423
281 lock_ret_code = 423
229
282
230 <%text>## allows to change the repository location in settings page</%text>
283 <%text>## allows to change the repository location in settings page</%text>
231 allow_repo_location_change = True
284 allow_repo_location_change = True
232
285
233 <%text>## allows to setup custom hooks in settings page</%text>
286 <%text>## allows to setup custom hooks in settings page</%text>
234 allow_custom_hooks_settings = True
287 allow_custom_hooks_settings = True
235
288
236 <%text>
289 <%text>
237 ####################################
290 ####################################
238 ### CELERY CONFIG ####
291 ### CELERY CONFIG ####
239 ####################################
292 ####################################
240 </%text>
293 </%text>
241 use_celery = false
294 use_celery = false
242 broker.host = localhost
295 broker.host = localhost
243 broker.vhost = rabbitmqhost
296 broker.vhost = rabbitmqhost
244 broker.port = 5672
297 broker.port = 5672
245 broker.user = rabbitmq
298 broker.user = rabbitmq
246 broker.password = qweqwe
299 broker.password = qweqwe
247
300
248 celery.imports = rhodecode.lib.celerylib.tasks
301 celery.imports = rhodecode.lib.celerylib.tasks
249
302
250 celery.result.backend = amqp
303 celery.result.backend = amqp
251 celery.result.dburi = amqp://
304 celery.result.dburi = amqp://
252 celery.result.serialier = json
305 celery.result.serialier = json
253
306
254 #celery.send.task.error.emails = true
307 #celery.send.task.error.emails = true
255 #celery.amqp.task.result.expires = 18000
308 #celery.amqp.task.result.expires = 18000
256
309
257 celeryd.concurrency = 2
310 celeryd.concurrency = 2
258 #celeryd.log.file = celeryd.log
311 #celeryd.log.file = celeryd.log
259 celeryd.log.level = debug
312 celeryd.log.level = debug
260 celeryd.max.tasks.per.child = 1
313 celeryd.max.tasks.per.child = 1
261
314
262 <%text>## tasks will never be sent to the queue, but executed locally instead.</%text>
315 <%text>## tasks will never be sent to the queue, but executed locally instead.</%text>
263 celery.always.eager = false
316 celery.always.eager = false
264 <%text>
317 <%text>
265 ####################################
318 ####################################
266 ### BEAKER CACHE ####
319 ### BEAKER CACHE ####
267 ####################################
320 ####################################
268 </%text>
321 </%text>
269 beaker.cache.data_dir=${here}/data/cache/data
322 beaker.cache.data_dir=${here}/data/cache/data
270 beaker.cache.lock_dir=${here}/data/cache/lock
323 beaker.cache.lock_dir=${here}/data/cache/lock
271
324
272 beaker.cache.regions=super_short_term,short_term,long_term,sql_cache_short,sql_cache_med,sql_cache_long
325 beaker.cache.regions=super_short_term,short_term,long_term,sql_cache_short,sql_cache_med,sql_cache_long
273
326
274 beaker.cache.super_short_term.type=memory
327 beaker.cache.super_short_term.type=memory
275 beaker.cache.super_short_term.expire=10
328 beaker.cache.super_short_term.expire=10
276 beaker.cache.super_short_term.key_length = 256
329 beaker.cache.super_short_term.key_length = 256
277
330
278 beaker.cache.short_term.type=memory
331 beaker.cache.short_term.type=memory
279 beaker.cache.short_term.expire=60
332 beaker.cache.short_term.expire=60
280 beaker.cache.short_term.key_length = 256
333 beaker.cache.short_term.key_length = 256
281
334
282 beaker.cache.long_term.type=memory
335 beaker.cache.long_term.type=memory
283 beaker.cache.long_term.expire=36000
336 beaker.cache.long_term.expire=36000
284 beaker.cache.long_term.key_length = 256
337 beaker.cache.long_term.key_length = 256
285
338
286 beaker.cache.sql_cache_short.type=memory
339 beaker.cache.sql_cache_short.type=memory
287 beaker.cache.sql_cache_short.expire=10
340 beaker.cache.sql_cache_short.expire=10
288 beaker.cache.sql_cache_short.key_length = 256
341 beaker.cache.sql_cache_short.key_length = 256
289
342
290 beaker.cache.sql_cache_med.type=memory
343 beaker.cache.sql_cache_med.type=memory
291 beaker.cache.sql_cache_med.expire=360
344 beaker.cache.sql_cache_med.expire=360
292 beaker.cache.sql_cache_med.key_length = 256
345 beaker.cache.sql_cache_med.key_length = 256
293
346
294 beaker.cache.sql_cache_long.type=file
347 beaker.cache.sql_cache_long.type=file
295 beaker.cache.sql_cache_long.expire=3600
348 beaker.cache.sql_cache_long.expire=3600
296 beaker.cache.sql_cache_long.key_length = 256
349 beaker.cache.sql_cache_long.key_length = 256
297 <%text>
350 <%text>
298 ####################################
351 ####################################
299 ### BEAKER SESSION ####
352 ### BEAKER SESSION ####
300 ####################################
353 ####################################
301 ## Type of storage used for the session, current types are
354 ## Type of storage used for the session, current types are
302 ## dbm, file, memcached, database, and memory.
355 ## dbm, file, memcached, database, and memory.
303 ## The storage uses the Container API
356 ## The storage uses the Container API
304 ## that is also used by the cache system.
357 ## that is also used by the cache system.
305 </%text>
358 </%text>
306 <%text>## db session ##</%text>
359 <%text>## db session ##</%text>
307 #beaker.session.type = ext:database
360 #beaker.session.type = ext:database
308 #beaker.session.sa.url = postgresql://postgres:qwe@localhost/rhodecode
361 #beaker.session.sa.url = postgresql://postgres:qwe@localhost/rhodecode
309 #beaker.session.table_name = db_session
362 #beaker.session.table_name = db_session
310
363
311 <%text>## encrypted cookie client side session, good for many instances ##</%text>
364 <%text>## encrypted cookie client side session, good for many instances ##</%text>
312 #beaker.session.type = cookie
365 #beaker.session.type = cookie
313
366
314 <%text>## file based cookies (default) ##</%text>
367 <%text>## file based cookies (default) ##</%text>
315 #beaker.session.type = file
368 #beaker.session.type = file
316
369
317 beaker.session.key = rhodecode
370 beaker.session.key = rhodecode
318 beaker.session.secret = ${uuid()}
371 beaker.session.secret = ${uuid()}
319
372
320 <%text>## Secure encrypted cookie. Requires AES and AES python libraries</%text>
373 <%text>## Secure encrypted cookie. Requires AES and AES python libraries</%text>
321 <%text>## you must disable beaker.session.secret to use this</%text>
374 <%text>## you must disable beaker.session.secret to use this</%text>
322 #beaker.session.encrypt_key = <key_for_encryption>
375 #beaker.session.encrypt_key = <key_for_encryption>
323 #beaker.session.validate_key = <validation_key>
376 #beaker.session.validate_key = <validation_key>
324
377
325 <%text>## sets session as invalid if it haven't been accessed for given amount of time</%text>
378 <%text>## sets session as invalid if it haven't been accessed for given amount of time</%text>
326 beaker.session.timeout = 2592000
379 beaker.session.timeout = 2592000
327 beaker.session.httponly = true
380 beaker.session.httponly = true
328 #beaker.session.cookie_path = /<your-prefix>
381 #beaker.session.cookie_path = /<your-prefix>
329
382
330 <%text>## uncomment for https secure cookie</%text>
383 <%text>## uncomment for https secure cookie</%text>
331 beaker.session.secure = false
384 beaker.session.secure = false
332
385
333 <%text>## auto save the session to not to use .save()</%text>
386 <%text>## auto save the session to not to use .save()</%text>
334 beaker.session.auto = False
387 beaker.session.auto = False
335
388
336 <%text>## default cookie expiration time in seconds `true` expire at browser close ##</%text>
389 <%text>## default cookie expiration time in seconds `true` expire at browser close ##</%text>
337 #beaker.session.cookie_expires = 3600
390 #beaker.session.cookie_expires = 3600
338
391
339 %if error_aggregation_service == 'errormator':
392 %if error_aggregation_service == 'errormator':
340 <%text>
393 <%text>
341 ############################
394 ############################
342 ## ERROR HANDLING SYSTEMS ##
395 ## ERROR HANDLING SYSTEMS ##
343 ############################
396 ############################
344
397
345 ####################
398 ####################
346 ### [errormator] ###
399 ### [errormator] ###
347 ####################
400 ####################
348
401
349 ## Errormator is tailored to work with RhodeCode, see
402 ## Errormator is tailored to work with RhodeCode, see
350 ## http://errormator.com for details how to obtain an account
403 ## http://errormator.com for details how to obtain an account
351 ## you must install python package `errormator_client` to make it work
404 ## you must install python package `errormator_client` to make it work
352 </%text>
405 </%text>
353 <%text>## errormator enabled</%text>
406 <%text>## errormator enabled</%text>
354 errormator = false
407 errormator = false
355
408
356 errormator.server_url = https://api.errormator.com
409 errormator.server_url = https://api.errormator.com
357 errormator.api_key = YOUR_API_KEY
410 errormator.api_key = YOUR_API_KEY
358
411
359 <%text>## TWEAK AMOUNT OF INFO SENT HERE</%text>
412 <%text>## TWEAK AMOUNT OF INFO SENT HERE</%text>
360
413
361 <%text>## enables 404 error logging (default False)</%text>
414 <%text>## enables 404 error logging (default False)</%text>
362 errormator.report_404 = false
415 errormator.report_404 = false
363
416
364 <%text>## time in seconds after request is considered being slow (default 1)</%text>
417 <%text>## time in seconds after request is considered being slow (default 1)</%text>
365 errormator.slow_request_time = 1
418 errormator.slow_request_time = 1
366
419
367 <%text>## record slow requests in application</%text>
420 <%text>## record slow requests in application</%text>
368 <%text>## (needs to be enabled for slow datastore recording and time tracking)</%text>
421 <%text>## (needs to be enabled for slow datastore recording and time tracking)</%text>
369 errormator.slow_requests = true
422 errormator.slow_requests = true
370
423
371 <%text>## enable hooking to application loggers</%text>
424 <%text>## enable hooking to application loggers</%text>
372 # errormator.logging = true
425 # errormator.logging = true
373
426
374 <%text>## minimum log level for log capture</%text>
427 <%text>## minimum log level for log capture</%text>
375 # errormator.logging.level = WARNING
428 # errormator.logging.level = WARNING
376
429
377 <%text>## send logs only from erroneous/slow requests</%text>
430 <%text>## send logs only from erroneous/slow requests</%text>
378 <%text>## (saves API quota for intensive logging)</%text>
431 <%text>## (saves API quota for intensive logging)</%text>
379 errormator.logging_on_error = false
432 errormator.logging_on_error = false
380
433
381 <%text>## list of additonal keywords that should be grabbed from environ object</%text>
434 <%text>## list of additonal keywords that should be grabbed from environ object</%text>
382 <%text>## can be string with comma separated list of words in lowercase</%text>
435 <%text>## can be string with comma separated list of words in lowercase</%text>
383 <%text>## (by default client will always send following info:</%text>
436 <%text>## (by default client will always send following info:</%text>
384 <%text>## 'REMOTE_USER', 'REMOTE_ADDR', 'SERVER_NAME', 'CONTENT_TYPE' + all keys that</%text>
437 <%text>## 'REMOTE_USER', 'REMOTE_ADDR', 'SERVER_NAME', 'CONTENT_TYPE' + all keys that</%text>
385 <%text>## start with HTTP* this list be extended with additional keywords here</%text>
438 <%text>## start with HTTP* this list be extended with additional keywords here</%text>
386 errormator.environ_keys_whitelist =
439 errormator.environ_keys_whitelist =
387
440
388
441
389 <%text>## list of keywords that should be blanked from request object</%text>
442 <%text>## list of keywords that should be blanked from request object</%text>
390 <%text>## can be string with comma separated list of words in lowercase</%text>
443 <%text>## can be string with comma separated list of words in lowercase</%text>
391 <%text>## (by default client will always blank keys that contain following words</%text>
444 <%text>## (by default client will always blank keys that contain following words</%text>
392 <%text>## 'password', 'passwd', 'pwd', 'auth_tkt', 'secret', 'csrf'</%text>
445 <%text>## 'password', 'passwd', 'pwd', 'auth_tkt', 'secret', 'csrf'</%text>
393 <%text>## this list be extended with additional keywords set here</%text>
446 <%text>## this list be extended with additional keywords set here</%text>
394 errormator.request_keys_blacklist =
447 errormator.request_keys_blacklist =
395
448
396
449
397 <%text>## list of namespaces that should be ignores when gathering log entries</%text>
450 <%text>## list of namespaces that should be ignores when gathering log entries</%text>
398 <%text>## can be string with comma separated list of namespaces</%text>
451 <%text>## can be string with comma separated list of namespaces</%text>
399 <%text>## (by default the client ignores own entries: errormator_client.client)</%text>
452 <%text>## (by default the client ignores own entries: errormator_client.client)</%text>
400 errormator.log_namespace_blacklist =
453 errormator.log_namespace_blacklist =
401 %elif error_aggregation_service == 'sentry':
454 %elif error_aggregation_service == 'sentry':
402 <%text>
455 <%text>
403 ################
456 ################
404 ### [sentry] ###
457 ### [sentry] ###
405 ################
458 ################
406
459
407 ## sentry is a alternative open source error aggregator
460 ## sentry is a alternative open source error aggregator
408 ## you must install python packages `sentry` and `raven` to enable
461 ## you must install python packages `sentry` and `raven` to enable
409 </%text>
462 </%text>
410 sentry.dsn = YOUR_DNS
463 sentry.dsn = YOUR_DNS
411 sentry.servers =
464 sentry.servers =
412 sentry.name =
465 sentry.name =
413 sentry.key =
466 sentry.key =
414 sentry.public_key =
467 sentry.public_key =
415 sentry.secret_key =
468 sentry.secret_key =
416 sentry.project =
469 sentry.project =
417 sentry.site =
470 sentry.site =
418 sentry.include_paths =
471 sentry.include_paths =
419 sentry.exclude_paths =
472 sentry.exclude_paths =
420 %endif
473 %endif
421 <%text>
474 <%text>
422 ################################################################################
475 ################################################################################
423 ## WARNING: *THE LINE BELOW MUST BE UNCOMMENTED ON A PRODUCTION ENVIRONMENT* ##
476 ## WARNING: *THE LINE BELOW MUST BE UNCOMMENTED ON A PRODUCTION ENVIRONMENT* ##
424 ## Debug mode will enable the interactive debugging tool, allowing ANYONE to ##
477 ## Debug mode will enable the interactive debugging tool, allowing ANYONE to ##
425 ## execute malicious code after an exception is raised. ##
478 ## execute malicious code after an exception is raised. ##
426 ################################################################################
479 ################################################################################
427 </%text>
480 </%text>
428 set debug = false
481 set debug = false
429 <%text>
482 <%text>
430 ##################################
483 ##################################
431 ### LOGVIEW CONFIG ###
484 ### LOGVIEW CONFIG ###
432 ##################################
485 ##################################
433 </%text>
486 </%text>
434 logview.sqlalchemy = #faa
487 logview.sqlalchemy = #faa
435 logview.pylons.templating = #bfb
488 logview.pylons.templating = #bfb
436 logview.pylons.util = #eee
489 logview.pylons.util = #eee
437 <%text>
490 <%text>
438 #########################################################
491 #########################################################
439 ### DB CONFIGS - EACH DB WILL HAVE IT'S OWN CONFIG ###
492 ### DB CONFIGS - EACH DB WILL HAVE IT'S OWN CONFIG ###
440 #########################################################
493 #########################################################
441 </%text>
494 </%text>
442 %if database_engine == 'sqlite':
495 %if database_engine == 'sqlite':
443 # SQLITE [default]
496 # SQLITE [default]
444 sqlalchemy.db1.url = sqlite:///${here}/rhodecode.db?timeout=60
497 sqlalchemy.db1.url = sqlite:///${here}/rhodecode.db?timeout=60
445 %elif database_engine == 'postgres':
498 %elif database_engine == 'postgres':
446 # POSTGRESQL
499 # POSTGRESQL
447 sqlalchemy.db1.url = postgresql://user:pass@localhost/rhodecode
500 sqlalchemy.db1.url = postgresql://user:pass@localhost/rhodecode
448 %elif database_engine == 'mysql':
501 %elif database_engine == 'mysql':
449 # MySQL
502 # MySQL
450 sqlalchemy.db1.url = mysql://user:pass@localhost/rhodecode
503 sqlalchemy.db1.url = mysql://user:pass@localhost/rhodecode
451 %endif
504 %endif
452 # see sqlalchemy docs for others
505 # see sqlalchemy docs for others
453
506
454 sqlalchemy.db1.echo = false
507 sqlalchemy.db1.echo = false
455 sqlalchemy.db1.pool_recycle = 3600
508 sqlalchemy.db1.pool_recycle = 3600
456 sqlalchemy.db1.convert_unicode = true
509 sqlalchemy.db1.convert_unicode = true
457 <%text>
510 <%text>
458 ################################
511 ################################
459 ### LOGGING CONFIGURATION ####
512 ### LOGGING CONFIGURATION ####
460 ################################
513 ################################
461 </%text>
514 </%text>
462 [loggers]
515 [loggers]
463 keys = root, routes, rhodecode, sqlalchemy, beaker, templates, whoosh_indexer
516 keys = root, routes, rhodecode, sqlalchemy, beaker, templates, whoosh_indexer
464
517
465 [handlers]
518 [handlers]
466 keys = console, console_sql
519 keys = console, console_sql
467
520
468 [formatters]
521 [formatters]
469 keys = generic, color_formatter, color_formatter_sql
522 keys = generic, color_formatter, color_formatter_sql
470 <%text>
523 <%text>
471 #############
524 #############
472 ## LOGGERS ##
525 ## LOGGERS ##
473 #############
526 #############
474 </%text>
527 </%text>
475 [logger_root]
528 [logger_root]
476 level = NOTSET
529 level = NOTSET
477 handlers = console
530 handlers = console
478
531
479 [logger_routes]
532 [logger_routes]
480 level = DEBUG
533 level = DEBUG
481 handlers =
534 handlers =
482 qualname = routes.middleware
535 qualname = routes.middleware
483 <%text>## "level = DEBUG" logs the route matched and routing variables.</%text>
536 <%text>## "level = DEBUG" logs the route matched and routing variables.</%text>
484 propagate = 1
537 propagate = 1
485
538
486 [logger_beaker]
539 [logger_beaker]
487 level = DEBUG
540 level = DEBUG
488 handlers =
541 handlers =
489 qualname = beaker.container
542 qualname = beaker.container
490 propagate = 1
543 propagate = 1
491
544
492 [logger_templates]
545 [logger_templates]
493 level = INFO
546 level = INFO
494 handlers =
547 handlers =
495 qualname = pylons.templating
548 qualname = pylons.templating
496 propagate = 1
549 propagate = 1
497
550
498 [logger_rhodecode]
551 [logger_rhodecode]
499 level = DEBUG
552 level = DEBUG
500 handlers =
553 handlers =
501 qualname = rhodecode
554 qualname = rhodecode
502 propagate = 1
555 propagate = 1
503
556
504 [logger_sqlalchemy]
557 [logger_sqlalchemy]
505 level = INFO
558 level = INFO
506 handlers = console_sql
559 handlers = console_sql
507 qualname = sqlalchemy.engine
560 qualname = sqlalchemy.engine
508 propagate = 0
561 propagate = 0
509
562
510 [logger_whoosh_indexer]
563 [logger_whoosh_indexer]
511 level = DEBUG
564 level = DEBUG
512 handlers =
565 handlers =
513 qualname = whoosh_indexer
566 qualname = whoosh_indexer
514 propagate = 1
567 propagate = 1
515 <%text>
568 <%text>
516 ##############
569 ##############
517 ## HANDLERS ##
570 ## HANDLERS ##
518 ##############
571 ##############
519 </%text>
572 </%text>
520 [handler_console]
573 [handler_console]
521 class = StreamHandler
574 class = StreamHandler
522 args = (sys.stderr,)
575 args = (sys.stderr,)
523 level = INFO
576 level = INFO
524 formatter = generic
577 formatter = generic
525
578
526 [handler_console_sql]
579 [handler_console_sql]
527 class = StreamHandler
580 class = StreamHandler
528 args = (sys.stderr,)
581 args = (sys.stderr,)
529 level = WARN
582 level = WARN
530 formatter = generic
583 formatter = generic
531 <%text>
584 <%text>
532 ################
585 ################
533 ## FORMATTERS ##
586 ## FORMATTERS ##
534 ################
587 ################
535 </%text>
588 </%text>
536 [formatter_generic]
589 [formatter_generic]
537 format = %(asctime)s.%(msecs)03d %(levelname)-5.5s [%(name)s] %(message)s
590 format = %(asctime)s.%(msecs)03d %(levelname)-5.5s [%(name)s] %(message)s
538 datefmt = %Y-%m-%d %H:%M:%S
591 datefmt = %Y-%m-%d %H:%M:%S
539
592
540 [formatter_color_formatter]
593 [formatter_color_formatter]
541 class=rhodecode.lib.colored_formatter.ColorFormatter
594 class=rhodecode.lib.colored_formatter.ColorFormatter
542 format= %(asctime)s.%(msecs)03d %(levelname)-5.5s [%(name)s] %(message)s
595 format= %(asctime)s.%(msecs)03d %(levelname)-5.5s [%(name)s] %(message)s
543 datefmt = %Y-%m-%d %H:%M:%S
596 datefmt = %Y-%m-%d %H:%M:%S
544
597
545 [formatter_color_formatter_sql]
598 [formatter_color_formatter_sql]
546 class=rhodecode.lib.colored_formatter.ColorFormatterSql
599 class=rhodecode.lib.colored_formatter.ColorFormatterSql
547 format= %(asctime)s.%(msecs)03d %(levelname)-5.5s [%(name)s] %(message)s
600 format= %(asctime)s.%(msecs)03d %(levelname)-5.5s [%(name)s] %(message)s
548 datefmt = %Y-%m-%d %H:%M:%S
601 datefmt = %Y-%m-%d %H:%M:%S
General Comments 0
You need to be logged in to leave comments. Login now