##// END OF EJS Templates
ssh: allow customizing the base_url for running application....
marcink -
r2188:397144e9 default
parent child Browse files
Show More
@@ -0,0 +1,43 b''
1 # -*- coding: utf-8 -*-
2
3 # Copyright (C) 2016-2017 RhodeCode GmbH
4 #
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
7 # (only), as published by the Free Software Foundation.
8 #
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 # GNU General Public License for more details.
13 #
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/>.
16 #
17 # This program is dual-licensed. If you wish to learn more about the
18 # RhodeCode Enterprise Edition, including its added features, Support services,
19 # and proprietary license terms, please see https://rhodecode.com/licenses/
20
21 import ConfigParser
22 from pyramid.paster import bootstrap as pyramid_bootstrap
23 from pyramid.request import Request
24
25
26 def get_config(ini_path):
27 parser = ConfigParser.ConfigParser()
28 parser.read(ini_path)
29 return parser
30
31
32 def bootstrap(config_uri, request=None, options=None):
33
34 config = get_config(config_uri)
35 base_url = 'http://rhodecode.local'
36 try:
37 base_url = config.get('app:main', 'app.base_url')
38 except (ConfigParser.NoSectionError, ConfigParser.NoOptionError):
39 pass
40
41 request = request or Request.blank('/', base_url=base_url)
42
43 return pyramid_bootstrap(config_uri, request=request, options=options)
@@ -1,720 +1,725 b''
1 1
2 2
3 3 ################################################################################
4 4 ## RHODECODE COMMUNITY EDITION CONFIGURATION ##
5 5 # The %(here)s variable will be replaced with the parent directory of this file#
6 6 ################################################################################
7 7
8 8 [DEFAULT]
9 9 debug = true
10 10
11 11 ################################################################################
12 12 ## EMAIL CONFIGURATION ##
13 13 ## Uncomment and replace with the email address which should receive ##
14 14 ## any error reports after an application crash ##
15 15 ## Additionally these settings will be used by the RhodeCode mailing system ##
16 16 ################################################################################
17 17
18 18 ## prefix all emails subjects with given prefix, helps filtering out emails
19 19 #email_prefix = [RhodeCode]
20 20
21 21 ## email FROM address all mails will be sent
22 22 #app_email_from = rhodecode-noreply@localhost
23 23
24 24 ## Uncomment and replace with the address which should receive any error report
25 25 ## note: using appenlight for error handling doesn't need this to be uncommented
26 26 #email_to = admin@localhost
27 27
28 28 ## in case of Application errors, sent an error email form
29 29 #error_email_from = rhodecode_error@localhost
30 30
31 31 ## additional error message to be send in case of server crash
32 32 #error_message =
33 33
34 34
35 35 #smtp_server = mail.server.com
36 36 #smtp_username =
37 37 #smtp_password =
38 38 #smtp_port =
39 39 #smtp_use_tls = false
40 40 #smtp_use_ssl = true
41 41 ## Specify available auth parameters here (e.g. LOGIN PLAIN CRAM-MD5, etc.)
42 42 #smtp_auth =
43 43
44 44 [server:main]
45 45 ## COMMON ##
46 46 host = 127.0.0.1
47 47 port = 5000
48 48
49 49 ##################################
50 50 ## WAITRESS WSGI SERVER ##
51 51 ## Recommended for Development ##
52 52 ##################################
53 53
54 54 use = egg:waitress#main
55 55 ## number of worker threads
56 56 threads = 5
57 57 ## MAX BODY SIZE 100GB
58 58 max_request_body_size = 107374182400
59 59 ## Use poll instead of select, fixes file descriptors limits problems.
60 60 ## May not work on old windows systems.
61 61 asyncore_use_poll = true
62 62
63 63
64 64 ##########################
65 65 ## GUNICORN WSGI SERVER ##
66 66 ##########################
67 67 ## run with gunicorn --log-config rhodecode.ini --paste rhodecode.ini
68 68
69 69 #use = egg:gunicorn#main
70 70 ## Sets the number of process workers. You must set `instance_id = *`
71 71 ## when this option is set to more than one worker, recommended
72 72 ## value is (2 * NUMBER_OF_CPUS + 1), eg 2CPU = 5 workers
73 73 ## The `instance_id = *` must be set in the [app:main] section below
74 74 #workers = 2
75 75 ## number of threads for each of the worker, must be set to 1 for gevent
76 76 ## generally recommended to be at 1
77 77 #threads = 1
78 78 ## process name
79 79 #proc_name = rhodecode
80 80 ## type of worker class, one of sync, gevent
81 81 ## recommended for bigger setup is using of of other than sync one
82 82 #worker_class = sync
83 83 ## The maximum number of simultaneous clients. Valid only for Gevent
84 84 #worker_connections = 10
85 85 ## max number of requests that worker will handle before being gracefully
86 86 ## restarted, could prevent memory leaks
87 87 #max_requests = 1000
88 88 #max_requests_jitter = 30
89 89 ## amount of time a worker can spend with handling a request before it
90 90 ## gets killed and restarted. Set to 6hrs
91 91 #timeout = 21600
92 92
93 93
94 94 ## prefix middleware for RhodeCode.
95 95 ## recommended when using proxy setup.
96 96 ## allows to set RhodeCode under a prefix in server.
97 97 ## eg https://server.com/custom_prefix. Enable `filter-with =` option below as well.
98 98 ## And set your prefix like: `prefix = /custom_prefix`
99 99 ## be sure to also set beaker.session.cookie_path = /custom_prefix if you need
100 100 ## to make your cookies only work on prefix url
101 101 [filter:proxy-prefix]
102 102 use = egg:PasteDeploy#prefix
103 103 prefix = /
104 104
105 105 [app:main]
106 106 use = egg:rhodecode-enterprise-ce
107 107
108 108 ## enable proxy prefix middleware, defined above
109 109 #filter-with = proxy-prefix
110 110
111 111 # During development the we want to have the debug toolbar enabled
112 112 pyramid.includes =
113 113 pyramid_debugtoolbar
114 114 rhodecode.lib.middleware.request_wrapper
115 115
116 116 pyramid.reload_templates = true
117 117
118 118 debugtoolbar.hosts = 0.0.0.0/0
119 119 debugtoolbar.exclude_prefixes =
120 120 /css
121 121 /fonts
122 122 /images
123 123 /js
124 124
125 125 ## RHODECODE PLUGINS ##
126 126 rhodecode.includes =
127 127 rhodecode.api
128 128
129 129
130 130 # api prefix url
131 131 rhodecode.api.url = /_admin/api
132 132
133 133
134 134 ## END RHODECODE PLUGINS ##
135 135
136 136 ## encryption key used to encrypt social plugin tokens,
137 137 ## remote_urls with credentials etc, if not set it defaults to
138 138 ## `beaker.session.secret`
139 139 #rhodecode.encrypted_values.secret =
140 140
141 141 ## decryption strict mode (enabled by default). It controls if decryption raises
142 142 ## `SignatureVerificationError` in case of wrong key, or damaged encryption data.
143 143 #rhodecode.encrypted_values.strict = false
144 144
145 145 ## return gzipped responses from Rhodecode (static files/application)
146 146 gzip_responses = false
147 147
148 148 ## autogenerate javascript routes file on startup
149 149 generate_js_files = false
150 150
151 151 ## Optional Languages
152 152 ## en(default), be, de, es, fr, it, ja, pl, pt, ru, zh
153 153 lang = en
154 154
155 155 ## perform a full repository scan on each server start, this should be
156 156 ## set to false after first startup, to allow faster server restarts.
157 157 startup.import_repos = false
158 158
159 159 ## Uncomment and set this path to use archive download cache.
160 160 ## Once enabled, generated archives will be cached at this location
161 161 ## and served from the cache during subsequent requests for the same archive of
162 162 ## the repository.
163 163 #archive_cache_dir = /tmp/tarballcache
164 164
165 ## URL at which the application is running. This is used for bootstraping
166 ## requests in context when no web request is available. Used in ishell, or
167 ## SSH calls. Set this for events to receive proper url for SSH calls.
168 app.base_url = http://rhodecode.local
169
165 170 ## change this to unique ID for security
166 171 app_instance_uuid = rc-production
167 172
168 173 ## cut off limit for large diffs (size in bytes). If overall diff size on
169 174 ## commit, or pull request exceeds this limit this diff will be displayed
170 175 ## partially. E.g 512000 == 512Kb
171 176 cut_off_limit_diff = 512000
172 177
173 178 ## cut off limit for large files inside diffs (size in bytes). Each individual
174 179 ## file inside diff which exceeds this limit will be displayed partially.
175 180 ## E.g 128000 == 128Kb
176 181 cut_off_limit_file = 128000
177 182
178 183 ## use cache version of scm repo everywhere
179 184 vcs_full_cache = true
180 185
181 186 ## force https in RhodeCode, fixes https redirects, assumes it's always https
182 187 ## Normally this is controlled by proper http flags sent from http server
183 188 force_https = false
184 189
185 190 ## use Strict-Transport-Security headers
186 191 use_htsts = false
187 192
188 193 ## number of commits stats will parse on each iteration
189 194 commit_parse_limit = 25
190 195
191 196 ## git rev filter option, --all is the default filter, if you need to
192 197 ## hide all refs in changelog switch this to --branches --tags
193 198 git_rev_filter = --branches --tags
194 199
195 200 # Set to true if your repos are exposed using the dumb protocol
196 201 git_update_server_info = false
197 202
198 203 ## RSS/ATOM feed options
199 204 rss_cut_off_limit = 256000
200 205 rss_items_per_page = 10
201 206 rss_include_diff = false
202 207
203 208 ## gist URL alias, used to create nicer urls for gist. This should be an
204 209 ## url that does rewrites to _admin/gists/{gistid}.
205 210 ## example: http://gist.rhodecode.org/{gistid}. Empty means use the internal
206 211 ## RhodeCode url, ie. http[s]://rhodecode.server/_admin/gists/{gistid}
207 212 gist_alias_url =
208 213
209 214 ## List of views (using glob pattern syntax) that AUTH TOKENS could be
210 215 ## used for access.
211 216 ## Adding ?auth_token=TOKEN_HASH to the url authenticates this request as if it
212 217 ## came from the the logged in user who own this authentication token.
213 218 ## Additionally @TOKEN syntaxt can be used to bound the view to specific
214 219 ## authentication token. Such view would be only accessible when used together
215 220 ## with this authentication token
216 221 ##
217 222 ## list of all views can be found under `/_admin/permissions/auth_token_access`
218 223 ## The list should be "," separated and on a single line.
219 224 ##
220 225 ## Most common views to enable:
221 226 # RepoCommitsView:repo_commit_download
222 227 # RepoCommitsView:repo_commit_patch
223 228 # RepoCommitsView:repo_commit_raw
224 229 # RepoCommitsView:repo_commit_raw@TOKEN
225 230 # RepoFilesView:repo_files_diff
226 231 # RepoFilesView:repo_archivefile
227 232 # RepoFilesView:repo_file_raw
228 233 # GistView:*
229 234 api_access_controllers_whitelist =
230 235
231 236 ## default encoding used to convert from and to unicode
232 237 ## can be also a comma separated list of encoding in case of mixed encodings
233 238 default_encoding = UTF-8
234 239
235 240 ## instance-id prefix
236 241 ## a prefix key for this instance used for cache invalidation when running
237 242 ## multiple instances of rhodecode, make sure it's globally unique for
238 243 ## all running rhodecode instances. Leave empty if you don't use it
239 244 instance_id =
240 245
241 246 ## Fallback authentication plugin. Set this to a plugin ID to force the usage
242 247 ## of an authentication plugin also if it is disabled by it's settings.
243 248 ## This could be useful if you are unable to log in to the system due to broken
244 249 ## authentication settings. Then you can enable e.g. the internal rhodecode auth
245 250 ## module to log in again and fix the settings.
246 251 ##
247 252 ## Available builtin plugin IDs (hash is part of the ID):
248 253 ## egg:rhodecode-enterprise-ce#rhodecode
249 254 ## egg:rhodecode-enterprise-ce#pam
250 255 ## egg:rhodecode-enterprise-ce#ldap
251 256 ## egg:rhodecode-enterprise-ce#jasig_cas
252 257 ## egg:rhodecode-enterprise-ce#headers
253 258 ## egg:rhodecode-enterprise-ce#crowd
254 259 #rhodecode.auth_plugin_fallback = egg:rhodecode-enterprise-ce#rhodecode
255 260
256 261 ## alternative return HTTP header for failed authentication. Default HTTP
257 262 ## response is 401 HTTPUnauthorized. Currently HG clients have troubles with
258 263 ## handling that causing a series of failed authentication calls.
259 264 ## Set this variable to 403 to return HTTPForbidden, or any other HTTP code
260 265 ## This will be served instead of default 401 on bad authnetication
261 266 auth_ret_code =
262 267
263 268 ## use special detection method when serving auth_ret_code, instead of serving
264 269 ## ret_code directly, use 401 initially (Which triggers credentials prompt)
265 270 ## and then serve auth_ret_code to clients
266 271 auth_ret_code_detection = false
267 272
268 273 ## locking return code. When repository is locked return this HTTP code. 2XX
269 274 ## codes don't break the transactions while 4XX codes do
270 275 lock_ret_code = 423
271 276
272 277 ## allows to change the repository location in settings page
273 278 allow_repo_location_change = true
274 279
275 280 ## allows to setup custom hooks in settings page
276 281 allow_custom_hooks_settings = true
277 282
278 283 ## generated license token, goto license page in RhodeCode settings to obtain
279 284 ## new token
280 285 license_token =
281 286
282 287 ## supervisor connection uri, for managing supervisor and logs.
283 288 supervisor.uri =
284 289 ## supervisord group name/id we only want this RC instance to handle
285 290 supervisor.group_id = dev
286 291
287 292 ## Display extended labs settings
288 293 labs_settings_active = true
289 294
290 295 ####################################
291 296 ### CELERY CONFIG ####
292 297 ####################################
293 298 use_celery = false
294 299 broker.host = localhost
295 300 broker.vhost = rabbitmqhost
296 301 broker.port = 5672
297 302 broker.user = rabbitmq
298 303 broker.password = qweqwe
299 304
300 305 celery.imports = rhodecode.lib.celerylib.tasks
301 306
302 307 celery.result.backend = amqp
303 308 celery.result.dburi = amqp://
304 309 celery.result.serialier = json
305 310
306 311 #celery.send.task.error.emails = true
307 312 #celery.amqp.task.result.expires = 18000
308 313
309 314 celeryd.concurrency = 2
310 315 #celeryd.log.file = celeryd.log
311 316 celeryd.log.level = debug
312 317 celeryd.max.tasks.per.child = 1
313 318
314 319 ## tasks will never be sent to the queue, but executed locally instead.
315 320 celery.always.eager = false
316 321
317 322 ####################################
318 323 ### BEAKER CACHE ####
319 324 ####################################
320 325 # default cache dir for templates. Putting this into a ramdisk
321 326 ## can boost performance, eg. %(here)s/data_ramdisk
322 327 cache_dir = %(here)s/data
323 328
324 329 ## locking and default file storage for Beaker. Putting this into a ramdisk
325 330 ## can boost performance, eg. %(here)s/data_ramdisk/cache/beaker_data
326 331 beaker.cache.data_dir = %(here)s/data/cache/beaker_data
327 332 beaker.cache.lock_dir = %(here)s/data/cache/beaker_lock
328 333
329 334 beaker.cache.regions = super_short_term, short_term, long_term, sql_cache_short, auth_plugins, repo_cache_long
330 335
331 336 beaker.cache.super_short_term.type = memory
332 337 beaker.cache.super_short_term.expire = 10
333 338 beaker.cache.super_short_term.key_length = 256
334 339
335 340 beaker.cache.short_term.type = memory
336 341 beaker.cache.short_term.expire = 60
337 342 beaker.cache.short_term.key_length = 256
338 343
339 344 beaker.cache.long_term.type = memory
340 345 beaker.cache.long_term.expire = 36000
341 346 beaker.cache.long_term.key_length = 256
342 347
343 348 beaker.cache.sql_cache_short.type = memory
344 349 beaker.cache.sql_cache_short.expire = 10
345 350 beaker.cache.sql_cache_short.key_length = 256
346 351
347 352 ## default is memory cache, configure only if required
348 353 ## using multi-node or multi-worker setup
349 354 #beaker.cache.auth_plugins.type = ext:database
350 355 #beaker.cache.auth_plugins.lock_dir = %(here)s/data/cache/auth_plugin_lock
351 356 #beaker.cache.auth_plugins.url = postgresql://postgres:secret@localhost/rhodecode
352 357 #beaker.cache.auth_plugins.url = mysql://root:secret@127.0.0.1/rhodecode
353 358 #beaker.cache.auth_plugins.sa.pool_recycle = 3600
354 359 #beaker.cache.auth_plugins.sa.pool_size = 10
355 360 #beaker.cache.auth_plugins.sa.max_overflow = 0
356 361
357 362 beaker.cache.repo_cache_long.type = memorylru_base
358 363 beaker.cache.repo_cache_long.max_items = 4096
359 364 beaker.cache.repo_cache_long.expire = 2592000
360 365
361 366 ## default is memorylru_base cache, configure only if required
362 367 ## using multi-node or multi-worker setup
363 368 #beaker.cache.repo_cache_long.type = ext:memcached
364 369 #beaker.cache.repo_cache_long.url = localhost:11211
365 370 #beaker.cache.repo_cache_long.expire = 1209600
366 371 #beaker.cache.repo_cache_long.key_length = 256
367 372
368 373 ####################################
369 374 ### BEAKER SESSION ####
370 375 ####################################
371 376
372 377 ## .session.type is type of storage options for the session, current allowed
373 378 ## types are file, ext:memcached, ext:database, and memory (default).
374 379 beaker.session.type = file
375 380 beaker.session.data_dir = %(here)s/data/sessions/data
376 381
377 382 ## db based session, fast, and allows easy management over logged in users
378 383 #beaker.session.type = ext:database
379 384 #beaker.session.table_name = db_session
380 385 #beaker.session.sa.url = postgresql://postgres:secret@localhost/rhodecode
381 386 #beaker.session.sa.url = mysql://root:secret@127.0.0.1/rhodecode
382 387 #beaker.session.sa.pool_recycle = 3600
383 388 #beaker.session.sa.echo = false
384 389
385 390 beaker.session.key = rhodecode
386 391 beaker.session.secret = develop-rc-uytcxaz
387 392 beaker.session.lock_dir = %(here)s/data/sessions/lock
388 393
389 394 ## Secure encrypted cookie. Requires AES and AES python libraries
390 395 ## you must disable beaker.session.secret to use this
391 396 #beaker.session.encrypt_key = key_for_encryption
392 397 #beaker.session.validate_key = validation_key
393 398
394 399 ## sets session as invalid(also logging out user) if it haven not been
395 400 ## accessed for given amount of time in seconds
396 401 beaker.session.timeout = 2592000
397 402 beaker.session.httponly = true
398 403 ## Path to use for the cookie. Set to prefix if you use prefix middleware
399 404 #beaker.session.cookie_path = /custom_prefix
400 405
401 406 ## uncomment for https secure cookie
402 407 beaker.session.secure = false
403 408
404 409 ## auto save the session to not to use .save()
405 410 beaker.session.auto = false
406 411
407 412 ## default cookie expiration time in seconds, set to `true` to set expire
408 413 ## at browser close
409 414 #beaker.session.cookie_expires = 3600
410 415
411 416 ###################################
412 417 ## SEARCH INDEXING CONFIGURATION ##
413 418 ###################################
414 419 ## Full text search indexer is available in rhodecode-tools under
415 420 ## `rhodecode-tools index` command
416 421
417 422 ## WHOOSH Backend, doesn't require additional services to run
418 423 ## it works good with few dozen repos
419 424 search.module = rhodecode.lib.index.whoosh
420 425 search.location = %(here)s/data/index
421 426
422 427 ########################################
423 428 ### CHANNELSTREAM CONFIG ####
424 429 ########################################
425 430 ## channelstream enables persistent connections and live notification
426 431 ## in the system. It's also used by the chat system
427 432 channelstream.enabled = false
428 433
429 434 ## server address for channelstream server on the backend
430 435 channelstream.server = 127.0.0.1:9800
431 436
432 437 ## location of the channelstream server from outside world
433 438 ## use ws:// for http or wss:// for https. This address needs to be handled
434 439 ## by external HTTP server such as Nginx or Apache
435 440 ## see nginx/apache configuration examples in our docs
436 441 channelstream.ws_url = ws://rhodecode.yourserver.com/_channelstream
437 442 channelstream.secret = secret
438 443 channelstream.history.location = %(here)s/channelstream_history
439 444
440 445 ## Internal application path that Javascript uses to connect into.
441 446 ## If you use proxy-prefix the prefix should be added before /_channelstream
442 447 channelstream.proxy_path = /_channelstream
443 448
444 449
445 450 ###################################
446 451 ## APPENLIGHT CONFIG ##
447 452 ###################################
448 453
449 454 ## Appenlight is tailored to work with RhodeCode, see
450 455 ## http://appenlight.com for details how to obtain an account
451 456
452 457 ## appenlight integration enabled
453 458 appenlight = false
454 459
455 460 appenlight.server_url = https://api.appenlight.com
456 461 appenlight.api_key = YOUR_API_KEY
457 462 #appenlight.transport_config = https://api.appenlight.com?threaded=1&timeout=5
458 463
459 464 # used for JS client
460 465 appenlight.api_public_key = YOUR_API_PUBLIC_KEY
461 466
462 467 ## TWEAK AMOUNT OF INFO SENT HERE
463 468
464 469 ## enables 404 error logging (default False)
465 470 appenlight.report_404 = false
466 471
467 472 ## time in seconds after request is considered being slow (default 1)
468 473 appenlight.slow_request_time = 1
469 474
470 475 ## record slow requests in application
471 476 ## (needs to be enabled for slow datastore recording and time tracking)
472 477 appenlight.slow_requests = true
473 478
474 479 ## enable hooking to application loggers
475 480 appenlight.logging = true
476 481
477 482 ## minimum log level for log capture
478 483 appenlight.logging.level = WARNING
479 484
480 485 ## send logs only from erroneous/slow requests
481 486 ## (saves API quota for intensive logging)
482 487 appenlight.logging_on_error = false
483 488
484 489 ## list of additonal keywords that should be grabbed from environ object
485 490 ## can be string with comma separated list of words in lowercase
486 491 ## (by default client will always send following info:
487 492 ## 'REMOTE_USER', 'REMOTE_ADDR', 'SERVER_NAME', 'CONTENT_TYPE' + all keys that
488 493 ## start with HTTP* this list be extended with additional keywords here
489 494 appenlight.environ_keys_whitelist =
490 495
491 496 ## list of keywords that should be blanked from request object
492 497 ## can be string with comma separated list of words in lowercase
493 498 ## (by default client will always blank keys that contain following words
494 499 ## 'password', 'passwd', 'pwd', 'auth_tkt', 'secret', 'csrf'
495 500 ## this list be extended with additional keywords set here
496 501 appenlight.request_keys_blacklist =
497 502
498 503 ## list of namespaces that should be ignores when gathering log entries
499 504 ## can be string with comma separated list of namespaces
500 505 ## (by default the client ignores own entries: appenlight_client.client)
501 506 appenlight.log_namespace_blacklist =
502 507
503 508
504 509 ################################################################################
505 510 ## WARNING: *THE LINE BELOW MUST BE UNCOMMENTED ON A PRODUCTION ENVIRONMENT* ##
506 511 ## Debug mode will enable the interactive debugging tool, allowing ANYONE to ##
507 512 ## execute malicious code after an exception is raised. ##
508 513 ################################################################################
509 514 #set debug = false
510 515
511 516
512 517 ##############
513 518 ## STYLING ##
514 519 ##############
515 520 debug_style = true
516 521
517 522 ###########################################
518 523 ### MAIN RHODECODE DATABASE CONFIG ###
519 524 ###########################################
520 525 #sqlalchemy.db1.url = sqlite:///%(here)s/rhodecode.db?timeout=30
521 526 #sqlalchemy.db1.url = postgresql://postgres:qweqwe@localhost/rhodecode
522 527 #sqlalchemy.db1.url = mysql://root:qweqwe@localhost/rhodecode
523 528 sqlalchemy.db1.url = sqlite:///%(here)s/rhodecode.db?timeout=30
524 529
525 530 # see sqlalchemy docs for other advanced settings
526 531
527 532 ## print the sql statements to output
528 533 sqlalchemy.db1.echo = false
529 534 ## recycle the connections after this amount of seconds
530 535 sqlalchemy.db1.pool_recycle = 3600
531 536 sqlalchemy.db1.convert_unicode = true
532 537
533 538 ## the number of connections to keep open inside the connection pool.
534 539 ## 0 indicates no limit
535 540 #sqlalchemy.db1.pool_size = 5
536 541
537 542 ## the number of connections to allow in connection pool "overflow", that is
538 543 ## connections that can be opened above and beyond the pool_size setting,
539 544 ## which defaults to five.
540 545 #sqlalchemy.db1.max_overflow = 10
541 546
542 547
543 548 ##################
544 549 ### VCS CONFIG ###
545 550 ##################
546 551 vcs.server.enable = true
547 552 vcs.server = localhost:9900
548 553
549 554 ## Web server connectivity protocol, responsible for web based VCS operatations
550 555 ## Available protocols are:
551 556 ## `http` - use http-rpc backend (default)
552 557 vcs.server.protocol = http
553 558
554 559 ## Push/Pull operations protocol, available options are:
555 560 ## `http` - use http-rpc backend (default)
556 561 ##
557 562 vcs.scm_app_implementation = http
558 563
559 564 ## Push/Pull operations hooks protocol, available options are:
560 565 ## `http` - use http-rpc backend (default)
561 566 vcs.hooks.protocol = http
562 567
563 568 vcs.server.log_level = debug
564 569 ## Start VCSServer with this instance as a subprocess, usefull for development
565 570 vcs.start_server = true
566 571
567 572 ## List of enabled VCS backends, available options are:
568 573 ## `hg` - mercurial
569 574 ## `git` - git
570 575 ## `svn` - subversion
571 576 vcs.backends = hg, git, svn
572 577
573 578 vcs.connection_timeout = 3600
574 579 ## Compatibility version when creating SVN repositories. Defaults to newest version when commented out.
575 580 ## Available options are: pre-1.4-compatible, pre-1.5-compatible, pre-1.6-compatible, pre-1.8-compatible, pre-1.9-compatible
576 581 #vcs.svn.compatible_version = pre-1.8-compatible
577 582
578 583
579 584 ############################################################
580 585 ### Subversion proxy support (mod_dav_svn) ###
581 586 ### Maps RhodeCode repo groups into SVN paths for Apache ###
582 587 ############################################################
583 588 ## Enable or disable the config file generation.
584 589 svn.proxy.generate_config = false
585 590 ## Generate config file with `SVNListParentPath` set to `On`.
586 591 svn.proxy.list_parent_path = true
587 592 ## Set location and file name of generated config file.
588 593 svn.proxy.config_file_path = %(here)s/mod_dav_svn.conf
589 594 ## alternative mod_dav config template. This needs to be a mako template
590 595 #svn.proxy.config_template = ~/.rccontrol/enterprise-1/custom_svn_conf.mako
591 596 ## Used as a prefix to the `Location` block in the generated config file.
592 597 ## In most cases it should be set to `/`.
593 598 svn.proxy.location_root = /
594 599 ## Command to reload the mod dav svn configuration on change.
595 600 ## Example: `/etc/init.d/apache2 reload`
596 601 #svn.proxy.reload_cmd = /etc/init.d/apache2 reload
597 602 ## If the timeout expires before the reload command finishes, the command will
598 603 ## be killed. Setting it to zero means no timeout. Defaults to 10 seconds.
599 604 #svn.proxy.reload_timeout = 10
600 605
601 606 ############################################################
602 607 ### SSH Support Settings ###
603 608 ############################################################
604 609
605 610 ## Defines if a custom authorized_keys file should be created and written on
606 611 ## any change user ssh keys. Setting this to false also disables posibility
607 612 ## of adding SSH keys by users from web interface. Super admins can still
608 613 ## manage SSH Keys.
609 614 ssh.generate_authorized_keyfile = false
610 615
611 616 ## Options for ssh, default is `no-pty,no-port-forwarding,no-X11-forwarding,no-agent-forwarding`
612 617 # ssh.authorized_keys_ssh_opts =
613 618
614 619 ## Path to the authrozied_keys file where the generate entries are placed.
615 620 ## It is possible to have multiple key files specified in `sshd_config` e.g.
616 621 ## AuthorizedKeysFile %h/.ssh/authorized_keys %h/.ssh/authorized_keys_rhodecode
617 622 ssh.authorized_keys_file_path = ~/.ssh/authorized_keys_rhodecode
618 623
619 624 ## Command to execute the SSH wrapper. The binary is available in the
620 625 ## rhodecode installation directory.
621 626 ## e.g ~/.rccontrol/community-1/profile/bin/rc-ssh-wrapper
622 627 ssh.wrapper_cmd = ~/.rccontrol/community-1/rc-ssh-wrapper
623 628
624 629 ## Allow shell when executing the ssh-wrapper command
625 630 ssh.wrapper_cmd_allow_shell = false
626 631
627 632 ## Enables logging, and detailed output send back to the client during SSH
628 633 ## operations. Usefull for debugging, shouldn't be used in production.
629 634 ssh.enable_debug_logging = true
630 635
631 636 ## Paths to binary executable, by default they are the names, but we can
632 637 ## override them if we want to use a custom one
633 638 ssh.executable.hg = ~/.rccontrol/vcsserver-1/profile/bin/hg
634 639 ssh.executable.git = ~/.rccontrol/vcsserver-1/profile/bin/git
635 640 ssh.executable.svn = ~/.rccontrol/vcsserver-1/profile/bin/svnserve
636 641
637 642
638 643 ## Dummy marker to add new entries after.
639 644 ## Add any custom entries below. Please don't remove.
640 645 custom.conf = 1
641 646
642 647
643 648 ################################
644 649 ### LOGGING CONFIGURATION ####
645 650 ################################
646 651 [loggers]
647 652 keys = root, sqlalchemy, beaker, rhodecode, ssh_wrapper
648 653
649 654 [handlers]
650 655 keys = console, console_sql
651 656
652 657 [formatters]
653 658 keys = generic, color_formatter, color_formatter_sql
654 659
655 660 #############
656 661 ## LOGGERS ##
657 662 #############
658 663 [logger_root]
659 664 level = NOTSET
660 665 handlers = console
661 666
662 667 [logger_sqlalchemy]
663 668 level = INFO
664 669 handlers = console_sql
665 670 qualname = sqlalchemy.engine
666 671 propagate = 0
667 672
668 673 [logger_beaker]
669 674 level = DEBUG
670 675 handlers =
671 676 qualname = beaker.container
672 677 propagate = 1
673 678
674 679 [logger_rhodecode]
675 680 level = DEBUG
676 681 handlers =
677 682 qualname = rhodecode
678 683 propagate = 1
679 684
680 685 [logger_ssh_wrapper]
681 686 level = DEBUG
682 687 handlers =
683 688 qualname = ssh_wrapper
684 689 propagate = 1
685 690
686 691
687 692 ##############
688 693 ## HANDLERS ##
689 694 ##############
690 695
691 696 [handler_console]
692 697 class = StreamHandler
693 698 args = (sys.stderr, )
694 699 level = DEBUG
695 700 formatter = color_formatter
696 701
697 702 [handler_console_sql]
698 703 class = StreamHandler
699 704 args = (sys.stderr, )
700 705 level = DEBUG
701 706 formatter = color_formatter_sql
702 707
703 708 ################
704 709 ## FORMATTERS ##
705 710 ################
706 711
707 712 [formatter_generic]
708 713 class = rhodecode.lib.logging_formatter.ExceptionAwareFormatter
709 714 format = %(asctime)s.%(msecs)03d %(levelname)-5.5s [%(name)s] %(message)s
710 715 datefmt = %Y-%m-%d %H:%M:%S
711 716
712 717 [formatter_color_formatter]
713 718 class = rhodecode.lib.logging_formatter.ColorFormatter
714 719 format = %(asctime)s.%(msecs)03d %(levelname)-5.5s [%(name)s] %(message)s
715 720 datefmt = %Y-%m-%d %H:%M:%S
716 721
717 722 [formatter_color_formatter_sql]
718 723 class = rhodecode.lib.logging_formatter.ColorFormatterSql
719 724 format = %(asctime)s.%(msecs)03d %(levelname)-5.5s [%(name)s] %(message)s
720 725 datefmt = %Y-%m-%d %H:%M:%S
@@ -1,690 +1,695 b''
1 1
2 2
3 3 ################################################################################
4 4 ## RHODECODE COMMUNITY EDITION CONFIGURATION ##
5 5 # The %(here)s variable will be replaced with the parent directory of this file#
6 6 ################################################################################
7 7
8 8 [DEFAULT]
9 9 debug = true
10 10
11 11 ################################################################################
12 12 ## EMAIL CONFIGURATION ##
13 13 ## Uncomment and replace with the email address which should receive ##
14 14 ## any error reports after an application crash ##
15 15 ## Additionally these settings will be used by the RhodeCode mailing system ##
16 16 ################################################################################
17 17
18 18 ## prefix all emails subjects with given prefix, helps filtering out emails
19 19 #email_prefix = [RhodeCode]
20 20
21 21 ## email FROM address all mails will be sent
22 22 #app_email_from = rhodecode-noreply@localhost
23 23
24 24 ## Uncomment and replace with the address which should receive any error report
25 25 ## note: using appenlight for error handling doesn't need this to be uncommented
26 26 #email_to = admin@localhost
27 27
28 28 ## in case of Application errors, sent an error email form
29 29 #error_email_from = rhodecode_error@localhost
30 30
31 31 ## additional error message to be send in case of server crash
32 32 #error_message =
33 33
34 34
35 35 #smtp_server = mail.server.com
36 36 #smtp_username =
37 37 #smtp_password =
38 38 #smtp_port =
39 39 #smtp_use_tls = false
40 40 #smtp_use_ssl = true
41 41 ## Specify available auth parameters here (e.g. LOGIN PLAIN CRAM-MD5, etc.)
42 42 #smtp_auth =
43 43
44 44 [server:main]
45 45 ## COMMON ##
46 46 host = 127.0.0.1
47 47 port = 5000
48 48
49 49 ##################################
50 50 ## WAITRESS WSGI SERVER ##
51 51 ## Recommended for Development ##
52 52 ##################################
53 53
54 54 #use = egg:waitress#main
55 55 ## number of worker threads
56 56 #threads = 5
57 57 ## MAX BODY SIZE 100GB
58 58 #max_request_body_size = 107374182400
59 59 ## Use poll instead of select, fixes file descriptors limits problems.
60 60 ## May not work on old windows systems.
61 61 #asyncore_use_poll = true
62 62
63 63
64 64 ##########################
65 65 ## GUNICORN WSGI SERVER ##
66 66 ##########################
67 67 ## run with gunicorn --log-config rhodecode.ini --paste rhodecode.ini
68 68
69 69 use = egg:gunicorn#main
70 70 ## Sets the number of process workers. You must set `instance_id = *`
71 71 ## when this option is set to more than one worker, recommended
72 72 ## value is (2 * NUMBER_OF_CPUS + 1), eg 2CPU = 5 workers
73 73 ## The `instance_id = *` must be set in the [app:main] section below
74 74 workers = 2
75 75 ## number of threads for each of the worker, must be set to 1 for gevent
76 76 ## generally recommended to be at 1
77 77 #threads = 1
78 78 ## process name
79 79 proc_name = rhodecode
80 80 ## type of worker class, one of sync, gevent
81 81 ## recommended for bigger setup is using of of other than sync one
82 82 worker_class = sync
83 83 ## The maximum number of simultaneous clients. Valid only for Gevent
84 84 #worker_connections = 10
85 85 ## max number of requests that worker will handle before being gracefully
86 86 ## restarted, could prevent memory leaks
87 87 max_requests = 1000
88 88 max_requests_jitter = 30
89 89 ## amount of time a worker can spend with handling a request before it
90 90 ## gets killed and restarted. Set to 6hrs
91 91 timeout = 21600
92 92
93 93
94 94 ## prefix middleware for RhodeCode.
95 95 ## recommended when using proxy setup.
96 96 ## allows to set RhodeCode under a prefix in server.
97 97 ## eg https://server.com/custom_prefix. Enable `filter-with =` option below as well.
98 98 ## And set your prefix like: `prefix = /custom_prefix`
99 99 ## be sure to also set beaker.session.cookie_path = /custom_prefix if you need
100 100 ## to make your cookies only work on prefix url
101 101 [filter:proxy-prefix]
102 102 use = egg:PasteDeploy#prefix
103 103 prefix = /
104 104
105 105 [app:main]
106 106 use = egg:rhodecode-enterprise-ce
107 107
108 108 ## enable proxy prefix middleware, defined above
109 109 #filter-with = proxy-prefix
110 110
111 111 ## encryption key used to encrypt social plugin tokens,
112 112 ## remote_urls with credentials etc, if not set it defaults to
113 113 ## `beaker.session.secret`
114 114 #rhodecode.encrypted_values.secret =
115 115
116 116 ## decryption strict mode (enabled by default). It controls if decryption raises
117 117 ## `SignatureVerificationError` in case of wrong key, or damaged encryption data.
118 118 #rhodecode.encrypted_values.strict = false
119 119
120 120 ## return gzipped responses from Rhodecode (static files/application)
121 121 gzip_responses = false
122 122
123 123 ## autogenerate javascript routes file on startup
124 124 generate_js_files = false
125 125
126 126 ## Optional Languages
127 127 ## en(default), be, de, es, fr, it, ja, pl, pt, ru, zh
128 128 lang = en
129 129
130 130 ## perform a full repository scan on each server start, this should be
131 131 ## set to false after first startup, to allow faster server restarts.
132 132 startup.import_repos = false
133 133
134 134 ## Uncomment and set this path to use archive download cache.
135 135 ## Once enabled, generated archives will be cached at this location
136 136 ## and served from the cache during subsequent requests for the same archive of
137 137 ## the repository.
138 138 #archive_cache_dir = /tmp/tarballcache
139 139
140 ## URL at which the application is running. This is used for bootstraping
141 ## requests in context when no web request is available. Used in ishell, or
142 ## SSH calls. Set this for events to receive proper url for SSH calls.
143 app.base_url = http://rhodecode.local
144
140 145 ## change this to unique ID for security
141 146 app_instance_uuid = rc-production
142 147
143 148 ## cut off limit for large diffs (size in bytes). If overall diff size on
144 149 ## commit, or pull request exceeds this limit this diff will be displayed
145 150 ## partially. E.g 512000 == 512Kb
146 151 cut_off_limit_diff = 512000
147 152
148 153 ## cut off limit for large files inside diffs (size in bytes). Each individual
149 154 ## file inside diff which exceeds this limit will be displayed partially.
150 155 ## E.g 128000 == 128Kb
151 156 cut_off_limit_file = 128000
152 157
153 158 ## use cache version of scm repo everywhere
154 159 vcs_full_cache = true
155 160
156 161 ## force https in RhodeCode, fixes https redirects, assumes it's always https
157 162 ## Normally this is controlled by proper http flags sent from http server
158 163 force_https = false
159 164
160 165 ## use Strict-Transport-Security headers
161 166 use_htsts = false
162 167
163 168 ## number of commits stats will parse on each iteration
164 169 commit_parse_limit = 25
165 170
166 171 ## git rev filter option, --all is the default filter, if you need to
167 172 ## hide all refs in changelog switch this to --branches --tags
168 173 git_rev_filter = --branches --tags
169 174
170 175 # Set to true if your repos are exposed using the dumb protocol
171 176 git_update_server_info = false
172 177
173 178 ## RSS/ATOM feed options
174 179 rss_cut_off_limit = 256000
175 180 rss_items_per_page = 10
176 181 rss_include_diff = false
177 182
178 183 ## gist URL alias, used to create nicer urls for gist. This should be an
179 184 ## url that does rewrites to _admin/gists/{gistid}.
180 185 ## example: http://gist.rhodecode.org/{gistid}. Empty means use the internal
181 186 ## RhodeCode url, ie. http[s]://rhodecode.server/_admin/gists/{gistid}
182 187 gist_alias_url =
183 188
184 189 ## List of views (using glob pattern syntax) that AUTH TOKENS could be
185 190 ## used for access.
186 191 ## Adding ?auth_token=TOKEN_HASH to the url authenticates this request as if it
187 192 ## came from the the logged in user who own this authentication token.
188 193 ## Additionally @TOKEN syntaxt can be used to bound the view to specific
189 194 ## authentication token. Such view would be only accessible when used together
190 195 ## with this authentication token
191 196 ##
192 197 ## list of all views can be found under `/_admin/permissions/auth_token_access`
193 198 ## The list should be "," separated and on a single line.
194 199 ##
195 200 ## Most common views to enable:
196 201 # RepoCommitsView:repo_commit_download
197 202 # RepoCommitsView:repo_commit_patch
198 203 # RepoCommitsView:repo_commit_raw
199 204 # RepoCommitsView:repo_commit_raw@TOKEN
200 205 # RepoFilesView:repo_files_diff
201 206 # RepoFilesView:repo_archivefile
202 207 # RepoFilesView:repo_file_raw
203 208 # GistView:*
204 209 api_access_controllers_whitelist =
205 210
206 211 ## default encoding used to convert from and to unicode
207 212 ## can be also a comma separated list of encoding in case of mixed encodings
208 213 default_encoding = UTF-8
209 214
210 215 ## instance-id prefix
211 216 ## a prefix key for this instance used for cache invalidation when running
212 217 ## multiple instances of rhodecode, make sure it's globally unique for
213 218 ## all running rhodecode instances. Leave empty if you don't use it
214 219 instance_id =
215 220
216 221 ## Fallback authentication plugin. Set this to a plugin ID to force the usage
217 222 ## of an authentication plugin also if it is disabled by it's settings.
218 223 ## This could be useful if you are unable to log in to the system due to broken
219 224 ## authentication settings. Then you can enable e.g. the internal rhodecode auth
220 225 ## module to log in again and fix the settings.
221 226 ##
222 227 ## Available builtin plugin IDs (hash is part of the ID):
223 228 ## egg:rhodecode-enterprise-ce#rhodecode
224 229 ## egg:rhodecode-enterprise-ce#pam
225 230 ## egg:rhodecode-enterprise-ce#ldap
226 231 ## egg:rhodecode-enterprise-ce#jasig_cas
227 232 ## egg:rhodecode-enterprise-ce#headers
228 233 ## egg:rhodecode-enterprise-ce#crowd
229 234 #rhodecode.auth_plugin_fallback = egg:rhodecode-enterprise-ce#rhodecode
230 235
231 236 ## alternative return HTTP header for failed authentication. Default HTTP
232 237 ## response is 401 HTTPUnauthorized. Currently HG clients have troubles with
233 238 ## handling that causing a series of failed authentication calls.
234 239 ## Set this variable to 403 to return HTTPForbidden, or any other HTTP code
235 240 ## This will be served instead of default 401 on bad authnetication
236 241 auth_ret_code =
237 242
238 243 ## use special detection method when serving auth_ret_code, instead of serving
239 244 ## ret_code directly, use 401 initially (Which triggers credentials prompt)
240 245 ## and then serve auth_ret_code to clients
241 246 auth_ret_code_detection = false
242 247
243 248 ## locking return code. When repository is locked return this HTTP code. 2XX
244 249 ## codes don't break the transactions while 4XX codes do
245 250 lock_ret_code = 423
246 251
247 252 ## allows to change the repository location in settings page
248 253 allow_repo_location_change = true
249 254
250 255 ## allows to setup custom hooks in settings page
251 256 allow_custom_hooks_settings = true
252 257
253 258 ## generated license token, goto license page in RhodeCode settings to obtain
254 259 ## new token
255 260 license_token =
256 261
257 262 ## supervisor connection uri, for managing supervisor and logs.
258 263 supervisor.uri =
259 264 ## supervisord group name/id we only want this RC instance to handle
260 265 supervisor.group_id = prod
261 266
262 267 ## Display extended labs settings
263 268 labs_settings_active = true
264 269
265 270 ####################################
266 271 ### CELERY CONFIG ####
267 272 ####################################
268 273 use_celery = false
269 274 broker.host = localhost
270 275 broker.vhost = rabbitmqhost
271 276 broker.port = 5672
272 277 broker.user = rabbitmq
273 278 broker.password = qweqwe
274 279
275 280 celery.imports = rhodecode.lib.celerylib.tasks
276 281
277 282 celery.result.backend = amqp
278 283 celery.result.dburi = amqp://
279 284 celery.result.serialier = json
280 285
281 286 #celery.send.task.error.emails = true
282 287 #celery.amqp.task.result.expires = 18000
283 288
284 289 celeryd.concurrency = 2
285 290 #celeryd.log.file = celeryd.log
286 291 celeryd.log.level = debug
287 292 celeryd.max.tasks.per.child = 1
288 293
289 294 ## tasks will never be sent to the queue, but executed locally instead.
290 295 celery.always.eager = false
291 296
292 297 ####################################
293 298 ### BEAKER CACHE ####
294 299 ####################################
295 300 # default cache dir for templates. Putting this into a ramdisk
296 301 ## can boost performance, eg. %(here)s/data_ramdisk
297 302 cache_dir = %(here)s/data
298 303
299 304 ## locking and default file storage for Beaker. Putting this into a ramdisk
300 305 ## can boost performance, eg. %(here)s/data_ramdisk/cache/beaker_data
301 306 beaker.cache.data_dir = %(here)s/data/cache/beaker_data
302 307 beaker.cache.lock_dir = %(here)s/data/cache/beaker_lock
303 308
304 309 beaker.cache.regions = super_short_term, short_term, long_term, sql_cache_short, auth_plugins, repo_cache_long
305 310
306 311 beaker.cache.super_short_term.type = memory
307 312 beaker.cache.super_short_term.expire = 10
308 313 beaker.cache.super_short_term.key_length = 256
309 314
310 315 beaker.cache.short_term.type = memory
311 316 beaker.cache.short_term.expire = 60
312 317 beaker.cache.short_term.key_length = 256
313 318
314 319 beaker.cache.long_term.type = memory
315 320 beaker.cache.long_term.expire = 36000
316 321 beaker.cache.long_term.key_length = 256
317 322
318 323 beaker.cache.sql_cache_short.type = memory
319 324 beaker.cache.sql_cache_short.expire = 10
320 325 beaker.cache.sql_cache_short.key_length = 256
321 326
322 327 ## default is memory cache, configure only if required
323 328 ## using multi-node or multi-worker setup
324 329 #beaker.cache.auth_plugins.type = ext:database
325 330 #beaker.cache.auth_plugins.lock_dir = %(here)s/data/cache/auth_plugin_lock
326 331 #beaker.cache.auth_plugins.url = postgresql://postgres:secret@localhost/rhodecode
327 332 #beaker.cache.auth_plugins.url = mysql://root:secret@127.0.0.1/rhodecode
328 333 #beaker.cache.auth_plugins.sa.pool_recycle = 3600
329 334 #beaker.cache.auth_plugins.sa.pool_size = 10
330 335 #beaker.cache.auth_plugins.sa.max_overflow = 0
331 336
332 337 beaker.cache.repo_cache_long.type = memorylru_base
333 338 beaker.cache.repo_cache_long.max_items = 4096
334 339 beaker.cache.repo_cache_long.expire = 2592000
335 340
336 341 ## default is memorylru_base cache, configure only if required
337 342 ## using multi-node or multi-worker setup
338 343 #beaker.cache.repo_cache_long.type = ext:memcached
339 344 #beaker.cache.repo_cache_long.url = localhost:11211
340 345 #beaker.cache.repo_cache_long.expire = 1209600
341 346 #beaker.cache.repo_cache_long.key_length = 256
342 347
343 348 ####################################
344 349 ### BEAKER SESSION ####
345 350 ####################################
346 351
347 352 ## .session.type is type of storage options for the session, current allowed
348 353 ## types are file, ext:memcached, ext:database, and memory (default).
349 354 beaker.session.type = file
350 355 beaker.session.data_dir = %(here)s/data/sessions/data
351 356
352 357 ## db based session, fast, and allows easy management over logged in users
353 358 #beaker.session.type = ext:database
354 359 #beaker.session.table_name = db_session
355 360 #beaker.session.sa.url = postgresql://postgres:secret@localhost/rhodecode
356 361 #beaker.session.sa.url = mysql://root:secret@127.0.0.1/rhodecode
357 362 #beaker.session.sa.pool_recycle = 3600
358 363 #beaker.session.sa.echo = false
359 364
360 365 beaker.session.key = rhodecode
361 366 beaker.session.secret = production-rc-uytcxaz
362 367 beaker.session.lock_dir = %(here)s/data/sessions/lock
363 368
364 369 ## Secure encrypted cookie. Requires AES and AES python libraries
365 370 ## you must disable beaker.session.secret to use this
366 371 #beaker.session.encrypt_key = key_for_encryption
367 372 #beaker.session.validate_key = validation_key
368 373
369 374 ## sets session as invalid(also logging out user) if it haven not been
370 375 ## accessed for given amount of time in seconds
371 376 beaker.session.timeout = 2592000
372 377 beaker.session.httponly = true
373 378 ## Path to use for the cookie. Set to prefix if you use prefix middleware
374 379 #beaker.session.cookie_path = /custom_prefix
375 380
376 381 ## uncomment for https secure cookie
377 382 beaker.session.secure = false
378 383
379 384 ## auto save the session to not to use .save()
380 385 beaker.session.auto = false
381 386
382 387 ## default cookie expiration time in seconds, set to `true` to set expire
383 388 ## at browser close
384 389 #beaker.session.cookie_expires = 3600
385 390
386 391 ###################################
387 392 ## SEARCH INDEXING CONFIGURATION ##
388 393 ###################################
389 394 ## Full text search indexer is available in rhodecode-tools under
390 395 ## `rhodecode-tools index` command
391 396
392 397 ## WHOOSH Backend, doesn't require additional services to run
393 398 ## it works good with few dozen repos
394 399 search.module = rhodecode.lib.index.whoosh
395 400 search.location = %(here)s/data/index
396 401
397 402 ########################################
398 403 ### CHANNELSTREAM CONFIG ####
399 404 ########################################
400 405 ## channelstream enables persistent connections and live notification
401 406 ## in the system. It's also used by the chat system
402 407 channelstream.enabled = false
403 408
404 409 ## server address for channelstream server on the backend
405 410 channelstream.server = 127.0.0.1:9800
406 411
407 412 ## location of the channelstream server from outside world
408 413 ## use ws:// for http or wss:// for https. This address needs to be handled
409 414 ## by external HTTP server such as Nginx or Apache
410 415 ## see nginx/apache configuration examples in our docs
411 416 channelstream.ws_url = ws://rhodecode.yourserver.com/_channelstream
412 417 channelstream.secret = secret
413 418 channelstream.history.location = %(here)s/channelstream_history
414 419
415 420 ## Internal application path that Javascript uses to connect into.
416 421 ## If you use proxy-prefix the prefix should be added before /_channelstream
417 422 channelstream.proxy_path = /_channelstream
418 423
419 424
420 425 ###################################
421 426 ## APPENLIGHT CONFIG ##
422 427 ###################################
423 428
424 429 ## Appenlight is tailored to work with RhodeCode, see
425 430 ## http://appenlight.com for details how to obtain an account
426 431
427 432 ## appenlight integration enabled
428 433 appenlight = false
429 434
430 435 appenlight.server_url = https://api.appenlight.com
431 436 appenlight.api_key = YOUR_API_KEY
432 437 #appenlight.transport_config = https://api.appenlight.com?threaded=1&timeout=5
433 438
434 439 # used for JS client
435 440 appenlight.api_public_key = YOUR_API_PUBLIC_KEY
436 441
437 442 ## TWEAK AMOUNT OF INFO SENT HERE
438 443
439 444 ## enables 404 error logging (default False)
440 445 appenlight.report_404 = false
441 446
442 447 ## time in seconds after request is considered being slow (default 1)
443 448 appenlight.slow_request_time = 1
444 449
445 450 ## record slow requests in application
446 451 ## (needs to be enabled for slow datastore recording and time tracking)
447 452 appenlight.slow_requests = true
448 453
449 454 ## enable hooking to application loggers
450 455 appenlight.logging = true
451 456
452 457 ## minimum log level for log capture
453 458 appenlight.logging.level = WARNING
454 459
455 460 ## send logs only from erroneous/slow requests
456 461 ## (saves API quota for intensive logging)
457 462 appenlight.logging_on_error = false
458 463
459 464 ## list of additonal keywords that should be grabbed from environ object
460 465 ## can be string with comma separated list of words in lowercase
461 466 ## (by default client will always send following info:
462 467 ## 'REMOTE_USER', 'REMOTE_ADDR', 'SERVER_NAME', 'CONTENT_TYPE' + all keys that
463 468 ## start with HTTP* this list be extended with additional keywords here
464 469 appenlight.environ_keys_whitelist =
465 470
466 471 ## list of keywords that should be blanked from request object
467 472 ## can be string with comma separated list of words in lowercase
468 473 ## (by default client will always blank keys that contain following words
469 474 ## 'password', 'passwd', 'pwd', 'auth_tkt', 'secret', 'csrf'
470 475 ## this list be extended with additional keywords set here
471 476 appenlight.request_keys_blacklist =
472 477
473 478 ## list of namespaces that should be ignores when gathering log entries
474 479 ## can be string with comma separated list of namespaces
475 480 ## (by default the client ignores own entries: appenlight_client.client)
476 481 appenlight.log_namespace_blacklist =
477 482
478 483
479 484 ################################################################################
480 485 ## WARNING: *THE LINE BELOW MUST BE UNCOMMENTED ON A PRODUCTION ENVIRONMENT* ##
481 486 ## Debug mode will enable the interactive debugging tool, allowing ANYONE to ##
482 487 ## execute malicious code after an exception is raised. ##
483 488 ################################################################################
484 489 set debug = false
485 490
486 491
487 492 ###########################################
488 493 ### MAIN RHODECODE DATABASE CONFIG ###
489 494 ###########################################
490 495 #sqlalchemy.db1.url = sqlite:///%(here)s/rhodecode.db?timeout=30
491 496 #sqlalchemy.db1.url = postgresql://postgres:qweqwe@localhost/rhodecode
492 497 #sqlalchemy.db1.url = mysql://root:qweqwe@localhost/rhodecode
493 498 sqlalchemy.db1.url = postgresql://postgres:qweqwe@localhost/rhodecode
494 499
495 500 # see sqlalchemy docs for other advanced settings
496 501
497 502 ## print the sql statements to output
498 503 sqlalchemy.db1.echo = false
499 504 ## recycle the connections after this amount of seconds
500 505 sqlalchemy.db1.pool_recycle = 3600
501 506 sqlalchemy.db1.convert_unicode = true
502 507
503 508 ## the number of connections to keep open inside the connection pool.
504 509 ## 0 indicates no limit
505 510 #sqlalchemy.db1.pool_size = 5
506 511
507 512 ## the number of connections to allow in connection pool "overflow", that is
508 513 ## connections that can be opened above and beyond the pool_size setting,
509 514 ## which defaults to five.
510 515 #sqlalchemy.db1.max_overflow = 10
511 516
512 517
513 518 ##################
514 519 ### VCS CONFIG ###
515 520 ##################
516 521 vcs.server.enable = true
517 522 vcs.server = localhost:9900
518 523
519 524 ## Web server connectivity protocol, responsible for web based VCS operatations
520 525 ## Available protocols are:
521 526 ## `http` - use http-rpc backend (default)
522 527 vcs.server.protocol = http
523 528
524 529 ## Push/Pull operations protocol, available options are:
525 530 ## `http` - use http-rpc backend (default)
526 531 ##
527 532 vcs.scm_app_implementation = http
528 533
529 534 ## Push/Pull operations hooks protocol, available options are:
530 535 ## `http` - use http-rpc backend (default)
531 536 vcs.hooks.protocol = http
532 537
533 538 vcs.server.log_level = info
534 539 ## Start VCSServer with this instance as a subprocess, usefull for development
535 540 vcs.start_server = false
536 541
537 542 ## List of enabled VCS backends, available options are:
538 543 ## `hg` - mercurial
539 544 ## `git` - git
540 545 ## `svn` - subversion
541 546 vcs.backends = hg, git, svn
542 547
543 548 vcs.connection_timeout = 3600
544 549 ## Compatibility version when creating SVN repositories. Defaults to newest version when commented out.
545 550 ## Available options are: pre-1.4-compatible, pre-1.5-compatible, pre-1.6-compatible, pre-1.8-compatible, pre-1.9-compatible
546 551 #vcs.svn.compatible_version = pre-1.8-compatible
547 552
548 553
549 554 ############################################################
550 555 ### Subversion proxy support (mod_dav_svn) ###
551 556 ### Maps RhodeCode repo groups into SVN paths for Apache ###
552 557 ############################################################
553 558 ## Enable or disable the config file generation.
554 559 svn.proxy.generate_config = false
555 560 ## Generate config file with `SVNListParentPath` set to `On`.
556 561 svn.proxy.list_parent_path = true
557 562 ## Set location and file name of generated config file.
558 563 svn.proxy.config_file_path = %(here)s/mod_dav_svn.conf
559 564 ## alternative mod_dav config template. This needs to be a mako template
560 565 #svn.proxy.config_template = ~/.rccontrol/enterprise-1/custom_svn_conf.mako
561 566 ## Used as a prefix to the `Location` block in the generated config file.
562 567 ## In most cases it should be set to `/`.
563 568 svn.proxy.location_root = /
564 569 ## Command to reload the mod dav svn configuration on change.
565 570 ## Example: `/etc/init.d/apache2 reload`
566 571 #svn.proxy.reload_cmd = /etc/init.d/apache2 reload
567 572 ## If the timeout expires before the reload command finishes, the command will
568 573 ## be killed. Setting it to zero means no timeout. Defaults to 10 seconds.
569 574 #svn.proxy.reload_timeout = 10
570 575
571 576 ############################################################
572 577 ### SSH Support Settings ###
573 578 ############################################################
574 579
575 580 ## Defines if a custom authorized_keys file should be created and written on
576 581 ## any change user ssh keys. Setting this to false also disables posibility
577 582 ## of adding SSH keys by users from web interface. Super admins can still
578 583 ## manage SSH Keys.
579 584 ssh.generate_authorized_keyfile = false
580 585
581 586 ## Options for ssh, default is `no-pty,no-port-forwarding,no-X11-forwarding,no-agent-forwarding`
582 587 # ssh.authorized_keys_ssh_opts =
583 588
584 589 ## Path to the authrozied_keys file where the generate entries are placed.
585 590 ## It is possible to have multiple key files specified in `sshd_config` e.g.
586 591 ## AuthorizedKeysFile %h/.ssh/authorized_keys %h/.ssh/authorized_keys_rhodecode
587 592 ssh.authorized_keys_file_path = ~/.ssh/authorized_keys_rhodecode
588 593
589 594 ## Command to execute the SSH wrapper. The binary is available in the
590 595 ## rhodecode installation directory.
591 596 ## e.g ~/.rccontrol/community-1/profile/bin/rc-ssh-wrapper
592 597 ssh.wrapper_cmd = ~/.rccontrol/community-1/rc-ssh-wrapper
593 598
594 599 ## Allow shell when executing the ssh-wrapper command
595 600 ssh.wrapper_cmd_allow_shell = false
596 601
597 602 ## Enables logging, and detailed output send back to the client during SSH
598 603 ## operations. Usefull for debugging, shouldn't be used in production.
599 604 ssh.enable_debug_logging = false
600 605
601 606 ## Paths to binary executable, by default they are the names, but we can
602 607 ## override them if we want to use a custom one
603 608 ssh.executable.hg = ~/.rccontrol/vcsserver-1/profile/bin/hg
604 609 ssh.executable.git = ~/.rccontrol/vcsserver-1/profile/bin/git
605 610 ssh.executable.svn = ~/.rccontrol/vcsserver-1/profile/bin/svnserve
606 611
607 612
608 613 ## Dummy marker to add new entries after.
609 614 ## Add any custom entries below. Please don't remove.
610 615 custom.conf = 1
611 616
612 617
613 618 ################################
614 619 ### LOGGING CONFIGURATION ####
615 620 ################################
616 621 [loggers]
617 622 keys = root, sqlalchemy, beaker, rhodecode, ssh_wrapper
618 623
619 624 [handlers]
620 625 keys = console, console_sql
621 626
622 627 [formatters]
623 628 keys = generic, color_formatter, color_formatter_sql
624 629
625 630 #############
626 631 ## LOGGERS ##
627 632 #############
628 633 [logger_root]
629 634 level = NOTSET
630 635 handlers = console
631 636
632 637 [logger_sqlalchemy]
633 638 level = INFO
634 639 handlers = console_sql
635 640 qualname = sqlalchemy.engine
636 641 propagate = 0
637 642
638 643 [logger_beaker]
639 644 level = DEBUG
640 645 handlers =
641 646 qualname = beaker.container
642 647 propagate = 1
643 648
644 649 [logger_rhodecode]
645 650 level = DEBUG
646 651 handlers =
647 652 qualname = rhodecode
648 653 propagate = 1
649 654
650 655 [logger_ssh_wrapper]
651 656 level = DEBUG
652 657 handlers =
653 658 qualname = ssh_wrapper
654 659 propagate = 1
655 660
656 661
657 662 ##############
658 663 ## HANDLERS ##
659 664 ##############
660 665
661 666 [handler_console]
662 667 class = StreamHandler
663 668 args = (sys.stderr, )
664 669 level = INFO
665 670 formatter = generic
666 671
667 672 [handler_console_sql]
668 673 class = StreamHandler
669 674 args = (sys.stderr, )
670 675 level = WARN
671 676 formatter = generic
672 677
673 678 ################
674 679 ## FORMATTERS ##
675 680 ################
676 681
677 682 [formatter_generic]
678 683 class = rhodecode.lib.logging_formatter.ExceptionAwareFormatter
679 684 format = %(asctime)s.%(msecs)03d %(levelname)-5.5s [%(name)s] %(message)s
680 685 datefmt = %Y-%m-%d %H:%M:%S
681 686
682 687 [formatter_color_formatter]
683 688 class = rhodecode.lib.logging_formatter.ColorFormatter
684 689 format = %(asctime)s.%(msecs)03d %(levelname)-5.5s [%(name)s] %(message)s
685 690 datefmt = %Y-%m-%d %H:%M:%S
686 691
687 692 [formatter_color_formatter_sql]
688 693 class = rhodecode.lib.logging_formatter.ColorFormatterSql
689 694 format = %(asctime)s.%(msecs)03d %(levelname)-5.5s [%(name)s] %(message)s
690 695 datefmt = %Y-%m-%d %H:%M:%S
@@ -1,83 +1,81 b''
1 1 # -*- coding: utf-8 -*-
2 2
3 3 # Copyright (C) 2016-2017 RhodeCode GmbH
4 4 #
5 5 # This program is free software: you can redistribute it and/or modify
6 6 # it under the terms of the GNU Affero General Public License, version 3
7 7 # (only), as published by the Free Software Foundation.
8 8 #
9 9 # This program is distributed in the hope that it will be useful,
10 10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 12 # GNU General Public License for more details.
13 13 #
14 14 # You should have received a copy of the GNU Affero General Public License
15 15 # along with this program. If not, see <http://www.gnu.org/licenses/>.
16 16 #
17 17 # This program is dual-licensed. If you wish to learn more about the
18 18 # RhodeCode Enterprise Edition, including its added features, Support services,
19 19 # and proprietary license terms, please see https://rhodecode.com/licenses/
20 20
21 21 import os
22 22 import sys
23 23 import logging
24 24
25 25 import click
26 26
27 from pyramid.paster import bootstrap, setup_logging
28 from pyramid.request import Request
27 from pyramid.paster import setup_logging
29 28
29 from rhodecode.lib.pyramid_utils import bootstrap
30 30 from .backends import SshWrapper
31 31
32 32 log = logging.getLogger(__name__)
33 33
34 34
35 35 def setup_custom_logging(ini_path, debug):
36 36 if debug:
37 37 # enabled rhodecode.ini controlled logging setup
38 38 setup_logging(ini_path)
39 39 else:
40 40 # configure logging in a mode that doesn't print anything.
41 41 # in case of regularly configured logging it gets printed out back
42 42 # to the client doing an SSH command.
43 43 logger = logging.getLogger('')
44 44 null = logging.NullHandler()
45 45 # add the handler to the root logger
46 46 logger.handlers = [null]
47 47
48 48
49 49 @click.command()
50 50 @click.argument('ini_path', type=click.Path(exists=True))
51 51 @click.option(
52 52 '--mode', '-m', required=False, default='auto',
53 53 type=click.Choice(['auto', 'vcs', 'git', 'hg', 'svn', 'test']),
54 54 help='mode of operation')
55 55 @click.option('--user', help='Username for which the command will be executed')
56 56 @click.option('--user-id', help='User ID for which the command will be executed')
57 57 @click.option('--key-id', help='ID of the key from the database')
58 58 @click.option('--shell', '-s', is_flag=True, help='Allow Shell')
59 59 @click.option('--debug', is_flag=True, help='Enabled detailed output logging')
60 60 def main(ini_path, mode, user, user_id, key_id, shell, debug):
61 61 setup_custom_logging(ini_path, debug)
62 62
63 63 command = os.environ.get('SSH_ORIGINAL_COMMAND', '')
64 64 if not command and mode not in ['test']:
65 65 raise ValueError(
66 66 'Unable to fetch SSH_ORIGINAL_COMMAND from environment.'
67 67 'Please make sure this is set and available during execution '
68 68 'of this script.')
69 69 connection_info = os.environ.get('SSH_CONNECTION', '')
70 70
71 # TODO(marcink): configure the running host...
72 request = Request.blank('/', base_url='http://localhost:8080')
73 with bootstrap(ini_path, request=request) as env:
71 with bootstrap(ini_path) as env:
74 72 try:
75 73 ssh_wrapper = SshWrapper(
76 74 command, connection_info, mode,
77 75 user, user_id, key_id, shell, ini_path, env)
78 76 except Exception:
79 77 log.exception('Failed to execute SshWrapper')
80 78 sys.exit(-5)
81 79
82 80 return_code = ssh_wrapper.wrap()
83 81 sys.exit(return_code)
@@ -1,769 +1,774 b''
1 1
2 2
3 3 ################################################################################
4 4 ## RHODECODE COMMUNITY EDITION CONFIGURATION ##
5 5 # The %(here)s variable will be replaced with the parent directory of this file#
6 6 ################################################################################
7 7
8 8 [DEFAULT]
9 9 debug = true
10 10
11 11 ################################################################################
12 12 ## EMAIL CONFIGURATION ##
13 13 ## Uncomment and replace with the email address which should receive ##
14 14 ## any error reports after an application crash ##
15 15 ## Additionally these settings will be used by the RhodeCode mailing system ##
16 16 ################################################################################
17 17
18 18 ## prefix all emails subjects with given prefix, helps filtering out emails
19 19 #email_prefix = [RhodeCode]
20 20
21 21 ## email FROM address all mails will be sent
22 22 #app_email_from = rhodecode-noreply@localhost
23 23
24 24 ## Uncomment and replace with the address which should receive any error report
25 25 ## note: using appenlight for error handling doesn't need this to be uncommented
26 26 #email_to = admin@localhost
27 27
28 28 ## in case of Application errors, sent an error email form
29 29 #error_email_from = rhodecode_error@localhost
30 30
31 31 ## additional error message to be send in case of server crash
32 32 #error_message =
33 33
34 34
35 35 #smtp_server = mail.server.com
36 36 #smtp_username =
37 37 #smtp_password =
38 38 #smtp_port =
39 39 #smtp_use_tls = false
40 40 #smtp_use_ssl = true
41 41 ## Specify available auth parameters here (e.g. LOGIN PLAIN CRAM-MD5, etc.)
42 42 #smtp_auth =
43 43
44 44 [server:main]
45 45 ## COMMON ##
46 46 host = 0.0.0.0
47 47 port = 5000
48 48
49 49 ##################################
50 50 ## WAITRESS WSGI SERVER ##
51 51 ## Recommended for Development ##
52 52 ##################################
53 53
54 54 use = egg:waitress#main
55 55 ## number of worker threads
56 56 threads = 5
57 57 ## MAX BODY SIZE 100GB
58 58 max_request_body_size = 107374182400
59 59 ## Use poll instead of select, fixes file descriptors limits problems.
60 60 ## May not work on old windows systems.
61 61 asyncore_use_poll = true
62 62
63 63
64 64 ##########################
65 65 ## GUNICORN WSGI SERVER ##
66 66 ##########################
67 67 ## run with gunicorn --log-config rhodecode.ini --paste rhodecode.ini
68 68
69 69 #use = egg:gunicorn#main
70 70 ## Sets the number of process workers. You must set `instance_id = *`
71 71 ## when this option is set to more than one worker, recommended
72 72 ## value is (2 * NUMBER_OF_CPUS + 1), eg 2CPU = 5 workers
73 73 ## The `instance_id = *` must be set in the [app:main] section below
74 74 #workers = 2
75 75 ## number of threads for each of the worker, must be set to 1 for gevent
76 76 ## generally recommened to be at 1
77 77 #threads = 1
78 78 ## process name
79 79 #proc_name = rhodecode
80 80 ## type of worker class, one of sync, gevent
81 81 ## recommended for bigger setup is using of of other than sync one
82 82 #worker_class = sync
83 83 ## The maximum number of simultaneous clients. Valid only for Gevent
84 84 #worker_connections = 10
85 85 ## max number of requests that worker will handle before being gracefully
86 86 ## restarted, could prevent memory leaks
87 87 #max_requests = 1000
88 88 #max_requests_jitter = 30
89 89 ## amount of time a worker can spend with handling a request before it
90 90 ## gets killed and restarted. Set to 6hrs
91 91 #timeout = 21600
92 92
93 93 ## UWSGI ##
94 94 ## run with uwsgi --ini-paste-logged <inifile.ini>
95 95 #[uwsgi]
96 96 #socket = /tmp/uwsgi.sock
97 97 #master = true
98 98 #http = 127.0.0.1:5000
99 99
100 100 ## set as deamon and redirect all output to file
101 101 #daemonize = ./uwsgi_rhodecode.log
102 102
103 103 ## master process PID
104 104 #pidfile = ./uwsgi_rhodecode.pid
105 105
106 106 ## stats server with workers statistics, use uwsgitop
107 107 ## for monitoring, `uwsgitop 127.0.0.1:1717`
108 108 #stats = 127.0.0.1:1717
109 109 #memory-report = true
110 110
111 111 ## log 5XX errors
112 112 #log-5xx = true
113 113
114 114 ## Set the socket listen queue size.
115 115 #listen = 256
116 116
117 117 ## Gracefully Reload workers after the specified amount of managed requests
118 118 ## (avoid memory leaks).
119 119 #max-requests = 1000
120 120
121 121 ## enable large buffers
122 122 #buffer-size=65535
123 123
124 124 ## socket and http timeouts ##
125 125 #http-timeout=3600
126 126 #socket-timeout=3600
127 127
128 128 ## Log requests slower than the specified number of milliseconds.
129 129 #log-slow = 10
130 130
131 131 ## Exit if no app can be loaded.
132 132 #need-app = true
133 133
134 134 ## Set lazy mode (load apps in workers instead of master).
135 135 #lazy = true
136 136
137 137 ## scaling ##
138 138 ## set cheaper algorithm to use, if not set default will be used
139 139 #cheaper-algo = spare
140 140
141 141 ## minimum number of workers to keep at all times
142 142 #cheaper = 1
143 143
144 144 ## number of workers to spawn at startup
145 145 #cheaper-initial = 1
146 146
147 147 ## maximum number of workers that can be spawned
148 148 #workers = 4
149 149
150 150 ## how many workers should be spawned at a time
151 151 #cheaper-step = 1
152 152
153 153 ## prefix middleware for RhodeCode.
154 154 ## recommended when using proxy setup.
155 155 ## allows to set RhodeCode under a prefix in server.
156 156 ## eg https://server.com/custom_prefix. Enable `filter-with =` option below as well.
157 157 ## And set your prefix like: `prefix = /custom_prefix`
158 158 ## be sure to also set beaker.session.cookie_path = /custom_prefix if you need
159 159 ## to make your cookies only work on prefix url
160 160 [filter:proxy-prefix]
161 161 use = egg:PasteDeploy#prefix
162 162 prefix = /
163 163
164 164 [app:main]
165 165 is_test = True
166 166 use = egg:rhodecode-enterprise-ce
167 167
168 168 ## enable proxy prefix middleware, defined above
169 169 #filter-with = proxy-prefix
170 170
171 171
172 172 ## RHODECODE PLUGINS ##
173 173 rhodecode.includes = rhodecode.api
174 174
175 175 # api prefix url
176 176 rhodecode.api.url = /_admin/api
177 177
178 178
179 179 ## END RHODECODE PLUGINS ##
180 180
181 181 ## encryption key used to encrypt social plugin tokens,
182 182 ## remote_urls with credentials etc, if not set it defaults to
183 183 ## `beaker.session.secret`
184 184 #rhodecode.encrypted_values.secret =
185 185
186 186 ## decryption strict mode (enabled by default). It controls if decryption raises
187 187 ## `SignatureVerificationError` in case of wrong key, or damaged encryption data.
188 188 #rhodecode.encrypted_values.strict = false
189 189
190 190 ## return gzipped responses from Rhodecode (static files/application)
191 191 gzip_responses = false
192 192
193 193 ## autogenerate javascript routes file on startup
194 194 generate_js_files = false
195 195
196 196 ## Optional Languages
197 197 ## en(default), be, de, es, fr, it, ja, pl, pt, ru, zh
198 198 lang = en
199 199
200 200 ## perform a full repository scan on each server start, this should be
201 201 ## set to false after first startup, to allow faster server restarts.
202 202 startup.import_repos = true
203 203
204 204 ## Uncomment and set this path to use archive download cache.
205 205 ## Once enabled, generated archives will be cached at this location
206 206 ## and served from the cache during subsequent requests for the same archive of
207 207 ## the repository.
208 208 #archive_cache_dir = /tmp/tarballcache
209 209
210 ## URL at which the application is running. This is used for bootstraping
211 ## requests in context when no web request is available. Used in ishell, or
212 ## SSH calls. Set this for events to receive proper url for SSH calls.
213 app.base_url = http://rhodecode.local
214
210 215 ## change this to unique ID for security
211 216 app_instance_uuid = rc-production
212 217
213 218 ## cut off limit for large diffs (size in bytes)
214 219 cut_off_limit_diff = 1024000
215 220 cut_off_limit_file = 256000
216 221
217 222 ## use cache version of scm repo everywhere
218 223 vcs_full_cache = false
219 224
220 225 ## force https in RhodeCode, fixes https redirects, assumes it's always https
221 226 ## Normally this is controlled by proper http flags sent from http server
222 227 force_https = false
223 228
224 229 ## use Strict-Transport-Security headers
225 230 use_htsts = false
226 231
227 232 ## number of commits stats will parse on each iteration
228 233 commit_parse_limit = 25
229 234
230 235 ## git rev filter option, --all is the default filter, if you need to
231 236 ## hide all refs in changelog switch this to --branches --tags
232 237 git_rev_filter = --all
233 238
234 239 # Set to true if your repos are exposed using the dumb protocol
235 240 git_update_server_info = false
236 241
237 242 ## RSS/ATOM feed options
238 243 rss_cut_off_limit = 256000
239 244 rss_items_per_page = 10
240 245 rss_include_diff = false
241 246
242 247 ## gist URL alias, used to create nicer urls for gist. This should be an
243 248 ## url that does rewrites to _admin/gists/{gistid}.
244 249 ## example: http://gist.rhodecode.org/{gistid}. Empty means use the internal
245 250 ## RhodeCode url, ie. http[s]://rhodecode.server/_admin/gists/{gistid}
246 251 gist_alias_url =
247 252
248 253 ## List of views (using glob pattern syntax) that AUTH TOKENS could be
249 254 ## used for access.
250 255 ## Adding ?auth_token=TOKEN_HASH to the url authenticates this request as if it
251 256 ## came from the the logged in user who own this authentication token.
252 257 ## Additionally @TOKEN syntaxt can be used to bound the view to specific
253 258 ## authentication token. Such view would be only accessible when used together
254 259 ## with this authentication token
255 260 ##
256 261 ## list of all views can be found under `/_admin/permissions/auth_token_access`
257 262 ## The list should be "," separated and on a single line.
258 263 ##
259 264 ## Most common views to enable:
260 265 # RepoCommitsView:repo_commit_download
261 266 # RepoCommitsView:repo_commit_patch
262 267 # RepoCommitsView:repo_commit_raw
263 268 # RepoCommitsView:repo_commit_raw@TOKEN
264 269 # RepoFilesView:repo_files_diff
265 270 # RepoFilesView:repo_archivefile
266 271 # RepoFilesView:repo_file_raw
267 272 # GistView:*
268 273 api_access_controllers_whitelist =
269 274
270 275 ## default encoding used to convert from and to unicode
271 276 ## can be also a comma separated list of encoding in case of mixed encodings
272 277 default_encoding = UTF-8
273 278
274 279 ## instance-id prefix
275 280 ## a prefix key for this instance used for cache invalidation when running
276 281 ## multiple instances of rhodecode, make sure it's globally unique for
277 282 ## all running rhodecode instances. Leave empty if you don't use it
278 283 instance_id =
279 284
280 285 ## Fallback authentication plugin. Set this to a plugin ID to force the usage
281 286 ## of an authentication plugin also if it is disabled by it's settings.
282 287 ## This could be useful if you are unable to log in to the system due to broken
283 288 ## authentication settings. Then you can enable e.g. the internal rhodecode auth
284 289 ## module to log in again and fix the settings.
285 290 ##
286 291 ## Available builtin plugin IDs (hash is part of the ID):
287 292 ## egg:rhodecode-enterprise-ce#rhodecode
288 293 ## egg:rhodecode-enterprise-ce#pam
289 294 ## egg:rhodecode-enterprise-ce#ldap
290 295 ## egg:rhodecode-enterprise-ce#jasig_cas
291 296 ## egg:rhodecode-enterprise-ce#headers
292 297 ## egg:rhodecode-enterprise-ce#crowd
293 298 #rhodecode.auth_plugin_fallback = egg:rhodecode-enterprise-ce#rhodecode
294 299
295 300 ## alternative return HTTP header for failed authentication. Default HTTP
296 301 ## response is 401 HTTPUnauthorized. Currently HG clients have troubles with
297 302 ## handling that causing a series of failed authentication calls.
298 303 ## Set this variable to 403 to return HTTPForbidden, or any other HTTP code
299 304 ## This will be served instead of default 401 on bad authnetication
300 305 auth_ret_code =
301 306
302 307 ## use special detection method when serving auth_ret_code, instead of serving
303 308 ## ret_code directly, use 401 initially (Which triggers credentials prompt)
304 309 ## and then serve auth_ret_code to clients
305 310 auth_ret_code_detection = false
306 311
307 312 ## locking return code. When repository is locked return this HTTP code. 2XX
308 313 ## codes don't break the transactions while 4XX codes do
309 314 lock_ret_code = 423
310 315
311 316 ## allows to change the repository location in settings page
312 317 allow_repo_location_change = true
313 318
314 319 ## allows to setup custom hooks in settings page
315 320 allow_custom_hooks_settings = true
316 321
317 322 ## generated license token, goto license page in RhodeCode settings to obtain
318 323 ## new token
319 324 license_token = abra-cada-bra1-rce3
320 325
321 326 ## supervisor connection uri, for managing supervisor and logs.
322 327 supervisor.uri =
323 328 ## supervisord group name/id we only want this RC instance to handle
324 329 supervisor.group_id = dev
325 330
326 331 ## Display extended labs settings
327 332 labs_settings_active = true
328 333
329 334 ####################################
330 335 ### CELERY CONFIG ####
331 336 ####################################
332 337 use_celery = false
333 338 broker.host = localhost
334 339 broker.vhost = rabbitmqhost
335 340 broker.port = 5672
336 341 broker.user = rabbitmq
337 342 broker.password = qweqwe
338 343
339 344 celery.imports = rhodecode.lib.celerylib.tasks
340 345
341 346 celery.result.backend = amqp
342 347 celery.result.dburi = amqp://
343 348 celery.result.serialier = json
344 349
345 350 #celery.send.task.error.emails = true
346 351 #celery.amqp.task.result.expires = 18000
347 352
348 353 celeryd.concurrency = 2
349 354 #celeryd.log.file = celeryd.log
350 355 celeryd.log.level = debug
351 356 celeryd.max.tasks.per.child = 1
352 357
353 358 ## tasks will never be sent to the queue, but executed locally instead.
354 359 celery.always.eager = false
355 360
356 361 ####################################
357 362 ### BEAKER CACHE ####
358 363 ####################################
359 364 # default cache dir for templates. Putting this into a ramdisk
360 365 ## can boost performance, eg. %(here)s/data_ramdisk
361 366 cache_dir = %(here)s/data
362 367
363 368 ## locking and default file storage for Beaker. Putting this into a ramdisk
364 369 ## can boost performance, eg. %(here)s/data_ramdisk/cache/beaker_data
365 370 beaker.cache.data_dir = %(here)s/rc/data/cache/beaker_data
366 371 beaker.cache.lock_dir = %(here)s/rc/data/cache/beaker_lock
367 372
368 373 beaker.cache.regions = super_short_term, short_term, long_term, sql_cache_short, auth_plugins, repo_cache_long
369 374
370 375 beaker.cache.super_short_term.type = memory
371 376 beaker.cache.super_short_term.expire = 1
372 377 beaker.cache.super_short_term.key_length = 256
373 378
374 379 beaker.cache.short_term.type = memory
375 380 beaker.cache.short_term.expire = 60
376 381 beaker.cache.short_term.key_length = 256
377 382
378 383 beaker.cache.long_term.type = memory
379 384 beaker.cache.long_term.expire = 36000
380 385 beaker.cache.long_term.key_length = 256
381 386
382 387 beaker.cache.sql_cache_short.type = memory
383 388 beaker.cache.sql_cache_short.expire = 1
384 389 beaker.cache.sql_cache_short.key_length = 256
385 390
386 391 ## default is memory cache, configure only if required
387 392 ## using multi-node or multi-worker setup
388 393 #beaker.cache.auth_plugins.type = ext:database
389 394 #beaker.cache.auth_plugins.lock_dir = %(here)s/data/cache/auth_plugin_lock
390 395 #beaker.cache.auth_plugins.url = postgresql://postgres:secret@localhost/rhodecode
391 396 #beaker.cache.auth_plugins.url = mysql://root:secret@127.0.0.1/rhodecode
392 397 #beaker.cache.auth_plugins.sa.pool_recycle = 3600
393 398 #beaker.cache.auth_plugins.sa.pool_size = 10
394 399 #beaker.cache.auth_plugins.sa.max_overflow = 0
395 400
396 401 beaker.cache.repo_cache_long.type = memorylru_base
397 402 beaker.cache.repo_cache_long.max_items = 4096
398 403 beaker.cache.repo_cache_long.expire = 2592000
399 404
400 405 ## default is memorylru_base cache, configure only if required
401 406 ## using multi-node or multi-worker setup
402 407 #beaker.cache.repo_cache_long.type = ext:memcached
403 408 #beaker.cache.repo_cache_long.url = localhost:11211
404 409 #beaker.cache.repo_cache_long.expire = 1209600
405 410 #beaker.cache.repo_cache_long.key_length = 256
406 411
407 412 ####################################
408 413 ### BEAKER SESSION ####
409 414 ####################################
410 415
411 416 ## .session.type is type of storage options for the session, current allowed
412 417 ## types are file, ext:memcached, ext:database, and memory (default).
413 418 beaker.session.type = file
414 419 beaker.session.data_dir = %(here)s/rc/data/sessions/data
415 420
416 421 ## db based session, fast, and allows easy management over logged in users
417 422 #beaker.session.type = ext:database
418 423 #beaker.session.table_name = db_session
419 424 #beaker.session.sa.url = postgresql://postgres:secret@localhost/rhodecode
420 425 #beaker.session.sa.url = mysql://root:secret@127.0.0.1/rhodecode
421 426 #beaker.session.sa.pool_recycle = 3600
422 427 #beaker.session.sa.echo = false
423 428
424 429 beaker.session.key = rhodecode
425 430 beaker.session.secret = test-rc-uytcxaz
426 431 beaker.session.lock_dir = %(here)s/rc/data/sessions/lock
427 432
428 433 ## Secure encrypted cookie. Requires AES and AES python libraries
429 434 ## you must disable beaker.session.secret to use this
430 435 #beaker.session.encrypt_key = key_for_encryption
431 436 #beaker.session.validate_key = validation_key
432 437
433 438 ## sets session as invalid(also logging out user) if it haven not been
434 439 ## accessed for given amount of time in seconds
435 440 beaker.session.timeout = 2592000
436 441 beaker.session.httponly = true
437 442 ## Path to use for the cookie. Set to prefix if you use prefix middleware
438 443 #beaker.session.cookie_path = /custom_prefix
439 444
440 445 ## uncomment for https secure cookie
441 446 beaker.session.secure = false
442 447
443 448 ## auto save the session to not to use .save()
444 449 beaker.session.auto = false
445 450
446 451 ## default cookie expiration time in seconds, set to `true` to set expire
447 452 ## at browser close
448 453 #beaker.session.cookie_expires = 3600
449 454
450 455 ###################################
451 456 ## SEARCH INDEXING CONFIGURATION ##
452 457 ###################################
453 458 ## Full text search indexer is available in rhodecode-tools under
454 459 ## `rhodecode-tools index` command
455 460
456 461 ## WHOOSH Backend, doesn't require additional services to run
457 462 ## it works good with few dozen repos
458 463 search.module = rhodecode.lib.index.whoosh
459 464 search.location = %(here)s/data/index
460 465
461 466 ########################################
462 467 ### CHANNELSTREAM CONFIG ####
463 468 ########################################
464 469 ## channelstream enables persistent connections and live notification
465 470 ## in the system. It's also used by the chat system
466 471
467 472 channelstream.enabled = false
468 473
469 474 ## server address for channelstream server on the backend
470 475 channelstream.server = 127.0.0.1:9800
471 476 ## location of the channelstream server from outside world
472 477 ## use ws:// for http or wss:// for https. This address needs to be handled
473 478 ## by external HTTP server such as Nginx or Apache
474 479 ## see nginx/apache configuration examples in our docs
475 480 channelstream.ws_url = ws://rhodecode.yourserver.com/_channelstream
476 481 channelstream.secret = secret
477 482 channelstream.history.location = %(here)s/channelstream_history
478 483
479 484 ## Internal application path that Javascript uses to connect into.
480 485 ## If you use proxy-prefix the prefix should be added before /_channelstream
481 486 channelstream.proxy_path = /_channelstream
482 487
483 488
484 489 ###################################
485 490 ## APPENLIGHT CONFIG ##
486 491 ###################################
487 492
488 493 ## Appenlight is tailored to work with RhodeCode, see
489 494 ## http://appenlight.com for details how to obtain an account
490 495
491 496 ## appenlight integration enabled
492 497 appenlight = false
493 498
494 499 appenlight.server_url = https://api.appenlight.com
495 500 appenlight.api_key = YOUR_API_KEY
496 501 #appenlight.transport_config = https://api.appenlight.com?threaded=1&timeout=5
497 502
498 503 # used for JS client
499 504 appenlight.api_public_key = YOUR_API_PUBLIC_KEY
500 505
501 506 ## TWEAK AMOUNT OF INFO SENT HERE
502 507
503 508 ## enables 404 error logging (default False)
504 509 appenlight.report_404 = false
505 510
506 511 ## time in seconds after request is considered being slow (default 1)
507 512 appenlight.slow_request_time = 1
508 513
509 514 ## record slow requests in application
510 515 ## (needs to be enabled for slow datastore recording and time tracking)
511 516 appenlight.slow_requests = true
512 517
513 518 ## enable hooking to application loggers
514 519 appenlight.logging = true
515 520
516 521 ## minimum log level for log capture
517 522 appenlight.logging.level = WARNING
518 523
519 524 ## send logs only from erroneous/slow requests
520 525 ## (saves API quota for intensive logging)
521 526 appenlight.logging_on_error = false
522 527
523 528 ## list of additonal keywords that should be grabbed from environ object
524 529 ## can be string with comma separated list of words in lowercase
525 530 ## (by default client will always send following info:
526 531 ## 'REMOTE_USER', 'REMOTE_ADDR', 'SERVER_NAME', 'CONTENT_TYPE' + all keys that
527 532 ## start with HTTP* this list be extended with additional keywords here
528 533 appenlight.environ_keys_whitelist =
529 534
530 535 ## list of keywords that should be blanked from request object
531 536 ## can be string with comma separated list of words in lowercase
532 537 ## (by default client will always blank keys that contain following words
533 538 ## 'password', 'passwd', 'pwd', 'auth_tkt', 'secret', 'csrf'
534 539 ## this list be extended with additional keywords set here
535 540 appenlight.request_keys_blacklist =
536 541
537 542 ## list of namespaces that should be ignores when gathering log entries
538 543 ## can be string with comma separated list of namespaces
539 544 ## (by default the client ignores own entries: appenlight_client.client)
540 545 appenlight.log_namespace_blacklist =
541 546
542 547
543 548 ################################################################################
544 549 ## WARNING: *THE LINE BELOW MUST BE UNCOMMENTED ON A PRODUCTION ENVIRONMENT* ##
545 550 ## Debug mode will enable the interactive debugging tool, allowing ANYONE to ##
546 551 ## execute malicious code after an exception is raised. ##
547 552 ################################################################################
548 553 set debug = false
549 554
550 555
551 556 ##############
552 557 ## STYLING ##
553 558 ##############
554 559 debug_style = false
555 560
556 561 ###########################################
557 562 ### MAIN RHODECODE DATABASE CONFIG ###
558 563 ###########################################
559 564 #sqlalchemy.db1.url = sqlite:///%(here)s/rhodecode_test.db?timeout=30
560 565 #sqlalchemy.db1.url = postgresql://postgres:qweqwe@localhost/rhodecode_test
561 566 #sqlalchemy.db1.url = mysql://root:qweqwe@localhost/rhodecode_test
562 567 sqlalchemy.db1.url = sqlite:///%(here)s/rhodecode_test.db?timeout=30
563 568
564 569 # see sqlalchemy docs for other advanced settings
565 570
566 571 ## print the sql statements to output
567 572 sqlalchemy.db1.echo = false
568 573 ## recycle the connections after this amount of seconds
569 574 sqlalchemy.db1.pool_recycle = 3600
570 575 sqlalchemy.db1.convert_unicode = true
571 576
572 577 ## the number of connections to keep open inside the connection pool.
573 578 ## 0 indicates no limit
574 579 #sqlalchemy.db1.pool_size = 5
575 580
576 581 ## the number of connections to allow in connection pool "overflow", that is
577 582 ## connections that can be opened above and beyond the pool_size setting,
578 583 ## which defaults to five.
579 584 #sqlalchemy.db1.max_overflow = 10
580 585
581 586
582 587 ##################
583 588 ### VCS CONFIG ###
584 589 ##################
585 590 vcs.server.enable = true
586 591 vcs.server = localhost:9901
587 592
588 593 ## Web server connectivity protocol, responsible for web based VCS operatations
589 594 ## Available protocols are:
590 595 ## `http` - use http-rpc backend (default)
591 596 vcs.server.protocol = http
592 597
593 598 ## Push/Pull operations protocol, available options are:
594 599 ## `http` - use http-rpc backend (default)
595 600 ## `vcsserver.scm_app` - internal app (EE only)
596 601 vcs.scm_app_implementation = http
597 602
598 603 ## Push/Pull operations hooks protocol, available options are:
599 604 ## `http` - use http-rpc backend (default)
600 605 vcs.hooks.protocol = http
601 606
602 607 vcs.server.log_level = debug
603 608 ## Start VCSServer with this instance as a subprocess, usefull for development
604 609 vcs.start_server = false
605 610
606 611 ## List of enabled VCS backends, available options are:
607 612 ## `hg` - mercurial
608 613 ## `git` - git
609 614 ## `svn` - subversion
610 615 vcs.backends = hg, git, svn
611 616
612 617 vcs.connection_timeout = 3600
613 618 ## Compatibility version when creating SVN repositories. Defaults to newest version when commented out.
614 619 ## Available options are: pre-1.4-compatible, pre-1.5-compatible, pre-1.6-compatible, pre-1.8-compatible, pre-1.9-compatible
615 620 #vcs.svn.compatible_version = pre-1.8-compatible
616 621
617 622
618 623 ############################################################
619 624 ### Subversion proxy support (mod_dav_svn) ###
620 625 ### Maps RhodeCode repo groups into SVN paths for Apache ###
621 626 ############################################################
622 627 ## Enable or disable the config file generation.
623 628 svn.proxy.generate_config = false
624 629 ## Generate config file with `SVNListParentPath` set to `On`.
625 630 svn.proxy.list_parent_path = true
626 631 ## Set location and file name of generated config file.
627 632 svn.proxy.config_file_path = %(here)s/mod_dav_svn.conf
628 633 ## Used as a prefix to the `Location` block in the generated config file.
629 634 ## In most cases it should be set to `/`.
630 635 svn.proxy.location_root = /
631 636 ## Command to reload the mod dav svn configuration on change.
632 637 ## Example: `/etc/init.d/apache2 reload`
633 638 #svn.proxy.reload_cmd = /etc/init.d/apache2 reload
634 639 ## If the timeout expires before the reload command finishes, the command will
635 640 ## be killed. Setting it to zero means no timeout. Defaults to 10 seconds.
636 641 #svn.proxy.reload_timeout = 10
637 642
638 643 ############################################################
639 644 ### SSH Support Settings ###
640 645 ############################################################
641 646
642 647 ## Defines if the authorized_keys file should be written on any change of
643 648 ## user ssh keys, setting this to false also disables posibility of adding
644 649 ## ssh keys for users from web interface.
645 650 ssh.generate_authorized_keyfile = true
646 651
647 652 ## Options for ssh, default is `no-pty,no-port-forwarding,no-X11-forwarding,no-agent-forwarding`
648 653 # ssh.authorized_keys_ssh_opts =
649 654
650 655 ## File to generate the authorized keys together with options
651 656 ## It is possible to have multiple key files specified in `sshd_config` e.g.
652 657 ## AuthorizedKeysFile %h/.ssh/authorized_keys %h/.ssh/authorized_keys_rhodecode
653 658 ssh.authorized_keys_file_path = %(here)s/rc/authorized_keys_rhodecode
654 659
655 660 ## Command to execute the SSH wrapper. The binary is available in the
656 661 ## rhodecode installation directory.
657 662 ## e.g ~/.rccontrol/community-1/profile/bin/rc-ssh-wrapper
658 663 ssh.wrapper_cmd = ~/.rccontrol/community-1/rc-ssh-wrapper
659 664
660 665 ## Allow shell when executing the ssh-wrapper command
661 666 ssh.wrapper_cmd_allow_shell = false
662 667
663 668 ## Enables logging, and detailed output send back to the client. Usefull for
664 669 ## debugging, shouldn't be used in production.
665 670 ssh.enable_debug_logging = false
666 671
667 672 ## Paths to binary executrables, by default they are the names, but we can
668 673 ## override them if we want to use a custom one
669 674 ssh.executable.hg = ~/.rccontrol/vcsserver-1/profile/bin/hg
670 675 ssh.executable.git = ~/.rccontrol/vcsserver-1/profile/bin/git
671 676 ssh.executable.svn = ~/.rccontrol/vcsserver-1/profile/bin/svnserve
672 677
673 678
674 679 ## Dummy marker to add new entries after.
675 680 ## Add any custom entries below. Please don't remove.
676 681 custom.conf = 1
677 682
678 683
679 684 ################################
680 685 ### LOGGING CONFIGURATION ####
681 686 ################################
682 687 [loggers]
683 688 keys = root, routes, rhodecode, sqlalchemy, beaker, templates, ssh_wrapper
684 689
685 690 [handlers]
686 691 keys = console, console_sql
687 692
688 693 [formatters]
689 694 keys = generic, color_formatter, color_formatter_sql
690 695
691 696 #############
692 697 ## LOGGERS ##
693 698 #############
694 699 [logger_root]
695 700 level = NOTSET
696 701 handlers = console
697 702
698 703 [logger_routes]
699 704 level = DEBUG
700 705 handlers =
701 706 qualname = routes.middleware
702 707 ## "level = DEBUG" logs the route matched and routing variables.
703 708 propagate = 1
704 709
705 710 [logger_beaker]
706 711 level = DEBUG
707 712 handlers =
708 713 qualname = beaker.container
709 714 propagate = 1
710 715
711 716 [logger_templates]
712 717 level = INFO
713 718 handlers =
714 719 qualname = pylons.templating
715 720 propagate = 1
716 721
717 722 [logger_rhodecode]
718 723 level = DEBUG
719 724 handlers =
720 725 qualname = rhodecode
721 726 propagate = 1
722 727
723 728 [logger_sqlalchemy]
724 729 level = ERROR
725 730 handlers = console_sql
726 731 qualname = sqlalchemy.engine
727 732 propagate = 0
728 733
729 734 [logger_ssh_wrapper]
730 735 level = DEBUG
731 736 handlers =
732 737 qualname = ssh_wrapper
733 738 propagate = 1
734 739
735 740
736 741 ##############
737 742 ## HANDLERS ##
738 743 ##############
739 744
740 745 [handler_console]
741 746 class = StreamHandler
742 747 args = (sys.stderr,)
743 748 level = DEBUG
744 749 formatter = generic
745 750
746 751 [handler_console_sql]
747 752 class = StreamHandler
748 753 args = (sys.stderr,)
749 754 level = WARN
750 755 formatter = generic
751 756
752 757 ################
753 758 ## FORMATTERS ##
754 759 ################
755 760
756 761 [formatter_generic]
757 762 class = rhodecode.lib.logging_formatter.ExceptionAwareFormatter
758 763 format = %(asctime)s.%(msecs)03d %(levelname)-5.5s [%(name)s] %(message)s
759 764 datefmt = %Y-%m-%d %H:%M:%S
760 765
761 766 [formatter_color_formatter]
762 767 class = rhodecode.lib.logging_formatter.ColorFormatter
763 768 format = %(asctime)s.%(msecs)03d %(levelname)-5.5s [%(name)s] %(message)s
764 769 datefmt = %Y-%m-%d %H:%M:%S
765 770
766 771 [formatter_color_formatter_sql]
767 772 class = rhodecode.lib.logging_formatter.ColorFormatterSql
768 773 format = %(asctime)s.%(msecs)03d %(levelname)-5.5s [%(name)s] %(message)s
769 774 datefmt = %Y-%m-%d %H:%M:%S
General Comments 0
You need to be logged in to leave comments. Login now