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