Shawn O. Pearce | e31d02c | 2009-12-08 12:21:37 -0800 | [diff] [blame] | 1 | Gerrit Code Review - Configuration |
| 2 | ================================== |
Shawn O. Pearce | d2b73db | 2009-01-09 11:55:47 -0800 | [diff] [blame] | 3 | |
Shawn O. Pearce | c5fed82 | 2009-11-17 16:10:10 -0800 | [diff] [blame] | 4 | File `etc/gerrit.config` |
| 5 | ------------------------ |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 6 | |
Shawn O. Pearce | c5fed82 | 2009-11-17 16:10:10 -0800 | [diff] [blame] | 7 | The optional file `'$site_path'/etc/gerrit.config` is a Git-style |
| 8 | config file that controls many host specific settings for Gerrit. |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 9 | |
| 10 | [NOTE] |
Shawn O. Pearce | c5fed82 | 2009-11-17 16:10:10 -0800 | [diff] [blame] | 11 | The contents of the `etc/gerrit.config` file are cached at startup |
Brandon Casey | 4a21add | 2011-07-05 13:14:18 -0500 | [diff] [blame] | 12 | by Gerrit. If you modify any properties in this file, Gerrit needs |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 13 | to be restarted before it will use the new values. |
| 14 | |
Shawn O. Pearce | c5fed82 | 2009-11-17 16:10:10 -0800 | [diff] [blame] | 15 | Sample `etc/gerrit.config`: |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 16 | ---- |
| 17 | [core] |
Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 18 | packedGitLimit = 200 m |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 19 | |
| 20 | [cache] |
Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 21 | directory = /var/cache/gerrit2 |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 22 | |
| 23 | [cache "diff"] |
Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 24 | diskbuffer = 10 m |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 25 | ---- |
| 26 | |
Dave Borowitz | 45baa89 | 2012-02-23 16:43:05 -0800 | [diff] [blame] | 27 | [[accounts]]Section accounts |
| 28 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 29 | |
Matthias Sohn | f336066 | 2012-04-05 15:42:52 +0200 | [diff] [blame] | 30 | [[accounts.visibility]]accounts.visibility:: |
Dave Borowitz | 45baa89 | 2012-02-23 16:43:05 -0800 | [diff] [blame] | 31 | + |
| 32 | Controls visibility of other users' dashboard pages and |
| 33 | completion suggestions to web users. |
| 34 | + |
| 35 | If `ALL`, all users are visible to all other users, even |
| 36 | anonymous users. |
| 37 | + |
| 38 | If `SAME_GROUP`, only users who are also members of a group the |
| 39 | current user is a member of are visible. |
| 40 | + |
| 41 | If `VISIBLE_GROUP`, only users who are members of at least one group |
| 42 | that is visible to the current user are visible. |
| 43 | + |
| 44 | If `NONE`, no users other than the current user are visible. |
| 45 | + |
| 46 | Default is `ALL`. |
| 47 | |
Edwin Kempin | 49cb3e1 | 2011-06-29 14:35:14 +0200 | [diff] [blame] | 48 | [[addreviewer]]Section addreviewer |
| 49 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 50 | |
| 51 | [[addreviewer.maxWithoutConfirmation]]addreviewer.maxWithoutConfirmation:: |
| 52 | + |
| 53 | The maximum number of reviewers a user can add at once by adding a |
| 54 | group as reviewer without being asked to confirm the operation. |
| 55 | + |
| 56 | If set to 0, the user will never be asked to confirm adding a group |
| 57 | as reviewer. |
| 58 | + |
| 59 | Default is 10. |
Edwin Kempin | 5e65d9b | 2011-07-08 07:35:48 +0200 | [diff] [blame] | 60 | + |
| 61 | This setting only applies for adding reviewers in the Gerrit WebUI, |
| 62 | but is ignored when adding reviewers with the |
Edwin Kempin | 33e92d0 | 2011-07-11 22:00:57 +0200 | [diff] [blame] | 63 | link:cmd-set-reviewers.html[set-reviewers] command. |
Edwin Kempin | 49cb3e1 | 2011-06-29 14:35:14 +0200 | [diff] [blame] | 64 | |
| 65 | [[addreviewer.maxAllowed]]addreviewer.maxAllowed:: |
| 66 | + |
| 67 | The maximum number of reviewers a user can add at once by adding a |
| 68 | group as reviewer. |
| 69 | + |
| 70 | If set to 0, there is no limit for the number of reviewers that can |
| 71 | be added at once by adding a group as reviewer. |
| 72 | + |
| 73 | Default is 20. |
| 74 | |
Shawn O. Pearce | 8efb2a7 | 2009-08-18 19:45:33 -0700 | [diff] [blame] | 75 | [[auth]]Section auth |
| 76 | ~~~~~~~~~~~~~~~~~~~~ |
Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 77 | |
| 78 | See also link:config-sso.html[SSO configuration]. |
| 79 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 80 | [[auth.type]]auth.type:: |
Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 81 | + |
Shawn O. Pearce | 2920ef3 | 2009-08-03 08:03:34 -0700 | [diff] [blame] | 82 | Type of user authentication employed by Gerrit. The supported |
| 83 | values are: |
Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 84 | + |
| 85 | * `OpenID` |
| 86 | + |
| 87 | The default setting. Gerrit uses any valid OpenID |
| 88 | provider chosen by the end-user. For more information see |
Shawn O. Pearce | 2920ef3 | 2009-08-03 08:03:34 -0700 | [diff] [blame] | 89 | http://openid.net/[openid.net]. |
Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 90 | + |
James E. Blair | ca8bc3b | 2011-12-21 18:12:26 +0000 | [diff] [blame] | 91 | * `OpenID_SSO` |
| 92 | + |
| 93 | Supports OpenID from a single provider. There is no registration |
| 94 | link, and the "Sign In" link sends the user directly to the provider's |
| 95 | SSO entry point. |
| 96 | + |
Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 97 | * `HTTP` |
| 98 | + |
Shawn O. Pearce | 2920ef3 | 2009-08-03 08:03:34 -0700 | [diff] [blame] | 99 | Gerrit relies upon data presented in the HTTP request. This includes |
Edwin Kempin | f1acbb8 | 2011-09-15 12:49:42 +0200 | [diff] [blame] | 100 | HTTP basic authentication, or some types of commercial single-sign-on |
Shawn O. Pearce | 2920ef3 | 2009-08-03 08:03:34 -0700 | [diff] [blame] | 101 | solutions. With this setting enabled the authentication must |
| 102 | take place in the web server or servlet container, and not from |
| 103 | within Gerrit. |
| 104 | + |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 105 | * `HTTP_LDAP` |
| 106 | + |
| 107 | Exactly like `HTTP` (above), but additionally Gerrit pre-populates |
| 108 | a user's full name and email address based on information obtained |
| 109 | from the user's account object in LDAP. The user's group membership |
| 110 | is also pulled from LDAP, making any LDAP groups that a user is a |
| 111 | member of available as groups in Gerrit. |
| 112 | + |
Sasa Zivkov | eabc897 | 2010-10-04 15:47:08 +0200 | [diff] [blame] | 113 | * `CLIENT_SSL_CERT_LDAP` |
| 114 | + |
| 115 | This authentication type is actually kind of SSO. Gerrit will configure |
David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 116 | Jetty's SSL channel to request the client's SSL certificate. For this |
Sasa Zivkov | eabc897 | 2010-10-04 15:47:08 +0200 | [diff] [blame] | 117 | authentication to work a Gerrit administrator has to import the root |
| 118 | certificate of the trust chain used to issue the client's certificate |
| 119 | into the <review-site>/etc/keystore. |
| 120 | After the authentication is done Gerrit will obtain basic user |
| 121 | registration (name and email) from LDAP, and some group memberships. |
| 122 | Therefore, the "_LDAP" suffix in the name of this authentication type. |
| 123 | This authentication type can only be used under hosted daemon mode, and |
| 124 | the httpd.listenUrl must use https:// as the protocol. |
| 125 | + |
Shawn O. Pearce | f7e065e | 2009-09-26 20:01:10 -0700 | [diff] [blame] | 126 | * `LDAP` |
| 127 | + |
| 128 | Gerrit prompts the user to enter a username and a password, which |
| 129 | it then verifies by performing a simple bind against the configured |
| 130 | <<ldap.server,ldap.server>>. In this configuration the web server |
| 131 | is not involved in the user authentication process. |
| 132 | + |
Shawn O. Pearce | c892d34 | 2010-02-17 17:00:50 -0800 | [diff] [blame] | 133 | The actual username used in the LDAP simple bind request is the |
| 134 | account's full DN, which is discovered by first querying the |
| 135 | directory using either an anonymous request, or the configured |
| 136 | <<ldap.username>> identity. |
| 137 | |
| 138 | * `LDAP_BIND` |
| 139 | + |
| 140 | Gerrit prompts the user to enter a username and a password, which |
| 141 | it then verifies by performing a simple bind against the configured |
| 142 | <<ldap.server,ldap.server>>. In this configuration the web server |
| 143 | is not involved in the user authentication process. |
| 144 | + |
| 145 | Unlike LDAP above, the username used to perform the LDAP simple bind |
| 146 | request is the exact string supplied by in the dialog by the user. |
| 147 | The configured <<ldap.username>> identity is not used to obtain |
| 148 | account information. |
| 149 | + |
Shawn O. Pearce | 2920ef3 | 2009-08-03 08:03:34 -0700 | [diff] [blame] | 150 | * `DEVELOPMENT_BECOME_ANY_ACCOUNT` |
| 151 | + |
| 152 | *DO NOT USE*. Only for use in a development environment. |
| 153 | + |
| 154 | When this is the configured authentication method a hyperlink titled |
| 155 | `Become` appears in the top right corner of the page, taking the |
| 156 | user to a form where they can enter the username of any existing |
| 157 | user account, and immediately login as that account, without any |
| 158 | authentication taking place. This form of authentication is only |
| 159 | useful for the GWT hosted mode shell, where OpenID authentication |
| 160 | redirects might be risky to the developer's host computer, and HTTP |
| 161 | authentication is not possible. |
Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 162 | |
| 163 | + |
| 164 | By default, OpenID. |
| 165 | |
Shawn O. Pearce | 533cafc | 2010-05-11 16:05:27 -0700 | [diff] [blame] | 166 | [[auth.allowedOpenID]]auth.allowedOpenID:: |
| 167 | + |
| 168 | List of permitted OpenID providers. A user may only authenticate |
| 169 | with an OpenID that matches this list. Only used if `auth.type` |
David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 170 | is set to OpenID (the default). |
Shawn O. Pearce | 533cafc | 2010-05-11 16:05:27 -0700 | [diff] [blame] | 171 | + |
Magnus Bäck | e561183 | 2011-02-02 08:57:15 +0100 | [diff] [blame] | 172 | Patterns may be either a |
| 173 | link:http://download.oracle.com/javase/6/docs/api/java/util/regex/Pattern.html[standard |
| 174 | Java regular expression (java.util.regex)] (start with `^` and |
Shawn O. Pearce | 533cafc | 2010-05-11 16:05:27 -0700 | [diff] [blame] | 175 | end with `$`) or be a simple prefix (any other string). |
| 176 | + |
| 177 | By default, the list contains two values, `http://` and `https://`, |
| 178 | allowing users to authenticate with any OpenID provider. |
| 179 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 180 | [[auth.trustedOpenID]]auth.trustedOpenID:: |
Shawn O. Pearce | d7c026d | 2009-08-05 20:11:22 -0700 | [diff] [blame] | 181 | + |
David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 182 | List of trusted OpenID providers. Only used if `auth.type` is |
Shawn O. Pearce | d7c026d | 2009-08-05 20:11:22 -0700 | [diff] [blame] | 183 | set to OpenID (the default). |
| 184 | + |
| 185 | In order for a user to take advantage of permissions beyond those |
| 186 | granted to the `Anonymous Users` and `Registered Users` groups, |
| 187 | the user account must only have OpenIDs which match at least one |
| 188 | pattern from this list. |
| 189 | + |
Magnus Bäck | e561183 | 2011-02-02 08:57:15 +0100 | [diff] [blame] | 190 | Patterns may be either a |
| 191 | link:http://download.oracle.com/javase/6/docs/api/java/util/regex/Pattern.html[standard |
| 192 | Java regular expression (java.util.regex)] (start with `^` and |
Shawn O. Pearce | d7c026d | 2009-08-05 20:11:22 -0700 | [diff] [blame] | 193 | end with `$`) or be a simple prefix (any other string). |
| 194 | + |
| 195 | By default, the list contains two values, `http://` and `https://`, |
| 196 | allowing Gerrit to trust any OpenID it receives. |
| 197 | |
Shawn O. Pearce | 89030bc | 2010-04-24 17:25:29 -0700 | [diff] [blame] | 198 | [[auth.maxOpenIdSessionAge]]auth.maxOpenIdSessionAge:: |
| 199 | + |
| 200 | Time in seconds before an OpenID provider must force the user |
| 201 | to authenticate themselves again before authentication to this |
| 202 | Gerrit server. Currently this is only a polite request, and users |
| 203 | coming from providers that don't support the PAPE extension will |
| 204 | be accepted anyway. In the future it may be enforced, rejecting |
| 205 | users coming from providers that don't honor the max session age. |
| 206 | + |
| 207 | If set to 0, the provider will always force the user to authenticate |
| 208 | (e.g. supply their password). Values should use common unit suffixes |
| 209 | to express their setting: |
| 210 | + |
| 211 | * s, sec, second, seconds |
| 212 | * m, min, minute, minutes |
| 213 | * h, hr, hour, hours |
| 214 | * d, day, days |
| 215 | * w, week, weeks (`1 week` is treated as `7 days`) |
| 216 | * mon, month, months (`1 month` is treated as `30 days`) |
| 217 | * y, year, years (`1 year` is treated as `365 days`) |
| 218 | |
| 219 | + |
| 220 | Default is -1, permitting infinite time between authentications. |
| 221 | |
Shawn O. Pearce | 34f38cf | 2011-06-16 19:18:54 -0700 | [diff] [blame] | 222 | [[auth.maxRegisterEmailTokenAge]]auth.maxRegisterEmailTokenAge:: |
| 223 | + |
| 224 | Time in seconds before an email verification token sent to a user in |
| 225 | order to validate their email address expires. |
| 226 | + |
| 227 | * s, sec, second, seconds |
| 228 | * m, min, minute, minutes |
| 229 | * h, hr, hour, hours |
| 230 | * d, day, days |
| 231 | * w, week, weeks (`1 week` is treated as `7 days`) |
| 232 | * mon, month, months (`1 month` is treated as `30 days`) |
| 233 | * y, year, years (`1 year` is treated as `365 days`) |
| 234 | |
| 235 | + |
Shawn O. Pearce | d6bd00b | 2012-01-20 12:40:51 -0800 | [diff] [blame] | 236 | Default is 12 hours. |
Shawn O. Pearce | 34f38cf | 2011-06-16 19:18:54 -0700 | [diff] [blame] | 237 | |
James E. Blair | ca8bc3b | 2011-12-21 18:12:26 +0000 | [diff] [blame] | 238 | [[auth.openIdSsoUrl]]auth.openIdSsoUrl:: |
| 239 | + |
| 240 | The SSO entry point URL. Only used if `auth.type` was set to |
| 241 | OpenID_SSO. |
| 242 | + |
| 243 | The "Sign In" link will send users directly to this URL. |
| 244 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 245 | [[auth.httpHeader]]auth.httpHeader:: |
Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 246 | + |
| 247 | HTTP header to trust the username from, or unset to select HTTP basic |
David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 248 | or digest authentication. Only used if `auth.type` is set to HTTP. |
Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 249 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 250 | [[auth.logoutUrl]]auth.logoutUrl:: |
Shawn O. Pearce | 12b5d84 | 2009-08-15 15:11:10 -0700 | [diff] [blame] | 251 | + |
| 252 | URL to redirect a browser to after the end-user has clicked on the |
| 253 | "Sign Out" link in the upper right corner. Organizations using an |
| 254 | enterprise single-sign-on solution may want to redirect the browser |
| 255 | to the SSO product's sign-out page. |
| 256 | + |
| 257 | If not set, the redirect returns to the list of all open changes. |
| 258 | |
Shawn O. Pearce | c9d26b5 | 2009-12-16 08:05:27 -0800 | [diff] [blame] | 259 | [[auth.registerUrl]]auth.registerUrl:: |
| 260 | + |
| 261 | Target for the "Register" link in the upper right corner. Used only |
| 262 | when auth.type is `LDAP`. |
| 263 | + |
| 264 | If not set, no "Register" link is displayed. |
| 265 | |
Piotr Sikora | 7cec2f8 | 2011-02-26 12:57:30 +0000 | [diff] [blame] | 266 | [[auth.cookiePath]]auth.cookiePath:: |
| 267 | + |
| 268 | Sets "path" attribute of the authentication cookie. |
| 269 | + |
| 270 | If not set, HTTP request's path is used. |
| 271 | |
| 272 | [[auth.cookieSecure]]auth.cookieSecure:: |
| 273 | + |
| 274 | Sets "secure" flag of the authentication cookie. If true, cookies |
| 275 | will be transmitted only over HTTPS protocol. |
| 276 | + |
| 277 | By default, false. |
| 278 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 279 | [[auth.emailFormat]]auth.emailFormat:: |
Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 280 | + |
| 281 | Optional format string to construct user email addresses out of |
Shawn O. Pearce | f7e065e | 2009-09-26 20:01:10 -0700 | [diff] [blame] | 282 | user login names. Only used if auth.type is `HTTP`, `HTTP_LDAP` |
| 283 | or `LDAP`. |
Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 284 | + |
Shawn O. Pearce | 44221bf | 2011-06-27 10:37:30 -0700 | [diff] [blame] | 285 | This value can be set to a format string, where `{0}` is replaced |
Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 286 | with the login name. E.g. "\{0\}+gerrit@example.com" with a user |
| 287 | login name of "foo" will produce "foo+gerrit@example.com" during |
| 288 | the first time user "foo" registers. |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 289 | + |
Shawn O. Pearce | f7e065e | 2009-09-26 20:01:10 -0700 | [diff] [blame] | 290 | If the site is using `HTTP_LDAP` or `LDAP`, using this option is |
| 291 | discouraged. Setting `ldap.accountEmailAddress` and importing the |
| 292 | email address from the LDAP directory is generally preferred. |
Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 293 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 294 | [[auth.contributorAgreements]]auth.contributorAgreements:: |
Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 295 | + |
| 296 | Controls whether or not the contributor agreement features are |
| 297 | enabled for the Gerrit site. If enabled a user must complete a |
| 298 | contributor agreement before they can upload changes. |
| 299 | + |
| 300 | If enabled, the admin must also insert one or more rows into |
| 301 | `contributor_agreements` and create agreement files under |
| 302 | `'$site_path'/static`, so users can actually complete one or |
Grzegorz Kossakowski | 28e4e1b | 2009-09-23 11:33:34 -0700 | [diff] [blame] | 303 | more agreements. |
Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 304 | + |
| 305 | By default this is false (no agreements are used). |
| 306 | |
Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 307 | auth.allowGoogleAccountUpgrade:: |
| 308 | + |
Shawn O. Pearce | 48eea07 | 2009-08-31 10:53:12 -0700 | [diff] [blame] | 309 | Allows Google Account users to automatically update their Gerrit |
| 310 | account when/if their Google Account OpenID identity token changes. |
| 311 | Identity tokens can change if the server changes hostnames, or |
| 312 | for other reasons known only to Google. The upgrade path works |
| 313 | by matching users by email address if the identity is not present, |
| 314 | and then changing the identity. |
Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 315 | + |
Shawn O. Pearce | 48eea07 | 2009-08-31 10:53:12 -0700 | [diff] [blame] | 316 | This setting also permits old Gerrit 1.x users to seamlessly upgrade |
| 317 | from Google Accounts on Google App Engine to OpenID authentication. |
Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 318 | + |
Shawn O. Pearce | 48eea07 | 2009-08-31 10:53:12 -0700 | [diff] [blame] | 319 | Having this enabled incurs an extra database query when Google |
Shawn O. Pearce | e31d02c | 2009-12-08 12:21:37 -0800 | [diff] [blame] | 320 | Account users register with the Gerrit server. |
Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 321 | + |
| 322 | By default, unset/false. |
| 323 | |
Christian Halstrick | a3d88a5 | 2011-08-31 09:21:41 +0200 | [diff] [blame] | 324 | [[auth.trustContainerAuth]]auth.trustContainerAuth:: |
| 325 | + |
| 326 | If true then it is the responsibility of the container hosting |
| 327 | Gerrit to authenticate users. In this case Gerrit will blindly trust |
| 328 | the container. |
| 329 | + |
| 330 | This parameter only affects git over http traffic. If set to false |
| 331 | then Gerrit will do the authentication (using DIGEST authentication). |
| 332 | + |
| 333 | By default this is set to false. |
| 334 | |
Luca Milanesio | 4205884 | 2012-01-05 21:25:38 +0000 | [diff] [blame] | 335 | [[auth.gitBasicAuth]]auth.gitBasicAuth:: |
| 336 | + |
| 337 | If true then Git over HTTP and HTTP/S traffic is authenticated using |
| 338 | standard BasicAuth and credentials validated using the same auth |
| 339 | method configured for Gerrit Web UI. |
| 340 | + |
| 341 | This parameter only affects git over http traffic. If set to false |
| 342 | then Gerrit will authenticate through DIGEST authentication and |
| 343 | the randomly generated HTTP password in Gerrit DB. |
| 344 | + |
| 345 | By default this is set to false. |
| 346 | |
Edwin Kempin | 4b9e5e7 | 2011-09-22 15:06:14 +0200 | [diff] [blame] | 347 | [[auth.userNameToLowerCase]]auth.userNameToLowerCase:: |
| 348 | + |
| 349 | If set the username that is received to authenticate a git operation |
| 350 | is converted to lower case for looking up the user account in Gerrit. |
| 351 | + |
| 352 | By setting this parameter a case insensitive authentication for the |
| 353 | git operations can be achieved, if it is ensured that the usernames in |
| 354 | Gerrit (scheme `username`) are stored in lower case (e.g. if the |
| 355 | parameter link:#ldap.accountSshUserName[ldap.accountSshUserName] is |
| 356 | set to `${sAMAccountName.toLowerCase}`). It is important that for all |
| 357 | existing accounts this username is already in lower case. It is not |
| 358 | possible to convert the usernames of the existing accounts to lower |
| 359 | case because this would break the access to existing per-user |
| 360 | branches. |
| 361 | + |
| 362 | This parameter only affects git over http and git over SSH traffic. |
| 363 | + |
| 364 | By default this is set to false. |
| 365 | |
Shawn O. Pearce | 8efb2a7 | 2009-08-18 19:45:33 -0700 | [diff] [blame] | 366 | [[cache]]Section cache |
| 367 | ~~~~~~~~~~~~~~~~~~~~~~ |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 368 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 369 | [[cache.directory]]cache.directory:: |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 370 | + |
| 371 | Path to a local directory where Gerrit can write cached entities for |
Shawn O. Pearce | 4b21228 | 2009-08-05 19:45:56 -0700 | [diff] [blame] | 372 | future lookup. This local disk cache is used to retain potentially |
| 373 | expensive to compute information across restarts. If the location |
| 374 | does not exist, Gerrit will try to create it. |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 375 | + |
Shawn O. Pearce | 4b21228 | 2009-08-05 19:45:56 -0700 | [diff] [blame] | 376 | If not absolute, the path is resolved relative to `$site_path`. |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 377 | + |
Shawn O. Pearce | 4b21228 | 2009-08-05 19:45:56 -0700 | [diff] [blame] | 378 | Default is unset, no disk cache. |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 379 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 380 | [[cache.name.maxAge]]cache.<name>.maxAge:: |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 381 | + |
Shawn O. Pearce | 2e1cb2b | 2012-05-24 14:28:40 -0700 | [diff] [blame] | 382 | Maximum age to keep an entry in the cache. Entries are removed from |
| 383 | the cache and refreshed from source data every maxAge interval. |
Shawn O. Pearce | d9c403e | 2009-08-19 08:35:41 -0700 | [diff] [blame] | 384 | Values should use common unit suffixes to express their setting: |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 385 | + |
Shawn O. Pearce | d9c403e | 2009-08-19 08:35:41 -0700 | [diff] [blame] | 386 | * s, sec, second, seconds |
| 387 | * m, min, minute, minutes |
| 388 | * h, hr, hour, hours |
| 389 | * d, day, days |
| 390 | * w, week, weeks (`1 week` is treated as `7 days`) |
| 391 | * mon, month, months (`1 month` is treated as `30 days`) |
| 392 | * y, year, years (`1 year` is treated as `365 days`) |
| 393 | |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 394 | + |
Shawn O. Pearce | 3fdbf39 | 2009-09-04 18:08:26 -0700 | [diff] [blame] | 395 | If a unit suffix is not specified, `minutes` is assumed. If 0 is |
| 396 | supplied, the maximum age is infinite and items are never purged |
| 397 | except when the cache is full. |
Shawn O. Pearce | d9c403e | 2009-08-19 08:35:41 -0700 | [diff] [blame] | 398 | + |
Shawn O. Pearce | 2e1cb2b | 2012-05-24 14:28:40 -0700 | [diff] [blame] | 399 | Default is `0`, meaning store forever with no expire, except: |
Shawn O. Pearce | d9c403e | 2009-08-19 08:35:41 -0700 | [diff] [blame] | 400 | + |
Shawn O. Pearce | 05687e9 | 2011-04-04 17:29:03 -0400 | [diff] [blame] | 401 | * `"adv_bases"`: default is `10 minutes` |
Shawn O. Pearce | d9c403e | 2009-08-19 08:35:41 -0700 | [diff] [blame] | 402 | * `"ldap_groups"`: default is `1 hour` |
Shawn O. Pearce | d9c403e | 2009-08-19 08:35:41 -0700 | [diff] [blame] | 403 | * `"web_sessions"`: default is `12 hours` |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 404 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 405 | [[cache.name.memoryLimit]]cache.<name>.memoryLimit:: |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 406 | + |
Shawn O. Pearce | 2e1cb2b | 2012-05-24 14:28:40 -0700 | [diff] [blame] | 407 | The total cost of entries to retain in memory. The cost computation |
| 408 | varies by the cache. For most caches where the in-memory size of each |
| 409 | entry is relatively the same, memoryLimit is currently defined to be |
| 410 | the number of entries held by the cache (each entry costs 1). |
| 411 | + |
| 412 | For caches where the size of an entry can vary significantly between |
| 413 | individual entries (notably `"diff"`, `"diff_intraline"`), memoryLimit |
| 414 | is an approximation of the total number of bytes stored by the cache. |
| 415 | Larger entries that represent bigger patch sets or longer source files |
| 416 | will consume a bigger portion of the memoryLimit. For these caches the |
| 417 | memoryLimit should be set to roughly the amount of RAM (in bytes) the |
| 418 | administrator can dedicate to the cache. |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 419 | + |
Shawn O. Pearce | efaf979 | 2009-09-02 18:12:52 -0700 | [diff] [blame] | 420 | Default is 1024 for most caches, except: |
| 421 | + |
Shawn O. Pearce | 05687e9 | 2011-04-04 17:29:03 -0400 | [diff] [blame] | 422 | * `"adv_bases"`: default is `4096` |
Shawn O. Pearce | 2e1cb2b | 2012-05-24 14:28:40 -0700 | [diff] [blame] | 423 | * `"diff"`: default is `10m` (10 MiB of memory) |
| 424 | * `"diff_intraline"`: default is `10m` (10 MiB of memory) |
| 425 | * `"plugin_resources"`: default is 2m (2 MiB of memory) |
| 426 | |
| 427 | + |
| 428 | If set to 0 the cache is disabled. Entries are removed immediately |
| 429 | after being stored by the cache. This is primarily useful for testing. |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 430 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 431 | [[cache.name.diskLimit]]cache.<name>.diskLimit:: |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 432 | + |
Shawn O. Pearce | 2e1cb2b | 2012-05-24 14:28:40 -0700 | [diff] [blame] | 433 | Total size in bytes of the keys and values stored on disk. Caches that |
| 434 | have grown bigger than this size are scanned daily at 1 AM local |
| 435 | server time to trim the cache. Entries are removed in least recently |
| 436 | accessed order until the cache fits within this limit. Caches may |
| 437 | grow larger than this during the day, as the size check is only |
| 438 | performed once every 24 hours. |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 439 | + |
Shawn O. Pearce | 2e1cb2b | 2012-05-24 14:28:40 -0700 | [diff] [blame] | 440 | Default is 128 MiB per cache. |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 441 | + |
Shawn O. Pearce | 2e1cb2b | 2012-05-24 14:28:40 -0700 | [diff] [blame] | 442 | If 0, disk storage for the cache is disabled. |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 443 | |
Shawn O. Pearce | 8efb2a7 | 2009-08-18 19:45:33 -0700 | [diff] [blame] | 444 | [[cache_names]]Standard Caches |
Shawn O. Pearce | 4016a93 | 2009-05-28 15:12:40 -0700 | [diff] [blame] | 445 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 446 | |
Shawn O. Pearce | 4a45271 | 2009-05-28 20:12:33 -0700 | [diff] [blame] | 447 | cache `"accounts"`:: |
| 448 | + |
Shawn O. Pearce | 4dba988 | 2009-08-05 19:55:15 -0700 | [diff] [blame] | 449 | Cache entries contain important details of an active user, including |
| 450 | their display name, preferences, known email addresses, and group |
| 451 | memberships. Entry information is obtained from the following |
| 452 | database tables: |
| 453 | + |
| 454 | * `accounts` |
| 455 | + |
| 456 | * `account_group_members` |
| 457 | + |
| 458 | * `account_external_ids` |
| 459 | |
| 460 | + |
| 461 | If direct updates are made to any of these database tables, this |
| 462 | cache should be flushed. |
| 463 | |
| 464 | cache `"accounts_byemail"`:: |
| 465 | + |
| 466 | Caches account identities keyed by email address, which is scanned |
| 467 | from the `account_external_ids` database table. If updates are |
| 468 | made to this table, this cache should be flushed. |
Shawn O. Pearce | 4a45271 | 2009-05-28 20:12:33 -0700 | [diff] [blame] | 469 | |
Shawn O. Pearce | 05687e9 | 2011-04-04 17:29:03 -0400 | [diff] [blame] | 470 | cache `"adv_bases"`:: |
| 471 | + |
| 472 | Used only for push over smart HTTP when branch level access controls |
| 473 | are enabled. The cache entry contains all commits that are avaliable |
| 474 | for the client to use as potential delta bases. Push over smart HTTP |
| 475 | requires two HTTP requests, and this cache tries to carry state from |
| 476 | the first request into the second to ensure it can complete. |
| 477 | |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 478 | cache `"diff"`:: |
| 479 | + |
Shawn O. Pearce | efaf979 | 2009-09-02 18:12:52 -0700 | [diff] [blame] | 480 | Each item caches the differences between two commits, at both the |
| 481 | directory and file levels. Gerrit uses this cache to accelerate |
| 482 | the display of affected file names, as well as file contents. |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 483 | + |
Shawn O. Pearce | 2e1cb2b | 2012-05-24 14:28:40 -0700 | [diff] [blame] | 484 | Entries in this cache are relatively large, so memoryLimit is an |
| 485 | estimate in bytes of memory used. Administrators should try to target |
| 486 | cache.diff.memoryLimit to fit all changes users will view in a 1 or 2 |
| 487 | day span. |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 488 | |
Shawn O. Pearce | f0cfe53 | 2011-04-11 23:40:06 -0400 | [diff] [blame] | 489 | cache `"diff_intraline"`:: |
| 490 | + |
| 491 | Each item caches the intraline difference of one file, when compared |
| 492 | between two commits. Gerrit uses this cache to accelerate display of |
| 493 | intraline differences when viewing a file. |
| 494 | + |
Shawn O. Pearce | 2e1cb2b | 2012-05-24 14:28:40 -0700 | [diff] [blame] | 495 | Entries in this cache are relatively large, so memoryLimit is an |
| 496 | estimate in bytes of memory used. Administrators should try to target |
| 497 | cache.diff.memoryLimit to fit all files users will view in a 1 or 2 |
| 498 | day span. |
Shawn O. Pearce | f0cfe53 | 2011-04-11 23:40:06 -0400 | [diff] [blame] | 499 | |
Shawn O. Pearce | 2d65d29 | 2011-06-24 08:12:02 -0700 | [diff] [blame] | 500 | cache `"git_tags"`:: |
| 501 | + |
| 502 | If branch or reference level READ access controls are used, this |
| 503 | cache tracks which tags are reachable from the branch tips of a |
| 504 | repository. Gerrit uses this information to determine the set |
| 505 | of tags that a client may access, derived from which tags are |
| 506 | part of the history of a visible branch. |
| 507 | + |
| 508 | The cache is persisted to disk across server restarts as it can |
| 509 | be expensive to compute (60 or more seconds for a large history |
| 510 | like the Linux kernel repository). |
| 511 | |
Shawn O. Pearce | 4a45271 | 2009-05-28 20:12:33 -0700 | [diff] [blame] | 512 | cache `"groups"`:: |
| 513 | + |
Shawn O. Pearce | 4dba988 | 2009-08-05 19:55:15 -0700 | [diff] [blame] | 514 | Caches the basic group information from the `account_groups` table, |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 515 | including the group owner, name, and description. |
| 516 | + |
| 517 | Gerrit group membership obtained from the `account_group_members` |
| 518 | table is cached under the `"accounts"` cache, above. External group |
| 519 | membership obtained from LDAP is cached under `"ldap_groups"`. |
| 520 | |
Matt Fischer | 620255a | 2011-03-22 14:28:23 -0500 | [diff] [blame] | 521 | cache `"groups_byinclude"`:: |
| 522 | + |
| 523 | Caches group inclusions in other groups. If direct updates are made |
| 524 | to the `account_group_includes` table, this cache should be flushed. |
| 525 | |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 526 | cache `"ldap_groups"`:: |
| 527 | + |
| 528 | Caches the LDAP groups that a user belongs to, if LDAP has been |
| 529 | configured on this server. This cache should be configured with a |
| 530 | low maxAge setting, to ensure LDAP modifications are picked up in |
| 531 | a timely fashion. |
Shawn O. Pearce | 4a45271 | 2009-05-28 20:12:33 -0700 | [diff] [blame] | 532 | |
Shawn O. Pearce | 6d26f4a | 2009-08-24 15:43:52 -0700 | [diff] [blame] | 533 | cache `"ldap_usernames"`:: |
| 534 | + |
| 535 | Caches a mapping of LDAP username to Gerrit account identity. The |
| 536 | cache automatically updates when a user first creates their account |
| 537 | within Gerrit, so the cache expire time is largely irrelevant. |
| 538 | |
Shawn O. Pearce | 0c1abdb | 2011-06-24 11:01:25 -0700 | [diff] [blame] | 539 | cache `"permission_sort"`:: |
| 540 | + |
David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 541 | Caches the order in which access control sections must be applied to a |
Shawn O. Pearce | 0c1abdb | 2011-06-24 11:01:25 -0700 | [diff] [blame] | 542 | reference. Sorting the sections can be expensive when regular |
| 543 | expressions are used, so this cache remembers the ordering for |
| 544 | each branch. |
| 545 | |
Shawn O. Pearce | 2e1cb2b | 2012-05-24 14:28:40 -0700 | [diff] [blame] | 546 | cache `"plugin_resources"`:: |
| 547 | + |
| 548 | Caches formatted plugin resources, such as plugin documentation that |
| 549 | has been converted from Markdown to HTML. The memoryLimit refers to |
| 550 | the bytes of memory dedicated to storing the documentation. |
| 551 | |
Shawn O. Pearce | 4a45271 | 2009-05-28 20:12:33 -0700 | [diff] [blame] | 552 | cache `"projects"`:: |
| 553 | + |
| 554 | Caches the project description records, from the `projects` table |
| 555 | in the database. If a project record is updated or deleted, this |
| 556 | cache should be flushed. Newly inserted projects do not require |
| 557 | a cache flush, as they will be read upon first reference. |
| 558 | |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 559 | cache `"sshkeys"`:: |
| 560 | + |
| 561 | Caches unpacked versions of user SSH keys, so the internal SSH daemon |
| 562 | can match against them during authentication. The unit of storage |
| 563 | is per-user, so 1024 items translates to 1024 unique user accounts. |
| 564 | As each individual user account may configure multiple SSH keys, |
| 565 | the total number of keys may be larger than the item count. |
Shawn O. Pearce | 4a45271 | 2009-05-28 20:12:33 -0700 | [diff] [blame] | 566 | + |
| 567 | This cache is based off the `account_ssh_keys` table and the |
| 568 | `accounts.ssh_user_name` column in the database. If either is |
| 569 | modified directly, this cache should be flushed. |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 570 | |
Shawn O. Pearce | b09322b | 2009-08-15 17:49:00 -0700 | [diff] [blame] | 571 | cache `"web_sessions"`:: |
| 572 | + |
| 573 | Tracks the live user sessions coming in over HTTP. Flushing this |
| 574 | cache would cause all users to be signed out immediately, forcing |
Shawn O. Pearce | 727d80f | 2009-08-17 07:57:54 -0700 | [diff] [blame] | 575 | them to sign-in again. To avoid breaking active users, this cache |
| 576 | is not flushed automatically by `gerrit flush-caches --all`, but |
| 577 | instead must be explicitly requested. |
| 578 | + |
| 579 | If no disk cache is configured (or `cache.web_sessions.diskLimit` |
| 580 | is set to 0) a server restart will force all users to sign-out, |
| 581 | and need to sign-in again after the restart, as the cache was |
| 582 | unable to persist the session information. Enabling a disk cache |
| 583 | is strongly recommended. |
| 584 | + |
Shawn O. Pearce | 2e1cb2b | 2012-05-24 14:28:40 -0700 | [diff] [blame] | 585 | Session storage is relatively inexpensive. The average entry in |
| 586 | this cache is approximately 346 bytes. |
Shawn O. Pearce | b09322b | 2009-08-15 17:49:00 -0700 | [diff] [blame] | 587 | |
Shawn O. Pearce | 4016a93 | 2009-05-28 15:12:40 -0700 | [diff] [blame] | 588 | See also link:cmd-flush-caches.html[gerrit flush-caches]. |
| 589 | |
Shawn O. Pearce | 29de436 | 2010-03-03 17:51:26 -0800 | [diff] [blame] | 590 | [[cache_options]]Cache Options |
| 591 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
| 592 | |
Shawn O. Pearce | 617aa39 | 2010-11-15 14:03:28 -0800 | [diff] [blame] | 593 | cache.diff_intraline.maxIdleWorkers:: |
| 594 | + |
| 595 | Number of idle worker threads to maintain for the intraline difference |
| 596 | computations. There is no upper bound on how many concurrent requests |
| 597 | can occur at once, if additional threads are started to handle a peak |
David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 598 | load, only this many will remain idle afterwards. |
Shawn O. Pearce | 617aa39 | 2010-11-15 14:03:28 -0800 | [diff] [blame] | 599 | + |
| 600 | Default is 1.5x number of available CPUs. |
| 601 | |
| 602 | cache.diff_intraline.timeout:: |
| 603 | + |
| 604 | Maximum number of milliseconds to wait for intraline difference data |
| 605 | before giving up and disabling it for a particular file pair. This is |
| 606 | a work around for an infinite loop bug in the intraline difference |
| 607 | implementation. If computation takes longer than the timeout the |
| 608 | worker thread is terminated and no intraline difference is displayed. |
| 609 | + |
| 610 | Values should use common unit suffixes to express their setting: |
| 611 | + |
| 612 | * ms, milliseconds |
| 613 | * s, sec, second, seconds |
| 614 | * m, min, minute, minutes |
| 615 | * h, hr, hour, hours |
| 616 | |
| 617 | + |
| 618 | If a unit suffix is not specified, `milliseconds` is assumed. |
| 619 | + |
| 620 | Default is 5 seconds. |
| 621 | |
Shawn O. Pearce | 307dd4e | 2010-11-15 12:12:20 -0800 | [diff] [blame] | 622 | cache.diff_intraline.enabled:: |
Shawn O. Pearce | 29de436 | 2010-03-03 17:51:26 -0800 | [diff] [blame] | 623 | + |
| 624 | Boolean to enable or disable the computation of intraline differences |
Shawn O. Pearce | 307dd4e | 2010-11-15 12:12:20 -0800 | [diff] [blame] | 625 | when populating a diff cache entry. This flag is provided primarily |
| 626 | as a backdoor to disable the intraline difference feature if |
| 627 | necessary. To maintain backwards compatability with prior versions, |
| 628 | this setting will fallback to `cache.diff.intraline` if not set in the |
| 629 | configuration. |
Shawn O. Pearce | 29de436 | 2010-03-03 17:51:26 -0800 | [diff] [blame] | 630 | + |
| 631 | Default is true, enabled. |
| 632 | |
Shawn O. Pearce | b8e4e35 | 2011-05-19 18:09:01 -0700 | [diff] [blame] | 633 | cache.projects.checkFrequency:: |
| 634 | + |
| 635 | How often project configuration should be checked for update from Git. |
| 636 | Gerrit Code Review caches project access rules and configuration in |
| 637 | memory, checking the refs/meta/config branch every checkFrequency |
| 638 | minutes to see if a new revision should be loaded and used for future |
| 639 | access. Values can be specified using standard time unit abbreviations |
| 640 | ('ms', 'sec', 'min', etc.). |
| 641 | + |
| 642 | If set to 0, checks occur every time, which may slow down operations. |
| 643 | Administrators may force the cache to flush with |
| 644 | link:cmd-flush-caches.html[gerrit flush-caches]. |
| 645 | + |
| 646 | Default is 5 minutes. |
| 647 | |
carloseduardo.baldacin | 14246de | 2011-07-14 17:52:22 -0300 | [diff] [blame] | 648 | [[changeMerge]]Section changeMerge |
Remy Bohmer | 203eea3 | 2012-02-19 21:21:36 +0100 | [diff] [blame] | 649 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
carloseduardo.baldacin | 14246de | 2011-07-14 17:52:22 -0300 | [diff] [blame] | 650 | |
| 651 | Controls whether or not the mergeability test of changes is |
| 652 | enabled. If enabled, when the change page is loaded, the test is |
| 653 | triggered. The submit button will be enabled or disabled according to |
| 654 | the result. |
| 655 | |
| 656 | ---- |
| 657 | [changeMerge] |
| 658 | test = true |
| 659 | ---- |
| 660 | |
carloseduardo.baldacin | 14246de | 2011-07-14 17:52:22 -0300 | [diff] [blame] | 661 | By default this is false (test is not enabled). |
| 662 | |
Brad Larson | 991a31b | 2009-11-03 14:30:26 -0600 | [diff] [blame] | 663 | [[commentlink]]Section commentlink |
Remy Bohmer | 203eea3 | 2012-02-19 21:21:36 +0100 | [diff] [blame] | 664 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
Brad Larson | 991a31b | 2009-11-03 14:30:26 -0600 | [diff] [blame] | 665 | Comment links are find/replace strings applied to change descriptions, |
| 666 | patch comments, and in-line code comments to turn set strings into |
| 667 | hyperlinks. One common use is for linking to bug-tracking systems. |
| 668 | |
| 669 | In the following example configuration the 'changeid' comment link |
Shawn O. Pearce | da866ae | 2009-12-16 15:46:03 -0800 | [diff] [blame] | 670 | will match typical Gerrit Change-Id values and create a hyperlink |
| 671 | to changes which reference it. The second configuration 'bugzilla' |
| 672 | will hyperlink terms such as 'bug 42' to an external bug tracker, |
| 673 | supplying the argument record number '42' for display. The third |
David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 674 | configuration 'tracker' uses raw HTML to more precisely control |
Shawn O. Pearce | da866ae | 2009-12-16 15:46:03 -0800 | [diff] [blame] | 675 | how the replacement is displayed to the user. |
Brad Larson | 991a31b | 2009-11-03 14:30:26 -0600 | [diff] [blame] | 676 | |
Shawn O. Pearce | da866ae | 2009-12-16 15:46:03 -0800 | [diff] [blame] | 677 | ---- |
| 678 | [commentlink "changeid"] |
| 679 | match = (I[0-9a-f]{8,40}) |
| 680 | link = "#q,$1,n,z" |
Brad Larson | 991a31b | 2009-11-03 14:30:26 -0600 | [diff] [blame] | 681 | |
Shawn O. Pearce | da866ae | 2009-12-16 15:46:03 -0800 | [diff] [blame] | 682 | [commentlink "bugzilla"] |
Shawn O. Pearce | c99630a | 2010-02-21 19:11:56 -0800 | [diff] [blame] | 683 | match = "(bug\\s+#?)(\\d+)" |
Shawn O. Pearce | da866ae | 2009-12-16 15:46:03 -0800 | [diff] [blame] | 684 | link = http://bugs.example.com/show_bug.cgi?id=$2 |
Brad Larson | 991a31b | 2009-11-03 14:30:26 -0600 | [diff] [blame] | 685 | |
Shawn O. Pearce | da866ae | 2009-12-16 15:46:03 -0800 | [diff] [blame] | 686 | [commentlink "tracker"] |
| 687 | match = ([Bb]ug:\\s+)(\\d+) |
| 688 | html = $1<a href=\"http://trak.example.com/$2\">$2</a> |
| 689 | ---- |
| 690 | |
| 691 | [[commentlink.name.match]]commentlink.<name>.match:: |
Brad Larson | 991a31b | 2009-11-03 14:30:26 -0600 | [diff] [blame] | 692 | + |
Shawn O. Pearce | da866ae | 2009-12-16 15:46:03 -0800 | [diff] [blame] | 693 | A JavaScript regular expression to match positions to be replaced |
| 694 | with a hyperlink. Subexpressions of the matched string can be |
| 695 | stored using groups and accessed with `$'n'` syntax, where 'n' |
| 696 | is the group number, starting from 1. |
Brad Larson | 991a31b | 2009-11-03 14:30:26 -0600 | [diff] [blame] | 697 | + |
Shawn O. Pearce | c99630a | 2010-02-21 19:11:56 -0800 | [diff] [blame] | 698 | The configuration file parser eats one level of backslashes, so the |
| 699 | character class `\s` requires `\\s` in the configuration file. The |
| 700 | parser also terminates the line at the first `#`, so a match |
| 701 | expression containing # must be wrapped in double quotes. |
Shawn O. Pearce | da866ae | 2009-12-16 15:46:03 -0800 | [diff] [blame] | 702 | + |
Shawn O. Pearce | 665beaa | 2010-02-21 22:41:03 -0800 | [diff] [blame] | 703 | To match case insensitive strings, a character class with both the |
| 704 | upper and lower case character for each position must be used. For |
| 705 | example, to match the string `bug` in a case insensitive way the match |
| 706 | pattern `[bB][uU][gG]` needs to be used. |
| 707 | + |
Shawn O. Pearce | da866ae | 2009-12-16 15:46:03 -0800 | [diff] [blame] | 708 | A common pattern to match is `bug\\s+(\\d+)`. |
Brad Larson | 991a31b | 2009-11-03 14:30:26 -0600 | [diff] [blame] | 709 | |
Shawn O. Pearce | da866ae | 2009-12-16 15:46:03 -0800 | [diff] [blame] | 710 | [[commentlink.name.link]]commentlink.<name>.link:: |
Brad Larson | 991a31b | 2009-11-03 14:30:26 -0600 | [diff] [blame] | 711 | + |
Shawn O. Pearce | da866ae | 2009-12-16 15:46:03 -0800 | [diff] [blame] | 712 | The URL to direct the user to whenever the regular expression is |
| 713 | matched. Groups in the match expression may be accessed as `$'n'`. |
| 714 | + |
| 715 | The link property is used only when the html property is not present. |
| 716 | |
| 717 | [[commentlink.name.html]]commentlink.<name>.html:: |
| 718 | + |
| 719 | HTML to replace the entire matched string with. If present, |
| 720 | this property overrides the link property above. Groups in the |
| 721 | match expression may be accessed as `$'n'`. |
| 722 | + |
| 723 | The configuration file eats double quotes, so escaping them as |
| 724 | `\"` is necessary to protect them from the parser. |
Brad Larson | 991a31b | 2009-11-03 14:30:26 -0600 | [diff] [blame] | 725 | |
| 726 | |
Shawn O. Pearce | 8efb2a7 | 2009-08-18 19:45:33 -0700 | [diff] [blame] | 727 | [[contactstore]]Section contactstore |
| 728 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
Shawn O. Pearce | 6854bdc | 2009-06-01 08:14:15 -0700 | [diff] [blame] | 729 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 730 | [[contactstore.url]]contactstore.url:: |
Shawn O. Pearce | 6854bdc | 2009-06-01 08:14:15 -0700 | [diff] [blame] | 731 | + |
| 732 | URL of the web based contact store Gerrit will send any offline |
| 733 | contact information to when it collects the data from users as part |
| 734 | of a contributor agreement. |
| 735 | + |
| 736 | See link:config-contact.html[Contact Information]. |
| 737 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 738 | [[contactstore.appsec]]contactstore.appsec:: |
Shawn O. Pearce | 6854bdc | 2009-06-01 08:14:15 -0700 | [diff] [blame] | 739 | + |
| 740 | Shared secret of the web based contact store. |
| 741 | |
Shawn O. Pearce | e24c71fb | 2009-12-07 20:32:40 -0800 | [diff] [blame] | 742 | |
| 743 | [[container]]Section container |
| 744 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 745 | |
| 746 | These settings are applied only if Gerrit is started as the container |
| 747 | process through Gerrit's 'gerrit.sh' rc.d compatible wrapper script. |
| 748 | |
| 749 | [[container.heapLimit]]container.heapLimit:: |
| 750 | + |
| 751 | Maximum heap size of the Java process running Gerrit, in bytes. |
| 752 | This property is translated into the '-Xmx' flag for the JVM. |
| 753 | + |
| 754 | Default is platform and JVM specific. |
| 755 | + |
| 756 | Common unit suffixes of 'k', 'm', or 'g' are supported. |
| 757 | |
| 758 | [[container.javaHome]]container.javaHome:: |
| 759 | + |
| 760 | Path of the JRE/JDK installation to run Gerrit with. If not set, the |
| 761 | Gerrit startup script will attempt to search your system and guess |
| 762 | a suitable JRE. Overrides the environment variable 'JAVA_HOME'. |
| 763 | |
| 764 | [[container.javaOptions]]container.javaOptions:: |
| 765 | + |
| 766 | Additional options to pass along to the Java runtime. If multiple |
| 767 | values are configured, they are passed in order on the command line, |
| 768 | separated by spaces. These options are appended onto 'JAVA_OPTIONS'. |
| 769 | |
Fredrik Luthander | b8f7d6d | 2010-05-18 21:11:22 +0200 | [diff] [blame] | 770 | [[container.slave]]container.slave:: |
| 771 | + |
| 772 | Used on Gerrit slave installations. If set to true the Gerrit JVM is |
| 773 | called with the '--slave' switch, enabling slave mode. If no value is |
| 774 | set (or any other value), gerrit defaults to master mode. |
| 775 | |
Shawn O. Pearce | e24c71fb | 2009-12-07 20:32:40 -0800 | [diff] [blame] | 776 | [[container.user]]container.user:: |
| 777 | + |
| 778 | Login name (or UID) of the operating system user the Gerrit JVM |
| 779 | will execute as. If not set, defaults to the user who launched |
| 780 | the 'gerrit.sh' wrapper script. |
| 781 | |
| 782 | [[container.war]]container.war:: |
| 783 | + |
| 784 | Path of the JAR file to start daemon execution with. This should |
| 785 | be the path of the local 'gerrit.war' archive. Overrides the |
| 786 | environment variable 'GERRIT_WAR'. |
| 787 | + |
| 788 | If not set, defaults to '$site_path/bin/gerrit.war', or to |
| 789 | '$HOME/gerrit.war'. |
| 790 | |
| 791 | |
Shawn O. Pearce | 8efb2a7 | 2009-08-18 19:45:33 -0700 | [diff] [blame] | 792 | [[core]]Section core |
| 793 | ~~~~~~~~~~~~~~~~~~~~ |
Shawn O. Pearce | 6854bdc | 2009-06-01 08:14:15 -0700 | [diff] [blame] | 794 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 795 | [[core.packedGitWindowSize]]core.packedGitWindowSize:: |
Shawn O. Pearce | 6854bdc | 2009-06-01 08:14:15 -0700 | [diff] [blame] | 796 | + |
| 797 | Number of bytes of a pack file to load into memory in a single |
| 798 | read operation. This is the "page size" of the JGit buffer cache, |
| 799 | used for all pack access operations. All disk IO occurs as single |
| 800 | window reads. Setting this too large may cause the process to load |
| 801 | more data than is required; setting this too small may increase |
| 802 | the frequency of `read()` system calls. |
| 803 | + |
| 804 | Default on JGit is 8 KiB on all platforms. |
| 805 | + |
| 806 | Common unit suffixes of 'k', 'm', or 'g' are supported. |
| 807 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 808 | [[core.packedGitLimit]]core.packedGitLimit:: |
Shawn O. Pearce | 6854bdc | 2009-06-01 08:14:15 -0700 | [diff] [blame] | 809 | + |
| 810 | Maximum number of bytes to load and cache in memory from pack files. |
| 811 | If JGit needs to access more than this many bytes it will unload less |
| 812 | frequently used windows to reclaim memory space within the process. |
| 813 | As this buffer must be shared with the rest of the JVM heap, it |
| 814 | should be a fraction of the total memory available. |
| 815 | + |
| 816 | Default on JGit is 10 MiB on all platforms. |
| 817 | + |
| 818 | Common unit suffixes of 'k', 'm', or 'g' are supported. |
| 819 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 820 | [[core.deltaBaseCaseLimit]]core.deltaBaseCacheLimit:: |
Shawn O. Pearce | 6854bdc | 2009-06-01 08:14:15 -0700 | [diff] [blame] | 821 | + |
| 822 | Maximum number of bytes to reserve for caching base objects |
| 823 | that multiple deltafied objects reference. By storing the entire |
| 824 | decompressed base object in a cache Git is able to avoid unpacking |
| 825 | and decompressing frequently used base objects multiple times. |
| 826 | + |
| 827 | Default on JGit is 10 MiB on all platforms. You probably do not |
| 828 | need to adjust this value. |
| 829 | + |
| 830 | Common unit suffixes of 'k', 'm', or 'g' are supported. |
| 831 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 832 | [[core.packedGitOpenFiles]]core.packedGitOpenFiles:: |
Shawn O. Pearce | 6854bdc | 2009-06-01 08:14:15 -0700 | [diff] [blame] | 833 | + |
| 834 | Maximum number of pack files to have open at once. A pack file |
| 835 | must be opened in order for any of its data to be available in |
| 836 | a cached window. |
| 837 | + |
| 838 | If you increase this to a larger setting you may need to also adjust |
| 839 | the ulimit on file descriptors for the host JVM, as Gerrit needs |
| 840 | additional file descriptors available for network sockets and other |
| 841 | repository data manipulation. |
| 842 | + |
| 843 | Default on JGit is 128 file descriptors on all platforms. |
| 844 | |
Shawn O. Pearce | 329fe79 | 2010-09-03 15:44:23 -0700 | [diff] [blame] | 845 | [[core.streamFileThreshold]]core.streamFileThreshold:: |
| 846 | + |
| 847 | Largest object size, in bytes, that JGit will allocate as a |
| 848 | contiguous byte array. Any file revision larger than this threshold |
| 849 | will have to be streamed, typically requiring the use of temporary |
| 850 | files under '$GIT_DIR/objects' to implement psuedo-random access |
| 851 | during delta decompression. |
| 852 | + |
| 853 | Servers with very high traffic should set this to be larger than |
| 854 | the size of their common big files. For example a server managing |
| 855 | the Android platform typically has to deal with ~10-12 MiB XML |
| 856 | files, so `15 m` would be a reasonable setting in that environment. |
| 857 | Setting this too high may cause the JVM to run out of heap space |
| 858 | when handling very big binary files, such as device firmware or |
| 859 | CD-ROM ISO images. |
| 860 | + |
Shawn O. Pearce | e3febd9 | 2010-10-13 21:17:53 -0700 | [diff] [blame] | 861 | Default is 50 MiB on all platforms. Prior to Gerrit 2.1.6, |
Shawn O. Pearce | 329fe79 | 2010-09-03 15:44:23 -0700 | [diff] [blame] | 862 | this value was effectively 2047 MiB. |
| 863 | + |
| 864 | Common unit suffixes of 'k', 'm', or 'g' are supported. |
| 865 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 866 | [[core.packedGitMmap]]core.packedGitMmap:: |
Shawn O. Pearce | 6854bdc | 2009-06-01 08:14:15 -0700 | [diff] [blame] | 867 | + |
| 868 | When true, JGit will use `mmap()` rather than `malloc()+read()` |
| 869 | to load data from pack files. The use of mmap can be problematic |
| 870 | on some JVMs as the garbage collector must deduce that a memory |
| 871 | mapped segment is no longer in use before a call to `munmap()` |
| 872 | can be made by the JVM native code. |
| 873 | + |
| 874 | In server applications (such as Gerrit) that need to access many |
| 875 | pack files, setting this to true risks artifically running out |
| 876 | of virtual address space, as the garbage collector cannot reclaim |
| 877 | unused mapped spaces fast enough. |
| 878 | + |
| 879 | Default on JGit is false. Although potentially slower, it yields |
| 880 | much more predictable behavior. |
| 881 | |
Sasa Zivkov | f69aeb1 | 2012-06-11 14:05:14 +0200 | [diff] [blame] | 882 | [[core.asyncLoggingBufferSize]]core.asyncLoggingBufferSize:: |
| 883 | + |
| 884 | Size of the buffer to store logging events for asynchronous logging. |
| 885 | Putting a larger value can protect threads from stalling when the |
| 886 | AsyncAppender threads are not fast enough to consume the logging events |
| 887 | from the buffer. It also protects from loosing log entries in this case. |
| 888 | + |
| 889 | Default is 64 entries. |
| 890 | |
Shawn O. Pearce | fb5548e | 2009-11-11 07:39:21 -0800 | [diff] [blame] | 891 | [[database]]Section database |
| 892 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 893 | |
| 894 | The database section configures where Gerrit stores its metadata |
| 895 | records about user accounts and change reviews. |
| 896 | |
Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 897 | ---- |
| 898 | [database] |
Shawn O. Pearce | 1be3906 | 2009-12-19 14:11:52 -0800 | [diff] [blame] | 899 | type = POSTGRESQL |
Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 900 | hostname = localhost |
| 901 | database = reviewdb |
| 902 | username = gerrit2 |
| 903 | password = s3kr3t |
| 904 | ---- |
Shawn O. Pearce | fb5548e | 2009-11-11 07:39:21 -0800 | [diff] [blame] | 905 | |
| 906 | [[database.type]]database.type:: |
| 907 | + |
| 908 | Type of database server to connect to. If set this value will be |
| 909 | used to automatically create correct database.driver and database.url |
| 910 | values to open the connection. |
| 911 | + |
Shawn O. Pearce | 1be3906 | 2009-12-19 14:11:52 -0800 | [diff] [blame] | 912 | * `POSTGRESQL` |
Shawn O. Pearce | fb5548e | 2009-11-11 07:39:21 -0800 | [diff] [blame] | 913 | + |
| 914 | Connect to a PostgreSQL database server. |
| 915 | + |
| 916 | * `H2` |
| 917 | + |
Shawn O. Pearce | 1be3906 | 2009-12-19 14:11:52 -0800 | [diff] [blame] | 918 | Connect to a local embedded H2 database. |
Shawn O. Pearce | fb5548e | 2009-11-11 07:39:21 -0800 | [diff] [blame] | 919 | + |
Shawn O. Pearce | 1be3906 | 2009-12-19 14:11:52 -0800 | [diff] [blame] | 920 | * `MYSQL` |
Shawn O. Pearce | fb5548e | 2009-11-11 07:39:21 -0800 | [diff] [blame] | 921 | + |
| 922 | Connect to a MySQL database server. |
Shawn O. Pearce | 1be3906 | 2009-12-19 14:11:52 -0800 | [diff] [blame] | 923 | + |
| 924 | * `JDBC` |
| 925 | + |
| 926 | Connect using a JDBC driver class name and URL. |
Shawn O. Pearce | fb5548e | 2009-11-11 07:39:21 -0800 | [diff] [blame] | 927 | |
| 928 | + |
| 929 | If not specified, database.driver and database.url are used as-is, |
| 930 | and if they are also not specified, defaults to H2. |
| 931 | |
| 932 | [[database.hostname]]database.hostname:: |
| 933 | + |
| 934 | Hostname of the database server. Defaults to 'localhost'. |
| 935 | |
| 936 | [[database.port]]database.port:: |
| 937 | + |
| 938 | Port number of the database server. Defaults to the default port |
| 939 | of the server named by database.type. |
| 940 | |
| 941 | [[database.database]]database.database:: |
| 942 | + |
Shawn O. Pearce | 1be3906 | 2009-12-19 14:11:52 -0800 | [diff] [blame] | 943 | For POSTGRESQL or MYSQL, the name of the database on the server. |
Shawn O. Pearce | fb5548e | 2009-11-11 07:39:21 -0800 | [diff] [blame] | 944 | + |
| 945 | For H2, this is the path to the database, and if not absolute is |
Shawn O. Pearce | 1be3906 | 2009-12-19 14:11:52 -0800 | [diff] [blame] | 946 | relative to `'$site_path'`. |
Shawn O. Pearce | fb5548e | 2009-11-11 07:39:21 -0800 | [diff] [blame] | 947 | |
| 948 | [[database.username]]database.username:: |
| 949 | + |
| 950 | Username to connect to the database server as. |
| 951 | |
| 952 | [[database.password]]database.password:: |
| 953 | + |
| 954 | Password to authenticate to the database server with. |
| 955 | |
| 956 | [[database.driver]]database.driver:: |
| 957 | + |
Shawn O. Pearce | 1be3906 | 2009-12-19 14:11:52 -0800 | [diff] [blame] | 958 | Name of the JDBC driver class to connect to the database with. |
| 959 | Setting this usually isn't necessary as it can be derived from |
| 960 | database.type or database.url for any supported database. |
Shawn O. Pearce | fb5548e | 2009-11-11 07:39:21 -0800 | [diff] [blame] | 961 | |
| 962 | [[database.url]]database.url:: |
| 963 | + |
Shawn O. Pearce | 1be3906 | 2009-12-19 14:11:52 -0800 | [diff] [blame] | 964 | 'jdbc:' URL for the database. Setting this variable usually |
| 965 | isn't necessary as it can be constructed from the all of the |
| 966 | above properties. |
Shawn O. Pearce | fb5548e | 2009-11-11 07:39:21 -0800 | [diff] [blame] | 967 | |
Shawn O. Pearce | 07f35177d | 2010-02-23 09:47:10 -0800 | [diff] [blame] | 968 | [[database.poolLimit]]database.poolLimit:: |
| 969 | + |
| 970 | Maximum number of open database connections. If the server needs |
| 971 | more than this number, request processing threads will wait up |
| 972 | to <<database.poolMaxWait, poolMaxWait>> seconds for a |
| 973 | connection to be released before they abort with an exception. |
| 974 | This limit must be several units higher than the total number of |
| 975 | httpd and sshd threads as some request processing code paths may |
| 976 | need multiple connections. |
| 977 | + |
| 978 | Default is 8. |
| 979 | |
Shawn O. Pearce | f458bf6 | 2010-02-25 09:03:03 -0800 | [diff] [blame] | 980 | [[database.poolMinIdle]]database.poolMinIdle:: |
Shawn O. Pearce | 07f35177d | 2010-02-23 09:47:10 -0800 | [diff] [blame] | 981 | + |
| 982 | Minimum number of connections to keep idle in the pool. |
| 983 | Default is 4. |
| 984 | |
Shawn O. Pearce | f458bf6 | 2010-02-25 09:03:03 -0800 | [diff] [blame] | 985 | [[database.poolMaxIdle]]database.poolMaxIdle:: |
Shawn O. Pearce | 07f35177d | 2010-02-23 09:47:10 -0800 | [diff] [blame] | 986 | + |
| 987 | Maximum number of connections to keep idle in the pool. If there |
| 988 | are more idle connections, connections will be closed instead of |
| 989 | being returned back to the pool. |
| 990 | Default is 4. |
| 991 | |
| 992 | [[database.poolMaxWait]]database.poolMaxWait:: |
| 993 | + |
| 994 | Maximum amount of time a request processing thread will wait to |
| 995 | acquire a database connection from the pool. If no connection is |
| 996 | released within this time period, the processing thread will abort |
| 997 | its current operations and return an error to the client. |
| 998 | Values should use common unit suffixes to express their setting: |
| 999 | + |
| 1000 | * ms, milliseconds |
| 1001 | * s, sec, second, seconds |
| 1002 | * m, min, minute, minutes |
| 1003 | * h, hr, hour, hours |
| 1004 | |
| 1005 | + |
| 1006 | If a unit suffix is not specified, `milliseconds` is assumed. |
| 1007 | + |
| 1008 | Default is `30 seconds`. |
| 1009 | |
monica.dionisio | 3f63044 | 2010-06-29 15:42:57 -0300 | [diff] [blame] | 1010 | [[download]]Section download |
Nasser Grainawi | b9a5037 | 2010-08-10 07:57:47 -0600 | [diff] [blame] | 1011 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
monica.dionisio | 3f63044 | 2010-06-29 15:42:57 -0300 | [diff] [blame] | 1012 | |
| 1013 | ---- |
| 1014 | [download] |
| 1015 | scheme = ssh |
| 1016 | scheme = http |
| 1017 | scheme = anon_http |
| 1018 | scheme = anon_git |
| 1019 | scheme = repo_download |
| 1020 | ---- |
| 1021 | |
| 1022 | The download section configures the allowed download methods. |
| 1023 | |
| 1024 | [[download.scheme]]download.scheme:: |
| 1025 | + |
| 1026 | Schemes that should be used to download changes. |
| 1027 | + |
| 1028 | Multiple schemes are supported: |
| 1029 | + |
| 1030 | * `http` |
| 1031 | + |
Shawn O. Pearce | 5c46a07 | 2010-08-23 08:33:32 -0700 | [diff] [blame] | 1032 | Authenticated HTTP download is allowed. |
monica.dionisio | 3f63044 | 2010-06-29 15:42:57 -0300 | [diff] [blame] | 1033 | + |
| 1034 | * `ssh` |
| 1035 | + |
Shawn O. Pearce | 5c46a07 | 2010-08-23 08:33:32 -0700 | [diff] [blame] | 1036 | Authenticated SSH download is allowed. |
monica.dionisio | 3f63044 | 2010-06-29 15:42:57 -0300 | [diff] [blame] | 1037 | + |
| 1038 | * `anon_http` |
| 1039 | + |
| 1040 | Anonymous HTTP download is allowed. |
| 1041 | + |
| 1042 | * `anon_git` |
| 1043 | + |
Shawn O. Pearce | 5c46a07 | 2010-08-23 08:33:32 -0700 | [diff] [blame] | 1044 | Anonymous Git download is allowed. This is not default, it is also |
| 1045 | necessary to set <<gerrit.canonicalGitUrl,gerrit.canonicalGitUrl>> |
| 1046 | variable. |
monica.dionisio | 3f63044 | 2010-06-29 15:42:57 -0300 | [diff] [blame] | 1047 | + |
| 1048 | * `repo_download` |
| 1049 | + |
Shawn O. Pearce | 5c46a07 | 2010-08-23 08:33:32 -0700 | [diff] [blame] | 1050 | Gerrit advertises patch set downloads with the `repo download` |
| 1051 | command, assuming that all projects managed by this instance are |
| 1052 | generally worked on with the repo multi-repository tool. This is |
| 1053 | not default, as not all instances will deploy repo. |
monica.dionisio | 3f63044 | 2010-06-29 15:42:57 -0300 | [diff] [blame] | 1054 | |
| 1055 | + |
Shawn O. Pearce | 5c46a07 | 2010-08-23 08:33:32 -0700 | [diff] [blame] | 1056 | If download.scheme is not specified, SSH, HTTP and Anonymous HTTP |
| 1057 | downloads are allowed. |
Shawn O. Pearce | fb5548e | 2009-11-11 07:39:21 -0800 | [diff] [blame] | 1058 | |
Shawn O. Pearce | 8efb2a7 | 2009-08-18 19:45:33 -0700 | [diff] [blame] | 1059 | [[gerrit]]Section gerrit |
| 1060 | ~~~~~~~~~~~~~~~~~~~~~~~~ |
Shawn O. Pearce | eb7f8ce | 2009-06-01 09:57:15 -0700 | [diff] [blame] | 1061 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1062 | [[gerrit.basePath]]gerrit.basePath:: |
Shawn O. Pearce | 9743d0b | 2009-06-01 10:10:06 -0700 | [diff] [blame] | 1063 | + |
| 1064 | Local filesystem directory holding all Git repositories that |
| 1065 | Gerrit knows about and can process changes for. A project |
| 1066 | entity in Gerrit maps to a local Git repository by creating |
Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1067 | the path string `"${basePath}/${project_name}.git"`. |
Shawn O. Pearce | 9743d0b | 2009-06-01 10:10:06 -0700 | [diff] [blame] | 1068 | + |
| 1069 | If relative, the path is resolved relative to `'$site_path'`. |
| 1070 | |
Shawn O. Pearce | 897d921 | 2011-06-16 16:59:59 -0700 | [diff] [blame] | 1071 | [[gerrit.allProjects]]gerrit.allProjects:: |
| 1072 | + |
| 1073 | Name of the permissions-only project defining global server |
| 1074 | access controls and settings. These are inherited into every |
| 1075 | other project managed by the running server. The name is |
| 1076 | relative to `gerrit.basePath`. |
| 1077 | + |
| 1078 | Defaults to `All-Projects` if not set. |
| 1079 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1080 | [[gerrit.canonicalWebUrl]]gerrit.canonicalWebUrl:: |
Shawn O. Pearce | eb7f8ce | 2009-06-01 09:57:15 -0700 | [diff] [blame] | 1081 | + |
| 1082 | The default URL for Gerrit to be accessed through. |
| 1083 | + |
| 1084 | Typically this would be set to "http://review.example.com/" or |
| 1085 | "http://example.com/gerrit/" so Gerrit can output links that point |
| 1086 | back to itself. |
| 1087 | + |
| 1088 | Setting this is highly recommended, as its necessary for the upload |
| 1089 | code invoked by "git push" or "repo upload" to output hyperlinks |
| 1090 | to the newly uploaded changes. |
| 1091 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1092 | [[gerrit.canonicalGitUrl]]gerrit.canonicalGitUrl:: |
Shawn O. Pearce | eb7f8ce | 2009-06-01 09:57:15 -0700 | [diff] [blame] | 1093 | + |
| 1094 | Optional base URL for repositories available over the anonymous git |
| 1095 | protocol. For example, set this to `git://mirror.example.com/base/` |
| 1096 | to have Gerrit display patch set download URLs in the UI. Gerrit |
| 1097 | automatically appends the project name onto the end of the URL. |
| 1098 | + |
| 1099 | By default unset, as the git daemon must be configured externally |
| 1100 | by the system administrator, and might not even be running on the |
| 1101 | same host as Gerrit. |
| 1102 | |
Shawn O. Pearce | 5d6de52 | 2011-10-07 18:00:16 -0700 | [diff] [blame] | 1103 | [[gerrit.gitHttpUrl]]gerrit.gitHttpUrl:: |
| 1104 | + |
| 1105 | Optional base URL for repositories available over the HTTP |
| 1106 | protocol. For example, set this to `http://mirror.example.com/base/` |
| 1107 | to have Gerrit display URLs from this server, rather than itself. |
| 1108 | + |
| 1109 | By default unset, as the HTTP daemon must be configured externally |
| 1110 | by the system administrator, and might not even be running on the |
| 1111 | same host as Gerrit. |
| 1112 | |
Shawn O. Pearce | 8efb2a7 | 2009-08-18 19:45:33 -0700 | [diff] [blame] | 1113 | [[gitweb]]Section gitweb |
| 1114 | ~~~~~~~~~~~~~~~~~~~~~~~~ |
Shawn O. Pearce | d7ba11f | 2009-06-01 09:35:41 -0700 | [diff] [blame] | 1115 | |
Shawn O. Pearce | 618dae2 | 2010-03-12 19:07:43 -0800 | [diff] [blame] | 1116 | Gerrit can forward requests to either an internally managed gitweb |
| 1117 | (which allows Gerrit to enforce some access controls), or to an |
| 1118 | externally managed gitweb (where the web server manages access). |
Shawn O. Pearce | d7ba11f | 2009-06-01 09:35:41 -0700 | [diff] [blame] | 1119 | See also link:config-gitweb.html[Gitweb Integration]. |
| 1120 | |
Shawn O. Pearce | 618dae2 | 2010-03-12 19:07:43 -0800 | [diff] [blame] | 1121 | [[gitweb.cgi]]gitweb.cgi:: |
| 1122 | + |
| 1123 | Path to the locally installed `gitweb.cgi` executable. This CGI will |
| 1124 | be called by Gerrit Code Review when the URL `/gitweb` is accessed. |
| 1125 | Project level access controls are enforced prior to calling the CGI. |
| 1126 | + |
| 1127 | Defaults to `/usr/lib/cgi-bin/gitweb.cgi` if gitweb.url is not set. |
| 1128 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1129 | [[gitweb.url]]gitweb.url:: |
Shawn O. Pearce | d7ba11f | 2009-06-01 09:35:41 -0700 | [diff] [blame] | 1130 | + |
| 1131 | Optional URL of an affiliated gitweb service. Defines the |
| 1132 | web location where a `gitweb.cgi` is installed to browse |
Shawn O. Pearce | 9743d0b | 2009-06-01 10:10:06 -0700 | [diff] [blame] | 1133 | gerrit.basePath and the repositories it contains. |
Shawn O. Pearce | d7ba11f | 2009-06-01 09:35:41 -0700 | [diff] [blame] | 1134 | + |
| 1135 | Gerrit appends any necessary query arguments onto the end of this URL. |
| 1136 | For example, "?p=$project.git;h=$commit". |
| 1137 | |
Shane Mc Cormack | 27868a4 | 2009-12-28 04:49:39 +0000 | [diff] [blame] | 1138 | [[gitweb.type]]gitweb.type:: |
| 1139 | + |
| 1140 | Optional type of affiliated gitweb service. This allows using |
Shawn O. Pearce | 2b11da0 | 2011-09-06 16:18:12 -0700 | [diff] [blame] | 1141 | alternatives to gitweb, such as cgit. If set to disabled there |
| 1142 | is no gitweb hyperlinking support. |
Shane Mc Cormack | 27868a4 | 2009-12-28 04:49:39 +0000 | [diff] [blame] | 1143 | + |
Shawn O. Pearce | 2b11da0 | 2011-09-06 16:18:12 -0700 | [diff] [blame] | 1144 | Valid values are `gitweb`, `cgit`, `disabled` or `custom`. |
Shane Mc Cormack | 27868a4 | 2009-12-28 04:49:39 +0000 | [diff] [blame] | 1145 | |
Edwin Kempin | d86909c | 2012-03-26 10:36:29 +0200 | [diff] [blame] | 1146 | [[gitweb.revision]]gitweb.revision:: |
Shane Mc Cormack | 27868a4 | 2009-12-28 04:49:39 +0000 | [diff] [blame] | 1147 | + |
| 1148 | Optional pattern to use for constructing the gitweb URL when pointing |
| 1149 | at a specific commit when `custom` is used above. |
| 1150 | + |
Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1151 | Valid replacements are `${project}` for the project name in Gerrit |
| 1152 | and `${commit}` for the SHA1 hash for the commit. |
Shane Mc Cormack | 27868a4 | 2009-12-28 04:49:39 +0000 | [diff] [blame] | 1153 | |
Edwin Kempin | d86909c | 2012-03-26 10:36:29 +0200 | [diff] [blame] | 1154 | [[gitweb.project]]gitweb.project:: |
Shane Mc Cormack | 27868a4 | 2009-12-28 04:49:39 +0000 | [diff] [blame] | 1155 | + |
| 1156 | Optional pattern to use for constructing the gitweb URL when pointing |
| 1157 | at a specific project when `custom` is used above. |
| 1158 | + |
Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1159 | Valid replacements are `${project}` for the project name in Gerrit. |
Shane Mc Cormack | 27868a4 | 2009-12-28 04:49:39 +0000 | [diff] [blame] | 1160 | |
Edwin Kempin | d86909c | 2012-03-26 10:36:29 +0200 | [diff] [blame] | 1161 | [[gitweb.branch]]gitweb.branch:: |
Shane Mc Cormack | 27868a4 | 2009-12-28 04:49:39 +0000 | [diff] [blame] | 1162 | + |
| 1163 | Optional pattern to use for constructing the gitweb URL when pointing |
| 1164 | at a specific branch when `custom` is used above. |
| 1165 | + |
Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1166 | Valid replacements are `${project}` for the project name in Gerrit |
| 1167 | and `${branch}` for the name of the branch. |
Shane Mc Cormack | 27868a4 | 2009-12-28 04:49:39 +0000 | [diff] [blame] | 1168 | |
Edwin Kempin | 6401156 | 2012-03-26 10:50:12 +0200 | [diff] [blame] | 1169 | [[gitweb.filehistory]]gitweb.filehistory:: |
| 1170 | + |
| 1171 | Optional pattern to use for constructing the gitweb URL when pointing |
| 1172 | at the history of a file in a specific branch when `custom` is used |
| 1173 | above. |
| 1174 | + |
| 1175 | Valid replacements are `${project}` for the project name in Gerrit, |
| 1176 | `${file}` for the file name and `${branch}` for the name of the |
| 1177 | branch. |
| 1178 | |
Gustaf Lundh | a07d2e7 | 2011-10-27 15:26:35 -0700 | [diff] [blame] | 1179 | [[gitweb.linkname]]gitweb.linkname:: |
| 1180 | + |
| 1181 | Optional setting for modifying the link name presented to the user |
| 1182 | in the Gerrit web-UI. |
| 1183 | + |
| 1184 | Default linkname for custom type is "gitweb". |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1185 | |
Adrian Goerler | f200707 | 2011-11-10 08:39:55 +0100 | [diff] [blame] | 1186 | [[gitweb.pathSeparator]]gitweb.pathSeparator:: |
| 1187 | + |
| 1188 | Optional character to substitute the standard path separator (slash) in |
| 1189 | project names and branch names. |
| 1190 | + |
| 1191 | By default, Gerrit will use hexadecimal encoding for slashes in project and |
| 1192 | branch names. Some web servers, such as Tomcat, reject this hexadecimal |
| 1193 | encoding in the URL. |
| 1194 | + |
| 1195 | Some alternative gitweb services, such as link:http://gitblit.com[Gitblit], |
| 1196 | allow using an alternative path separator character. In Gitblit, this can be |
| 1197 | configured through the property link:http://gitblit.com/properties.html[web.forwardSlashCharacter]. |
| 1198 | In Gerrit, the alternative path separator can be configured correspondingly |
| 1199 | using the property 'gitweb.pathSeparator'. |
| 1200 | + |
| 1201 | Valid values are the characters '*', '(' and ')'. |
| 1202 | |
Shane Mc Cormack | 6c2b677 | 2010-01-12 21:56:44 +0000 | [diff] [blame] | 1203 | [[hooks]]Section hooks |
Remy Bohmer | 203eea3 | 2012-02-19 21:21:36 +0100 | [diff] [blame] | 1204 | ~~~~~~~~~~~~~~~~~~~~~~ |
Shane Mc Cormack | 6c2b677 | 2010-01-12 21:56:44 +0000 | [diff] [blame] | 1205 | |
| 1206 | See also link:config-hooks.html[Hooks]. |
| 1207 | |
| 1208 | [[hooks.path]]hooks.path:: |
| 1209 | + |
| 1210 | Optional path to hooks, if not specified then `'$site_path'/hooks` will be used. |
| 1211 | |
| 1212 | [[hooks.patchsetCreatedHook]]hooks.patchsetCreatedHook:: |
| 1213 | + |
| 1214 | Optional filename for the patchset created hook, if not specified then |
| 1215 | `patchset-created` will be used. |
| 1216 | |
David Pursehouse | d556c19 | 2012-06-12 18:34:37 +0900 | [diff] [blame] | 1217 | [[hooks.draftPublishedHook]]hooks.draftPublishedHook:: |
| 1218 | + |
| 1219 | Optional filename for the draft published hook, if not specified then |
| 1220 | `draft-published` will be used. |
| 1221 | |
Shane Mc Cormack | 6c2b677 | 2010-01-12 21:56:44 +0000 | [diff] [blame] | 1222 | [[hooks.commentAddedHook]]hooks.commentAddedHook:: |
| 1223 | + |
| 1224 | Optional filename for the comment added hook, if not specified then |
| 1225 | `comment-added` will be used. |
| 1226 | |
| 1227 | [[hooks.changeMergedHook]]hooks.changeMergedHook:: |
| 1228 | + |
| 1229 | Optional filename for the change merged hook, if not specified then |
| 1230 | `change-merged` will be used. |
| 1231 | |
| 1232 | [[hooks.changeAbandonedHook]]hooks.changeAbandonedHook:: |
| 1233 | + |
| 1234 | Optional filename for the change abandoned hook, if not specified then |
| 1235 | `change-abandoned` will be used. |
| 1236 | |
David Pursehouse | a93c930 | 2012-06-15 16:29:26 +0900 | [diff] [blame] | 1237 | [[hooks.changeRestoredHook]]hooks.changeRestoredHook:: |
| 1238 | + |
| 1239 | Optional filename for the change restored hook, if not specified then |
| 1240 | `change-restored` will be used. |
| 1241 | |
| 1242 | [[hooks.refUpdatedHook]]hooks.refUpdatedHook:: |
| 1243 | + |
| 1244 | Optional filename for the ref updated hook, if not specified then |
| 1245 | `ref-updated` will be used. |
| 1246 | |
| 1247 | [[hooks.claSignedHook]]hooks.claSignedHook:: |
| 1248 | + |
| 1249 | Optional filename for the CLA signed hook, if not specified then |
| 1250 | `cla-signed` will be used. |
| 1251 | |
Shawn O. Pearce | 309d8d3 | 2009-11-17 16:03:16 -0800 | [diff] [blame] | 1252 | [[http]]Section http |
| 1253 | ~~~~~~~~~~~~~~~~~~~~ |
| 1254 | |
| 1255 | [[http.proxy]]http.proxy:: |
Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 1256 | + |
| 1257 | URL of the proxy server when making outgoing HTTP |
| 1258 | connections for OpenID login transactions. Syntax |
| 1259 | should be `http://`'hostname'`:`'port'. |
Shawn O. Pearce | 309d8d3 | 2009-11-17 16:03:16 -0800 | [diff] [blame] | 1260 | |
| 1261 | [[http.proxyUsername]]http.proxyUsername:: |
Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 1262 | + |
| 1263 | Optional username to authenticate to the HTTP proxy with. |
| 1264 | This property is honored only if the username does not |
| 1265 | appear in the http.proxy property above. |
Shawn O. Pearce | 309d8d3 | 2009-11-17 16:03:16 -0800 | [diff] [blame] | 1266 | |
| 1267 | [[http.proxyPassword]]http.proxyPassword:: |
Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 1268 | + |
| 1269 | Optional password to authenticate to the HTTP proxy with. |
| 1270 | This property is honored only if the password does not |
| 1271 | appear in the http.proxy property above. |
Shawn O. Pearce | 309d8d3 | 2009-11-17 16:03:16 -0800 | [diff] [blame] | 1272 | |
| 1273 | |
| 1274 | [[httpd]]Section httpd |
| 1275 | ~~~~~~~~~~~~~~~~~~~~~~ |
Shawn O. Pearce | fa2486a | 2009-11-11 14:51:30 -0800 | [diff] [blame] | 1276 | |
| 1277 | The httpd section configures the embedded servlet container. |
| 1278 | |
| 1279 | [[httpd.listenUrl]]httpd.listenUrl:: |
| 1280 | + |
| 1281 | Specifies the URLs the internal HTTP daemon should listen for |
Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1282 | connections on. The special hostname '*' may be used to listen |
Shawn O. Pearce | fa2486a | 2009-11-11 14:51:30 -0800 | [diff] [blame] | 1283 | on all local addresses. A context path may optionally be included, |
| 1284 | placing Gerrit Code Review's web address within a subdirectory of |
| 1285 | the server. |
| 1286 | + |
| 1287 | Multiple protocol schemes are supported: |
| 1288 | + |
| 1289 | * `http://`'hostname'`:`'port' |
| 1290 | + |
| 1291 | Plain-text HTTP protocol. If port is not supplied, defaults to 80, |
| 1292 | the standard HTTP port. |
| 1293 | + |
| 1294 | * `https://`'hostname'`:`'port' |
| 1295 | + |
| 1296 | SSL encrypted HTTP protocol. If port is not supplied, defaults to |
| 1297 | 443, the standard HTTPS port. |
| 1298 | + |
| 1299 | Externally facing production sites are encouraged to use a reverse |
| 1300 | proxy configuration and `proxy-https://` (below), rather than using |
| 1301 | the embedded servlet container to implement the SSL processing. |
| 1302 | The proxy server with SSL support is probably easier to configure, |
| 1303 | provides more configuration options to control cipher usage, and |
| 1304 | is likely using natively compiled encryption algorithms, resulting |
| 1305 | in higher throughput. |
| 1306 | + |
| 1307 | * `proxy-http://`'hostname'`:`'port' |
| 1308 | + |
| 1309 | Plain-text HTTP relayed from a reverse proxy. If port is not |
| 1310 | supplied, defaults to 8080. |
| 1311 | + |
| 1312 | Like http, but additional header parsing features are |
| 1313 | enabled to honor X-Forwarded-For, X-Forwarded-Host and |
| 1314 | X-Forwarded-Server. These headers are typically set by Apache's |
| 1315 | link:http://httpd.apache.org/docs/2.2/mod/mod_proxy.html#x-headers[mod_proxy]. |
| 1316 | + |
| 1317 | * `proxy-https://`'hostname'`:`'port' |
| 1318 | + |
| 1319 | Plain text HTTP relayed from a reverse proxy that has already |
| 1320 | handled the SSL encryption/decryption. If port is not supplied, |
| 1321 | defaults to 8080. |
| 1322 | + |
| 1323 | Behaves exactly like proxy-http, but also sets the scheme to assume |
| 1324 | 'https://' is the proper URL back to the server. |
| 1325 | |
| 1326 | + |
| 1327 | If multiple values are supplied, the daemon will listen on all |
| 1328 | of them. |
| 1329 | + |
| 1330 | By default, http://*:8080. |
| 1331 | |
| 1332 | [[httpd.reuseAddress]]httpd.reuseAddress:: |
| 1333 | + |
| 1334 | If true, permits the daemon to bind to the port even if the port |
| 1335 | is already in use. If false, the daemon ensures the port is not |
| 1336 | in use before starting. Busy sites may need to set this to true |
| 1337 | to permit fast restarts. |
| 1338 | + |
| 1339 | By default, true. |
| 1340 | |
| 1341 | [[httpd.requestHeaderSize]]httpd.requestHeaderSize:: |
| 1342 | + |
| 1343 | Size, in bytes, of the buffer used to parse the HTTP headers of an |
| 1344 | incoming HTTP request. The entire request headers, including any |
| 1345 | cookies sent by the browser, must fit within this buffer, otherwise |
| 1346 | the server aborts with the response '413 Request Entity Too Large'. |
| 1347 | + |
| 1348 | One buffer of this size is allocated per active connection. |
| 1349 | Allocating a buffer that is too large wastes memory that cannot be |
| 1350 | reclaimed, allocating a buffer that is too small may cause unexpected |
| 1351 | errors caused by very long Referer URLs or large cookie values. |
| 1352 | + |
| 1353 | By default, 16384 (16 K), which is sufficient for most OpenID and |
| 1354 | other web-based single-sign-on integrations. |
| 1355 | |
| 1356 | [[httpd.sslKeyStore]]httpd.sslKeyStore:: |
| 1357 | + |
| 1358 | Path of the Java keystore containing the server's SSL certificate |
| 1359 | and private key. This keystore is required for `https://` in URL. |
| 1360 | + |
| 1361 | To create a self-signed certificate for simple internal usage: |
| 1362 | + |
Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 1363 | ---- |
| 1364 | keytool -keystore keystore -alias jetty -genkey -keyalg RSA |
| 1365 | chmod 600 keystore |
| 1366 | ---- |
Shawn O. Pearce | fa2486a | 2009-11-11 14:51:30 -0800 | [diff] [blame] | 1367 | + |
| 1368 | If not absolute, the path is resolved relative to `$site_path`. |
| 1369 | + |
Shawn O. Pearce | c5fed82 | 2009-11-17 16:10:10 -0800 | [diff] [blame] | 1370 | By default, `$site_path/etc/keystore`. |
Shawn O. Pearce | fa2486a | 2009-11-11 14:51:30 -0800 | [diff] [blame] | 1371 | |
| 1372 | [[httpd.sslKeyPassword]]httpd.sslKeyPassword:: |
| 1373 | + |
| 1374 | Password used to decrypt the private portion of the sslKeyStore. |
David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 1375 | Java keystores require a password, even if the administrator |
Shawn O. Pearce | fa2486a | 2009-11-11 14:51:30 -0800 | [diff] [blame] | 1376 | doesn't want to enable one. |
| 1377 | + |
| 1378 | If set to the empty string the embedded server will prompt for the |
| 1379 | password during startup. |
| 1380 | + |
| 1381 | By default, `gerrit`. |
| 1382 | |
Shawn O. Pearce | 1766f50 | 2010-01-15 10:49:46 -0800 | [diff] [blame] | 1383 | [[httpd.requestLog]]httpd.requestLog:: |
| 1384 | + |
| 1385 | Enable (or disable) the `'$site_path'/logs/httpd_log` request log. |
| 1386 | If enabled, an NCSA combined log format request log file is written |
| 1387 | out by the internal HTTP daemon. |
| 1388 | + |
| 1389 | By default, true if httpd.listenUrl uses http:// or https://, |
| 1390 | and false if httpd.listenUrl uses proxy-http:// or proxy-https://. |
| 1391 | |
Shawn O. Pearce | fa2486a | 2009-11-11 14:51:30 -0800 | [diff] [blame] | 1392 | [[httpd.acceptorThreads]]httpd.acceptorThreads:: |
| 1393 | + |
| 1394 | Number of worker threads dedicated to accepting new incoming TCP |
David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 1395 | connections and allocating them connection-specific resources. |
Shawn O. Pearce | fa2486a | 2009-11-11 14:51:30 -0800 | [diff] [blame] | 1396 | + |
| 1397 | By default, 2, which should be suitable for most high-traffic sites. |
| 1398 | |
| 1399 | [[httpd.minThreads]]httpd.minThreads:: |
| 1400 | + |
| 1401 | Minimum number of spare threads to keep in the worker thread pool. |
| 1402 | This number must be at least 1 larger than httpd.acceptorThreads |
| 1403 | multipled by the number of httpd.listenUrls configured. |
| 1404 | + |
| 1405 | By default, 5, suitable for most lower-volume traffic sites. |
| 1406 | |
| 1407 | [[httpd.maxThreads]]httpd.maxThreads:: |
| 1408 | + |
| 1409 | Maximum number of threads to permit in the worker thread pool. |
| 1410 | + |
| 1411 | By default 25, suitable for most lower-volume traffic sites. |
| 1412 | |
| 1413 | [[httpd.maxQueued]]httpd.maxQueued:: |
| 1414 | + |
| 1415 | Maximum number of client connections which can enter the worker |
| 1416 | thread pool waiting for a worker thread to become available. |
| 1417 | 0 disables the queue and permits infinite number of connections. |
| 1418 | + |
| 1419 | By default 50. |
| 1420 | |
Shawn O. Pearce | e5452b7 | 2010-01-15 14:32:50 -0800 | [diff] [blame] | 1421 | [[httpd.maxWait]]httpd.maxWait:: |
| 1422 | + |
David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 1423 | Maximum amount of time a client will wait for an available |
Shawn O. Pearce | e5452b7 | 2010-01-15 14:32:50 -0800 | [diff] [blame] | 1424 | thread to handle a project clone, fetch or push request over the |
| 1425 | smart HTTP transport. |
| 1426 | + |
| 1427 | Values should use common unit suffixes to express their setting: |
| 1428 | + |
| 1429 | * s, sec, second, seconds |
| 1430 | * m, min, minute, minutes |
| 1431 | * h, hr, hour, hours |
| 1432 | * d, day, days |
| 1433 | * w, week, weeks (`1 week` is treated as `7 days`) |
| 1434 | * mon, month, months (`1 month` is treated as `30 days`) |
| 1435 | * y, year, years (`1 year` is treated as `365 days`) |
| 1436 | |
| 1437 | + |
| 1438 | If a unit suffix is not specified, `minutes` is assumed. If 0 |
| 1439 | is supplied, the maximum age is infinite and connections will not |
| 1440 | abort until the client disconnects. |
| 1441 | + |
| 1442 | By default, 5 minutes. |
| 1443 | |
Shawn O. Pearce | fa2486a | 2009-11-11 14:51:30 -0800 | [diff] [blame] | 1444 | |
Shawn O. Pearce | 8efb2a7 | 2009-08-18 19:45:33 -0700 | [diff] [blame] | 1445 | [[ldap]]Section ldap |
| 1446 | ~~~~~~~~~~~~~~~~~~~~ |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1447 | |
David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 1448 | LDAP integration is only enabled if `auth.type` is set to |
Sasa Zivkov | eabc897 | 2010-10-04 15:47:08 +0200 | [diff] [blame] | 1449 | `HTTP_LDAP`, `LDAP` or `CLIENT_SSL_CERT_LDAP`. See above for a |
| 1450 | detailed description of the auth.type settings and their |
| 1451 | implications. |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1452 | |
Shawn O. Pearce | 02c2e80 | 2009-10-29 14:46:03 -0700 | [diff] [blame] | 1453 | An example LDAP configuration follows, and then discussion of |
| 1454 | the parameters introduced here. Suitable defaults for most |
| 1455 | parameters are automatically guessed based on the type of server |
| 1456 | detected during startup. The guessed defaults support both |
| 1457 | link:http://www.ietf.org/rfc/rfc2307.txt[RFC 2307] and Active |
| 1458 | Directory. |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1459 | |
Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 1460 | ---- |
| 1461 | [ldap] |
| 1462 | server = ldap://ldap.example.com |
| 1463 | |
| 1464 | accountBase = ou=people,dc=example,dc=com |
| 1465 | accountPattern = (&(objectClass=person)(uid=${username})) |
| 1466 | accountFullName = displayName |
| 1467 | accountEmailAddress = mail |
| 1468 | |
| 1469 | groupBase = ou=groups,dc=example,dc=com |
| 1470 | groupMemberPattern = (&(objectClass=group)(member=${dn})) |
| 1471 | ---- |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1472 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1473 | [[ldap.server]]ldap.server:: |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1474 | + |
| 1475 | URL of the organization's LDAP server to query for user information |
| 1476 | and group membership from. Must be of the form `ldap://host` or |
| 1477 | `ldaps://host` to bind with either a plaintext or SSL connection. |
Shawn O. Pearce | f7e065e | 2009-09-26 20:01:10 -0700 | [diff] [blame] | 1478 | + |
| 1479 | If auth.type is `LDAP` this setting should use `ldaps://` to |
| 1480 | ensure the end user's plaintext password is transmitted only over |
| 1481 | an encrypted connection. |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1482 | |
Shawn O. Pearce | 02c2e80 | 2009-10-29 14:46:03 -0700 | [diff] [blame] | 1483 | [[ldap.sslVerify]]ldap.sslVerify:: |
| 1484 | + |
| 1485 | If false and ldap.server is an `ldaps://` style URL, Gerrit |
| 1486 | will not verify the server certificate when it connects to |
| 1487 | perform a query. |
| 1488 | + |
| 1489 | By default, true, requiring the certificate to be verified. |
| 1490 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1491 | [[ldap.username]]ldap.username:: |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1492 | + |
| 1493 | _(Optional)_ Username to bind to the LDAP server with. If not set, |
| 1494 | an anonymous connection to the LDAP server is attempted. |
| 1495 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1496 | [[ldap.password]]ldap.password:: |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1497 | + |
| 1498 | _(Optional)_ Password for the user identified by `ldap.username`. |
| 1499 | If not set, an anonymous (or passwordless) connection to the LDAP |
| 1500 | server is attempted. |
| 1501 | |
Ben Wu | 0410a15 | 2010-06-04 16:17:24 +0800 | [diff] [blame] | 1502 | [[ldap.referral]]ldap.referral:: |
| 1503 | + |
| 1504 | _(Optional)_ How an LDAP referral should be handled if it is |
| 1505 | encountered during directory traversal. Set to `follow` to |
James Y Knight | 1244ed0 | 2011-01-04 02:40:32 -0500 | [diff] [blame] | 1506 | automatically follow any referrals, or `ignore` to ignore the |
| 1507 | referrals. |
Ben Wu | 0410a15 | 2010-06-04 16:17:24 +0800 | [diff] [blame] | 1508 | + |
| 1509 | By default, `ignore`. |
| 1510 | |
Sasa Zivkov | 100bd4b | 2011-11-07 14:58:46 +0100 | [diff] [blame] | 1511 | [[ldap.readTimeout]]ldap.readTimeout:: |
| 1512 | + |
| 1513 | _(Optional)_ The read timeout for an LDAP operation. The value is |
| 1514 | in the usual time-unit format like "1 s", "100 ms", etc... |
| 1515 | A timeout can be used to avoid blocking all of the SSH command start |
David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 1516 | threads in case the LDAP server becomes slow. |
Sasa Zivkov | 100bd4b | 2011-11-07 14:58:46 +0100 | [diff] [blame] | 1517 | + |
| 1518 | By default there is no timeout and Gerrit will wait for the LDAP |
| 1519 | server to respond until the TCP connection times out. |
| 1520 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1521 | [[ldap.accountBase]]ldap.accountBase:: |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1522 | + |
| 1523 | Root of the tree containing all user accounts. This is typically |
| 1524 | of the form `ou=people,dc=example,dc=com`. |
| 1525 | |
Shawn O. Pearce | 304ccdb | 2009-08-25 12:25:27 -0700 | [diff] [blame] | 1526 | [[ldap.accountScope]]ldap.accountScope:: |
| 1527 | + |
| 1528 | Scope of the search performed for accounts. Must be one of: |
| 1529 | + |
| 1530 | * `one`: Search only one level below accountBase, but not recursive |
| 1531 | * `sub` or `subtree`: Search recursively below accountBase |
| 1532 | * `base` or `object`: Search exactly accountBase; probably not desired |
| 1533 | |
| 1534 | + |
| 1535 | Default is `subtree` as many directories have several levels. |
| 1536 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1537 | [[ldap.accountPattern]]ldap.accountPattern:: |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1538 | + |
| 1539 | Query pattern to use when searching for a user account. This may be |
| 1540 | any valid LDAP query expression, including the standard `(&...)` and |
| 1541 | `(|...)` operators. If auth.type is `HTTP_LDAP` then the variable |
Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1542 | `${username}` is replaced with a parameter set to the username |
Shawn O. Pearce | f7e065e | 2009-09-26 20:01:10 -0700 | [diff] [blame] | 1543 | that was supplied by the HTTP server. If auth.type is `LDAP` then |
Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1544 | the variable `${username}` is replaced by the string entered by |
Shawn O. Pearce | f7e065e | 2009-09-26 20:01:10 -0700 | [diff] [blame] | 1545 | the end user. |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1546 | + |
| 1547 | This pattern is used to search the objects contained directly under |
| 1548 | the `ldap.accountBase` tree. A typical setting for this parameter |
Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1549 | is `(uid=${username})` or `(cn=${username})`, but the proper |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1550 | setting depends on the LDAP schema used by the directory server. |
| 1551 | + |
Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1552 | Default is `(uid=${username})` for RFC 2307 servers, |
Shawn O. Pearce | 02c2e80 | 2009-10-29 14:46:03 -0700 | [diff] [blame] | 1553 | and `(&(objectClass=user)(sAMAccountName=${username}))` |
| 1554 | for Active Directory. |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1555 | |
Shawn O. Pearce | 37dc1f8 | 2009-08-19 09:49:07 -0700 | [diff] [blame] | 1556 | [[ldap.accountFullName]]ldap.accountFullName:: |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1557 | + |
| 1558 | _(Optional)_ Name of an attribute on the user account object which |
| 1559 | contains the initial value for the user's full name field in Gerrit. |
| 1560 | Typically this is the `displayName` property in LDAP, but could |
| 1561 | also be `legalName` or `cn`. |
| 1562 | + |
David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 1563 | Attribute values may be concatenated with literal strings. For |
| 1564 | example to join given name and surname together, use the pattern |
Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1565 | `${givenName} ${SN}`. |
Shawn O. Pearce | b86ae00 | 2009-09-26 16:54:05 -0700 | [diff] [blame] | 1566 | + |
Shawn O. Pearce | 3ca1dcf | 2009-08-20 08:56:23 -0700 | [diff] [blame] | 1567 | If set, users will be unable to modify their full name field, as |
| 1568 | Gerrit will populate it only from the LDAP data. |
| 1569 | + |
Shawn O. Pearce | 02c2e80 | 2009-10-29 14:46:03 -0700 | [diff] [blame] | 1570 | Default is `displayName` for RFC 2307 servers, |
| 1571 | and `${givenName} ${sn}` for Active Directory. |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1572 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1573 | [[ldap.accountEmailAddress]]ldap.accountEmailAddress:: |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1574 | + |
| 1575 | _(Optional)_ Name of an attribute on the user account object which |
| 1576 | contains the user's Internet email address, as defined by this |
| 1577 | LDAP server. |
| 1578 | + |
Shawn O. Pearce | b86ae00 | 2009-09-26 16:54:05 -0700 | [diff] [blame] | 1579 | Attribute values may be concatenated with literal strings, |
| 1580 | for example to set the email address to the lowercase form |
| 1581 | of sAMAccountName followed by a constant domain name, use |
Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1582 | `${sAMAccountName.toLowerCase}@example.com`. |
Shawn O. Pearce | b86ae00 | 2009-09-26 16:54:05 -0700 | [diff] [blame] | 1583 | + |
Shawn O. Pearce | 3ca1dcf | 2009-08-20 08:56:23 -0700 | [diff] [blame] | 1584 | If set, the preferred email address will be prefilled from LDAP, |
David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 1585 | but users may still be able to register additional email addresses, |
Shawn O. Pearce | 3ca1dcf | 2009-08-20 08:56:23 -0700 | [diff] [blame] | 1586 | and select a different preferred email address. |
| 1587 | + |
Shawn O. Pearce | 02c2e80 | 2009-10-29 14:46:03 -0700 | [diff] [blame] | 1588 | Default is `mail`. |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1589 | |
Shawn O. Pearce | 59e0922 | 2009-08-19 09:04:49 -0700 | [diff] [blame] | 1590 | [[ldap.accountSshUserName]]ldap.accountSshUserName:: |
| 1591 | + |
| 1592 | _(Optional)_ Name of an attribute on the user account object which |
| 1593 | contains the initial value for the user's SSH username field in |
| 1594 | Gerrit. Typically this is the `uid` property in LDAP, but could |
| 1595 | also be `cn`. Administrators should prefer to match the attribute |
| 1596 | corresponding to the user's workstation username, as this is what |
| 1597 | SSH clients will default to. |
| 1598 | + |
Shawn O. Pearce | b86ae00 | 2009-09-26 16:54:05 -0700 | [diff] [blame] | 1599 | Attribute values may also be forced to lowercase, or to uppercase in |
Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1600 | an expression. For example, `${sAMAccountName.toLowerCase}` will |
Shawn O. Pearce | b86ae00 | 2009-09-26 16:54:05 -0700 | [diff] [blame] | 1601 | force the value of sAMAccountName, if defined, to be all lowercase. |
| 1602 | The suffix `.toUpperCase` can be used for the other direction. |
| 1603 | The suffix `.localPart` can be used to split attribute values of |
| 1604 | the form 'user@example.com' and return only the left hand side, for |
Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1605 | example `${userPrincipalName.localPart}` would provide only 'user'. |
Shawn O. Pearce | b86ae00 | 2009-09-26 16:54:05 -0700 | [diff] [blame] | 1606 | + |
Shawn O. Pearce | 3ca1dcf | 2009-08-20 08:56:23 -0700 | [diff] [blame] | 1607 | If set, users will be unable to modify their SSH username field, as |
| 1608 | Gerrit will populate it only from the LDAP data. |
| 1609 | + |
Shawn O. Pearce | 02c2e80 | 2009-10-29 14:46:03 -0700 | [diff] [blame] | 1610 | Default is `uid` for RFC 2307 servers, |
| 1611 | and `${sAMAccountName.toLowerCase}` for Active Directory. |
Shawn O. Pearce | 59e0922 | 2009-08-19 09:04:49 -0700 | [diff] [blame] | 1612 | |
Shawn O. Pearce | 7d25f78 | 2009-10-30 08:01:03 -0700 | [diff] [blame] | 1613 | [[ldap.accountMemberField]]ldap.accountMemberField:: |
Anthony | 93de7db | 2009-10-03 10:01:50 -0400 | [diff] [blame] | 1614 | + |
| 1615 | _(Optional)_ Name of an attribute on the user account object which |
Shawn O. Pearce | 7d25f78 | 2009-10-30 08:01:03 -0700 | [diff] [blame] | 1616 | contains the groups the user is part of. Typically used for Active |
| 1617 | Directory servers. |
Anthony | 93de7db | 2009-10-03 10:01:50 -0400 | [diff] [blame] | 1618 | + |
Shawn O. Pearce | 02c2e80 | 2009-10-29 14:46:03 -0700 | [diff] [blame] | 1619 | Default is unset for RFC 2307 servers (disabled) |
| 1620 | and `memberOf` for Active Directory. |
Anthony | 93de7db | 2009-10-03 10:01:50 -0400 | [diff] [blame] | 1621 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1622 | [[ldap.groupBase]]ldap.groupBase:: |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1623 | + |
| 1624 | Root of the tree containing all group objects. This is typically |
| 1625 | of the form `ou=groups,dc=example,dc=com`. |
| 1626 | |
Shawn O. Pearce | 304ccdb | 2009-08-25 12:25:27 -0700 | [diff] [blame] | 1627 | [[ldap.groupScope]]ldap.groupScope:: |
| 1628 | + |
| 1629 | Scope of the search performed for group objects. Must be one of: |
| 1630 | + |
| 1631 | * `one`: Search only one level below groupBase, but not recursive |
| 1632 | * `sub` or `subtree`: Search recursively below groupBase |
| 1633 | * `base` or `object`: Search exactly groupBase; probably not desired |
| 1634 | |
| 1635 | + |
| 1636 | Default is `subtree` as many directories have several levels. |
| 1637 | |
Shawn O. Pearce | 7d25f78 | 2009-10-30 08:01:03 -0700 | [diff] [blame] | 1638 | [[ldap.groupPattern]]ldap.groupPattern:: |
| 1639 | + |
| 1640 | Query pattern used when searching for an LDAP group to connect |
| 1641 | to a Gerrit group. This may be any valid LDAP query expression, |
| 1642 | including the standard `(&...)` and `(|...)` operators. The variable |
Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1643 | `${groupname}` is replaced with the search term supplied by the |
Shawn O. Pearce | 7d25f78 | 2009-10-30 08:01:03 -0700 | [diff] [blame] | 1644 | group owner. |
| 1645 | + |
Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1646 | Default is `(cn=${groupname})` for RFC 2307, |
| 1647 | and `(&(objectClass=group)(cn=${groupname}))` for Active Directory. |
Shawn O. Pearce | 7d25f78 | 2009-10-30 08:01:03 -0700 | [diff] [blame] | 1648 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1649 | [[ldap.groupMemberPattern]]ldap.groupMemberPattern:: |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1650 | + |
| 1651 | Query pattern to use when searching for the groups that a user |
| 1652 | account is currently a member of. This may be any valid LDAP query |
| 1653 | expression, including the standard `(&...)` and `(|...)` operators. |
| 1654 | + |
Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1655 | If auth.type is `HTTP_LDAP` then the variable `${username}` is |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1656 | replaced with a parameter set to the username that was supplied |
| 1657 | by the HTTP server. Other variables appearing in the pattern, |
Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1658 | such as `${fooBarAttribute}`, are replaced with the value of the |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1659 | corresponding attribute (in this case, `fooBarAttribute`) as read |
| 1660 | from the user's account object matched under `ldap.accountBase`. |
Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1661 | Attributes such as `${dn}` or `${uidNumber}` may be useful. |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1662 | + |
Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1663 | Default is `(memberUid=${username})` for RFC 2307, |
Shawn O. Pearce | 02c2e80 | 2009-10-29 14:46:03 -0700 | [diff] [blame] | 1664 | and unset (disabled) for Active Directory. |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1665 | |
Edwin Kempin | b3b0d29 | 2011-09-14 14:17:34 +0200 | [diff] [blame] | 1666 | [[ldap.localUsernameToLowerCase]]ldap.localUsernameToLowerCase:: |
| 1667 | + |
| 1668 | Converts the local username, that is used to login into the Gerrit |
| 1669 | WebUI, to lower case before doing the LDAP authentication. By setting |
| 1670 | this parameter to true, a case insensitive login to the Gerrit WebUI |
| 1671 | can be achieved. |
| 1672 | + |
| 1673 | If set, it must be ensured that the local usernames for all existing |
| 1674 | accounts are converted to lower case, otherwise a user that has a |
David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 1675 | local username that contains upper case characters will not be able to login |
Edwin Kempin | b3b0d29 | 2011-09-14 14:17:34 +0200 | [diff] [blame] | 1676 | anymore. The local usernames for the existing accounts can be |
| 1677 | converted to lower case by running the server program |
| 1678 | link:pgm-LocalUsernamesToLowerCase.html[LocalUsernamesToLowerCase]. |
| 1679 | Please be aware that the conversion of the local usernames to lower |
| 1680 | case can't be undone. For newly created accounts the local username |
| 1681 | will be directly stored in lower case. |
| 1682 | + |
| 1683 | By default, unset/false. |
Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1684 | |
Shawn O. Pearce | 8efb2a7 | 2009-08-18 19:45:33 -0700 | [diff] [blame] | 1685 | [[mimetype]]Section mimetype |
| 1686 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
Shawn O. Pearce | 01cb1190 | 2009-07-15 08:19:01 -0700 | [diff] [blame] | 1687 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1688 | [[mimetype.name.safe]]mimetype.<name>.safe:: |
Shawn O. Pearce | 01cb1190 | 2009-07-15 08:19:01 -0700 | [diff] [blame] | 1689 | + |
| 1690 | If set to true, files with the MIME type `<name>` will be sent as |
| 1691 | direct downloads to the user's browser, rather than being wrapped up |
| 1692 | inside of zipped archives. The type name may be a complete type |
Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1693 | name, e.g. `image/gif`, a generic media type, e.g. `image/*`, |
| 1694 | or the wildcard `*/*` to match all types. |
Shawn O. Pearce | 01cb1190 | 2009-07-15 08:19:01 -0700 | [diff] [blame] | 1695 | + |
| 1696 | By default, false for all MIME types. |
| 1697 | |
| 1698 | Common examples: |
Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 1699 | ---- |
| 1700 | [mimetype "image/*"] |
| 1701 | safe = true |
| 1702 | |
| 1703 | [mimetype "application/pdf"] |
| 1704 | safe = true |
| 1705 | |
| 1706 | [mimetype "application/msword"] |
| 1707 | safe = true |
| 1708 | |
| 1709 | [mimetype "application/vnd.ms-excel"] |
| 1710 | safe = true |
| 1711 | ---- |
Shawn O. Pearce | 01cb1190 | 2009-07-15 08:19:01 -0700 | [diff] [blame] | 1712 | |
Shawn O. Pearce | 5f11b29 | 2010-08-05 17:57:35 -0700 | [diff] [blame] | 1713 | |
| 1714 | [[pack]]Section pack |
| 1715 | ~~~~~~~~~~~~~~~~~~~~ |
| 1716 | Global settings controlling how Gerrit Code Review creates pack |
| 1717 | streams for Git clients running clone, fetch, or pull. Most of these |
| 1718 | variables are per-client request, and thus should be carefully set |
| 1719 | given the expected concurrent request load and available CPU and |
| 1720 | memory resources. |
| 1721 | |
| 1722 | [[pack.deltacompression]]pack.deltacompression:: |
| 1723 | + |
| 1724 | If true, delta compression between objects is enabled. This may |
| 1725 | result in a smaller overall transfer for the client, but requires |
| 1726 | more server memory and CPU time. |
| 1727 | + |
| 1728 | False (off) by default, matching Gerrit Code Review 2.1.4. |
| 1729 | |
| 1730 | [[pack.threads]]pack.threads:: |
| 1731 | + |
| 1732 | Maximum number of threads to use for delta compression (if enabled). |
| 1733 | This is per-client request. If set to 0 then the number of CPUs is |
| 1734 | auto-detected and one thread per CPU is used, per client request. |
| 1735 | + |
| 1736 | By default, 1. |
| 1737 | |
| 1738 | |
Shawn O. Pearce | 5ad16ea | 2012-05-09 14:24:25 -0700 | [diff] [blame] | 1739 | [[plugins]]Section plugins |
| 1740 | ~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 1741 | |
| 1742 | [[plugins.checkFrequency]]plugins.checkFrequency:: |
| 1743 | + |
| 1744 | How often plugins should be examined for new plugins to load, removed |
| 1745 | plugins to be unloaded, or updated plugins to be reloaded. Values can |
| 1746 | be specified using standard time unit abbreviations ('ms', 'sec', |
| 1747 | 'min', etc.). |
| 1748 | + |
| 1749 | If set to 0, automatic plugin reloading is disabled. Administrators |
| 1750 | may force reloading with link:cmd-plugin.html[gerrit plugin reload]. |
| 1751 | + |
| 1752 | Default is 1 minute. |
| 1753 | |
| 1754 | |
lincoln | 2be1160 | 2010-07-05 10:53:25 -0300 | [diff] [blame] | 1755 | [[receive]]Section receive |
| 1756 | ~~~~~~~~~~~~~~~~~~~~~~~~~~ |
Sasa Zivkov | 59d89c3 | 2011-11-18 15:32:35 +0100 | [diff] [blame] | 1757 | This section is used to set who can execute the 'receive-pack' and |
| 1758 | to limit the maximum Git object size that 'receive-pack' will accept. |
| 1759 | 'receive-pack' is what runs on the server during a user's push or |
Dave Borowitz | 234734a | 2012-03-01 14:22:29 -0800 | [diff] [blame] | 1760 | repo upload command. It also contains some advanced options for tuning the |
| 1761 | behavior of Gerrit's 'receive-pack' mechanism. |
lincoln | 2be1160 | 2010-07-05 10:53:25 -0300 | [diff] [blame] | 1762 | |
| 1763 | ---- |
| 1764 | [receive] |
| 1765 | allowGroup = GROUP_ALLOWED_TO_EXECUTE |
| 1766 | allowGroup = YET_ANOTHER_GROUP_ALLOWED_TO_EXECUTE |
Sasa Zivkov | 59d89c3 | 2011-11-18 15:32:35 +0100 | [diff] [blame] | 1767 | maxObjectSizeLimit = 40 m |
lincoln | 2be1160 | 2010-07-05 10:53:25 -0300 | [diff] [blame] | 1768 | ---- |
| 1769 | |
| 1770 | [[receive.allowGroup]]receive.allowGroup:: |
| 1771 | + |
| 1772 | Name of the groups of users that are allowed to execute |
| 1773 | 'receive-pack' on the server. One or more groups can be set. |
| 1774 | + |
| 1775 | If no groups are added, any user will be allowed to execute |
| 1776 | 'receive-pack' on the server. |
| 1777 | |
Sasa Zivkov | 59d89c3 | 2011-11-18 15:32:35 +0100 | [diff] [blame] | 1778 | [[receive.maxObjectSizeLimit]]receive.maxObjectSizeLimit:: |
| 1779 | + |
| 1780 | Maximum allowed Git object size that 'receive-pack' will accept. |
| 1781 | If an object is larger than the given size the pack-parsing will abort |
| 1782 | and the push operation will fail. If set to zero then there is no |
| 1783 | limit. |
| 1784 | + |
David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 1785 | Gerrit administrators can use this setting to prevent developers |
Sasa Zivkov | 59d89c3 | 2011-11-18 15:32:35 +0100 | [diff] [blame] | 1786 | from pushing objects which are too large to Gerrit. |
| 1787 | + |
| 1788 | Default is zero. |
| 1789 | + |
| 1790 | Common unit suffixes of 'k', 'm', or 'g' are supported. |
| 1791 | |
Dave Borowitz | 234734a | 2012-03-01 14:22:29 -0800 | [diff] [blame] | 1792 | [[receive.threadPoolSize]]receive.threadPoolSize:: |
| 1793 | + |
| 1794 | Maximum size of the thread pool in which the change data in received packs is |
| 1795 | processed. |
| 1796 | + |
| 1797 | Defaults to the number of available CPUs according to the Java runtime. |
| 1798 | |
Dave Borowitz | 1c40136 | 2012-03-02 17:39:17 -0800 | [diff] [blame] | 1799 | [[receive.timeout]]receive.timeout:: |
| 1800 | + |
Shawn O. Pearce | 00dd12d | 2012-03-12 15:52:11 -0700 | [diff] [blame] | 1801 | Overall timeout on the time taken to process the change data in |
| 1802 | received packs. Only includes the time processing Gerrit changes |
| 1803 | and updating references, not the time to index the pack. Values can |
| 1804 | be specified using standard time unit abbreviations ('ms', 'sec', |
| 1805 | 'min', etc.). |
Dave Borowitz | 1c40136 | 2012-03-02 17:39:17 -0800 | [diff] [blame] | 1806 | + |
Shawn O. Pearce | 00dd12d | 2012-03-12 15:52:11 -0700 | [diff] [blame] | 1807 | Default is 2 minutes. If no unit is specified, millisconds |
| 1808 | is assumed. |
Dave Borowitz | 1c40136 | 2012-03-02 17:39:17 -0800 | [diff] [blame] | 1809 | |
lincoln | 2be1160 | 2010-07-05 10:53:25 -0300 | [diff] [blame] | 1810 | |
Hugo Josefson | 072b470 | 2010-04-21 19:27:11 +0200 | [diff] [blame] | 1811 | [[repository]]Section repository |
| 1812 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 1813 | Repositories in this sense are the same as projects. |
| 1814 | |
Shawn O. Pearce | 897d921 | 2011-06-16 16:59:59 -0700 | [diff] [blame] | 1815 | In the following example configuration `Registered Users` is set |
| 1816 | to be the default owner of new projects. |
Hugo Josefson | 072b470 | 2010-04-21 19:27:11 +0200 | [diff] [blame] | 1817 | |
| 1818 | ---- |
| 1819 | [repository "*"] |
Hugo Josefson | 072b470 | 2010-04-21 19:27:11 +0200 | [diff] [blame] | 1820 | ownerGroup = Registered Users |
| 1821 | ---- |
| 1822 | |
| 1823 | [NOTE] |
| 1824 | Currently only the repository name `*` is supported. |
| 1825 | This is a wildcard designating all repositories. |
| 1826 | |
Hugo Josefson | 072b470 | 2010-04-21 19:27:11 +0200 | [diff] [blame] | 1827 | [[repository.name.ownerGroup]]repository.<name>.ownerGroup:: |
| 1828 | + |
| 1829 | A name of a group which exists in the database. Zero, one or many |
| 1830 | groups are allowed. Each on its own line. Groups which don't exist |
| 1831 | in the database are ignored. |
Hugo Josefson | 072b470 | 2010-04-21 19:27:11 +0200 | [diff] [blame] | 1832 | |
Shawn O. Pearce | 94860ee | 2011-09-29 13:11:08 -0700 | [diff] [blame] | 1833 | [[rules]]Section rules |
| 1834 | ~~~~~~~~~~~~~~~~~~~~~~ |
| 1835 | |
| 1836 | [[rules.enable]]rules.enable:: |
| 1837 | + |
| 1838 | If true, Gerrit will load and excute 'rules.pl' files in each |
| 1839 | project's refs/meta/config branch, if present. When set to false, |
| 1840 | only the default internal rules will be used. |
| 1841 | + |
| 1842 | Default is true, to execute project specific rules. |
| 1843 | |
Shawn O. Pearce | 8efb2a7 | 2009-08-18 19:45:33 -0700 | [diff] [blame] | 1844 | [[sendemail]]Section sendemail |
| 1845 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
Shawn O. Pearce | b0572c6 | 2009-06-01 14:18:22 -0700 | [diff] [blame] | 1846 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1847 | [[sendemail.enable]]sendemail.enable:: |
Shawn O. Pearce | 2e4573b | 2009-06-02 09:09:50 -0700 | [diff] [blame] | 1848 | + |
| 1849 | If false Gerrit will not send email messages, for any reason, |
| 1850 | and all other properties of section sendemail are ignored. |
| 1851 | + |
| 1852 | By default, true, allowing notifications to be sent. |
| 1853 | |
Shawn O. Pearce | 5c31bd7 | 2009-09-10 18:13:33 -0700 | [diff] [blame] | 1854 | [[sendemail.from]]sendemail.from:: |
| 1855 | + |
| 1856 | Designates what name and address Gerrit will place in the From |
| 1857 | field of any generated email messages. The supported values are: |
| 1858 | + |
| 1859 | * `USER` |
| 1860 | + |
| 1861 | Gerrit will set the From header to use the current user's |
| 1862 | Full Name and Preferred Email. This may cause messsages to be |
| 1863 | classified as spam if the user's domain has SPF or DKIM enabled |
| 1864 | and <<sendemail.smtpServer,sendemail.smtpServer>> is not a trusted |
| 1865 | relay for that domain. |
| 1866 | + |
| 1867 | * `MIXED` |
| 1868 | + |
Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1869 | Shorthand for `${user} (Code Review) <review@example.com>` where |
Shawn O. Pearce | 5c31bd7 | 2009-09-10 18:13:33 -0700 | [diff] [blame] | 1870 | `review@example.com` is the same as <<user.email,user.email>>. |
| 1871 | See below for a description of how the replacement is handled. |
| 1872 | + |
| 1873 | * `SERVER` |
| 1874 | + |
| 1875 | Gerrit will set the From header to the same name and address |
| 1876 | it records in any commits Gerrit creates. This is set by |
| 1877 | <<user.name,user.name>> and <<user.email,user.email>>, or guessed |
| 1878 | from the local operating system. |
| 1879 | + |
| 1880 | * 'Code Review' `<`'review'`@`'example.com'`>` |
| 1881 | + |
| 1882 | If set to a name and email address in brackets, Gerrit will use |
| 1883 | this name and email address for any messages, overriding the name |
| 1884 | that may have been selected for commits by user.name and user.email. |
Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1885 | Optionally, the name portion may contain the placeholder `${user}`, |
Shawn O. Pearce | 5c31bd7 | 2009-09-10 18:13:33 -0700 | [diff] [blame] | 1886 | which is replaced by the Full Name of the current user. |
| 1887 | |
| 1888 | + |
| 1889 | By default, MIXED. |
| 1890 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1891 | [[sendemail.smtpServer]]sendemail.smtpServer:: |
Shawn O. Pearce | b0572c6 | 2009-06-01 14:18:22 -0700 | [diff] [blame] | 1892 | + |
| 1893 | Hostname (or IP address) of a SMTP server that will relay |
| 1894 | messages generated by Gerrit to end users. |
| 1895 | + |
| 1896 | By default, 127.0.0.1 (aka localhost). |
| 1897 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1898 | [[sendemail.smtpServerPort]]sendemail.smtpServerPort:: |
Shawn O. Pearce | b0572c6 | 2009-06-01 14:18:22 -0700 | [diff] [blame] | 1899 | + |
| 1900 | Port number of the SMTP server in sendemail.smtpserver. |
| 1901 | + |
Shawn O. Pearce | 6e9a83f | 2009-11-02 10:30:48 -0800 | [diff] [blame] | 1902 | By default, 25, or 465 if smtpEncryption is 'ssl'. |
| 1903 | |
| 1904 | [[sendemail.smtpEncryption]]sendemail.smtpEncryption:: |
| 1905 | + |
| 1906 | Specify the encryption to use, either 'ssl' or 'tls'. |
| 1907 | + |
| 1908 | By default, 'none', indicating no encryption is used. |
| 1909 | |
| 1910 | [[sendemail.sslVerify]]sendemail.sslVerify:: |
| 1911 | + |
| 1912 | If false and sendemail.smtpEncryption is 'ssl' or 'tls', Gerrit |
| 1913 | will not verify the server certificate when it connects to send |
| 1914 | an email message. |
| 1915 | + |
| 1916 | By default, true, requiring the certificate to be verified. |
Shawn O. Pearce | b0572c6 | 2009-06-01 14:18:22 -0700 | [diff] [blame] | 1917 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1918 | [[sendemail.smtpUser]]sendemail.smtpUser:: |
Shawn O. Pearce | b0572c6 | 2009-06-01 14:18:22 -0700 | [diff] [blame] | 1919 | + |
| 1920 | User name to authenticate with, if required for relay. |
| 1921 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1922 | [[sendemail.smtpPass]]sendemail.smtpPass:: |
Shawn O. Pearce | b0572c6 | 2009-06-01 14:18:22 -0700 | [diff] [blame] | 1923 | + |
| 1924 | Password for the account named by sendemail.smtpUser. |
| 1925 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1926 | [[sendemail.allowrcpt]]sendemail.allowrcpt:: |
Shawn O. Pearce | 219a8ee | 2009-06-01 18:13:57 -0700 | [diff] [blame] | 1927 | + |
| 1928 | If present, each value adds one entry to the whitelist of email |
| 1929 | addresses that Gerrit can send email to. If set to a complete |
| 1930 | email address, that one address is added to the white list. |
| 1931 | If set to a domain name, any address at that domain can receive |
| 1932 | email from Gerrit. |
| 1933 | + |
| 1934 | By default, unset, permitting delivery to any email address. |
| 1935 | |
Shawn O. Pearce | 02aacbc | 2012-06-12 13:44:22 -0700 | [diff] [blame] | 1936 | [[sendemail.includeDiff]]sendemail.includeDiff:: |
| 1937 | + |
| 1938 | If true, new change emails from Gerrit will include the complete |
Shawn O. Pearce | 28a950b | 2012-06-12 14:36:34 -0700 | [diff] [blame] | 1939 | unified diff of the change. Variable maxmimumDiffSize places an upper |
| 1940 | limit on how large the email can get when this option is enabled. |
Shawn O. Pearce | 02aacbc | 2012-06-12 13:44:22 -0700 | [diff] [blame] | 1941 | + |
| 1942 | By default, false. |
| 1943 | |
Shawn O. Pearce | 28a950b | 2012-06-12 14:36:34 -0700 | [diff] [blame] | 1944 | [[sendemail.maximumDiffSize]]sendemail.maximumDiffSize:: |
| 1945 | + |
| 1946 | Largest size of unified diff output to include in an email. When |
| 1947 | the diff exceeds this size the file paths will be listed instead. |
| 1948 | Standard byte unit suffixes are supported. |
| 1949 | + |
| 1950 | By default, 256 KiB. |
| 1951 | |
Alex Blewitt | 9cca740 | 2011-02-11 01:39:30 +0000 | [diff] [blame] | 1952 | [[sendemail.importance]]sendemail.importance:: |
| 1953 | + |
| 1954 | If present, emails sent from Gerrit will have the given level |
| 1955 | of importance. Valid values include 'high' and 'low', which |
| 1956 | email clients will render in different ways. |
| 1957 | + |
| 1958 | By default, unset, so no Importance header is generated. |
| 1959 | |
| 1960 | [[sendemail.expiryDays]]sendemail.expiryDays:: |
| 1961 | + |
| 1962 | If present, emails sent from Gerrit will expire after the given |
| 1963 | number of days. This will add the Expiry-Date header and |
| 1964 | email clients may expire or expunge mails whose Expiry-Date |
| 1965 | header is in the past. This should be a positive non-zero |
| 1966 | number indicating how many days in the future the mails |
| 1967 | should expire. |
| 1968 | + |
| 1969 | By default, unset, so no Expiry-Date header is generated. |
| 1970 | |
Shawn O. Pearce | dba9764 | 2011-09-07 20:12:31 -0700 | [diff] [blame] | 1971 | |
| 1972 | [[site]]Section site |
| 1973 | ~~~~~~~~~~~~~~~~~~~~ |
| 1974 | |
| 1975 | [[site.checkUserAgent]]site.checkUserAgent:: |
| 1976 | + |
| 1977 | If true the server checks the User-Agent HTTP header and sends the |
| 1978 | correct JavaScript to the client as part of the initial page load. |
| 1979 | This usually reduces a round-trip for the client, allowing the UI to |
| 1980 | start more quickly. If false, a tiny JavaScript loader is sent to the |
| 1981 | client instead to determine the correct code to use. Default is true. |
| 1982 | |
| 1983 | [[site.refreshHeaderFooter]]site.refreshHeaderFooter:: |
| 1984 | + |
| 1985 | If true the server checks the site header, footer and CSS files for |
| 1986 | updated versions. If false, a server restart is required to change |
| 1987 | any of these resources. Default is true, allowing automatic reloads. |
| 1988 | |
Shawn O. Pearce | 6bd04fd | 2012-04-05 14:39:22 -0700 | [diff] [blame] | 1989 | [[site.enableDeprecatedQuery]]site.enableDeprecatedQuery:: |
| 1990 | + |
| 1991 | If true the deprecated `/query` URL is available to return JSON |
| 1992 | and text results for changes. If false, the URL is disabled and |
| 1993 | returns 404 to clients. Default is true, enabling `/query`. |
| 1994 | |
Sasa Zivkov | de980a4 | 2012-06-14 14:57:53 +0200 | [diff] [blame] | 1995 | [[site.upgradeSchemaOnStartup]]site.upgradeSchemaOnStartup:: |
| 1996 | + |
| 1997 | Control whether schema upgrade should be done on Gerrit startup. The following |
| 1998 | values are supported: |
| 1999 | + |
| 2000 | * `OFF` |
| 2001 | + |
| 2002 | No automatic schema upgrade on startup. |
| 2003 | + |
| 2004 | * `AUTO` |
| 2005 | + |
| 2006 | Perform schema migration on startup, if necessary. If, as a result of |
| 2007 | schema migration, there would be any unused database objects they will |
| 2008 | be dropped automatically. |
| 2009 | + |
| 2010 | * `AUTO_NO_PRUNE` |
| 2011 | + |
| 2012 | Like `AUTO` but unused database objects will not be pruned. |
| 2013 | |
| 2014 | + |
| 2015 | The default is `OFF`. |
| 2016 | |
Shawn O. Pearce | 521380a | 2012-05-11 14:57:56 -0700 | [diff] [blame] | 2017 | [[ssh-alias]] Section ssh-alias |
| 2018 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 2019 | |
| 2020 | Variables in section ssh-alias permit the site administrator to alias |
| 2021 | another command from Gerrit or a plugin into the `gerrit` command |
| 2022 | namespace. To alias `replication start` to `gerrit replicate`: |
| 2023 | |
| 2024 | ---- |
| 2025 | [ssh-alias] |
| 2026 | replicate = replication start |
| 2027 | ---- |
Shawn O. Pearce | dba9764 | 2011-09-07 20:12:31 -0700 | [diff] [blame] | 2028 | |
Shawn O. Pearce | 8efb2a7 | 2009-08-18 19:45:33 -0700 | [diff] [blame] | 2029 | [[sshd]] Section sshd |
Shawn O. Pearce | a758fef | 2009-08-19 08:29:32 -0700 | [diff] [blame] | 2030 | ~~~~~~~~~~~~~~~~~~~~~ |
Shawn O. Pearce | 9410f2c | 2009-05-14 10:26:47 -0700 | [diff] [blame] | 2031 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 2032 | [[sshd.listenAddress]]sshd.listenAddress:: |
Shawn O. Pearce | 1d3cb444 | 2009-05-30 14:03:31 -0700 | [diff] [blame] | 2033 | + |
| 2034 | Specifies the local addresses the internal SSHD should listen |
| 2035 | for connections on. The following forms may be used to specify |
| 2036 | an address. In any form, `:'port'` may be omitted to use the |
| 2037 | default of 29418. |
| 2038 | + |
| 2039 | * 'hostname':'port' (for example `review.example.com:29418`) |
| 2040 | * 'IPv4':'port' (for example `10.0.0.1:29418`) |
| 2041 | * ['IPv6']:'port' (for example `[ff02::1]:29418`) |
Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 2042 | * *:'port' (for example `*:29418`) |
Shawn O. Pearce | 1d3cb444 | 2009-05-30 14:03:31 -0700 | [diff] [blame] | 2043 | |
| 2044 | + |
| 2045 | If multiple values are supplied, the daemon will listen on all |
| 2046 | of them. |
| 2047 | + |
Shawn O. Pearce | 6af6f5f | 2010-06-08 17:38:43 -0700 | [diff] [blame] | 2048 | To disable the internal SSHD, set listenAddress to `off`. |
| 2049 | + |
Shawn O. Pearce | 1d3cb444 | 2009-05-30 14:03:31 -0700 | [diff] [blame] | 2050 | By default, *:29418. |
| 2051 | |
James Y Knight | 910bd86 | 2011-01-11 20:05:56 -0500 | [diff] [blame] | 2052 | [[sshd.advertisedAddress]]sshd.advertisedAddress:: |
| 2053 | + |
| 2054 | Specifies the addresses clients should be told to connect to. |
| 2055 | This may differ from sshd.listenAddress if a firewall based port |
| 2056 | redirector is being used, making Gerrit appear to answer on port |
| 2057 | 22. The following forms may be used to specify an address. In any |
| 2058 | form, `:'port'` may be omitted to use the default SSH port of 22. |
| 2059 | + |
| 2060 | * 'hostname':'port' (for example `review.example.com:22`) |
| 2061 | * 'IPv4':'port' (for example `10.0.0.1:29418`) |
| 2062 | * ['IPv6']:'port' (for example `[ff02::1]:29418`) |
| 2063 | |
| 2064 | + |
| 2065 | If multiple values are supplied, the daemon will advertise all |
| 2066 | of them. |
| 2067 | + |
| 2068 | By default, sshd.listenAddress. |
| 2069 | |
Shawn O. Pearce | 149238a | 2009-09-10 12:25:20 -0700 | [diff] [blame] | 2070 | [[sshd.reuseAddress]]sshd.reuseAddress:: |
Shawn O. Pearce | 9410f2c | 2009-05-14 10:26:47 -0700 | [diff] [blame] | 2071 | + |
| 2072 | If true, permits the daemon to bind to the port even if the port |
| 2073 | is already in use. If false, the daemon ensures the port is not |
| 2074 | in use before starting. Busy sites may need to set this to true |
| 2075 | to permit fast restarts. |
| 2076 | + |
| 2077 | By default, true. |
Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 2078 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 2079 | [[sshd.tcpKeepAlive]]sshd.tcpKeepAlive:: |
Shawn O. Pearce | fc9081f | 2009-05-14 10:26:59 -0700 | [diff] [blame] | 2080 | + |
| 2081 | If true, enables TCP keepalive messages to the other side, so |
| 2082 | the daemon can terminate connections if the peer disappears. |
| 2083 | + |
| 2084 | By default, true. |
| 2085 | |
Shawn O. Pearce | 1a4580b | 2009-11-19 17:37:10 -0800 | [diff] [blame] | 2086 | [[sshd.threads]]sshd.threads:: |
| 2087 | + |
| 2088 | Number of threads to use when executing SSH command requests. |
| 2089 | If additional requests are received while all threads are busy they |
David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 2090 | are queued and serviced in a first-come-first-served order. |
Shawn O. Pearce | 1a4580b | 2009-11-19 17:37:10 -0800 | [diff] [blame] | 2091 | + |
| 2092 | By default, 1.5x the number of CPUs available to the JVM. |
| 2093 | |
Nico Sallembien | fc53f7f | 2010-05-18 16:40:10 -0700 | [diff] [blame] | 2094 | [[sshd.batchThreads]]sshd.batchThreads:: |
| 2095 | + |
| 2096 | Number of threads to allocate for SSH command requests from |
Fredrik Luthander | 4684302 | 2012-03-13 16:11:02 +0100 | [diff] [blame] | 2097 | link:access-control.html#non-interactive_users[non-interactive users]. |
| 2098 | If equals to 0, then all non-interactive requests are executed in the same |
| 2099 | queue as interactive requests. |
Nico Sallembien | fc53f7f | 2010-05-18 16:40:10 -0700 | [diff] [blame] | 2100 | + |
| 2101 | Any other value will remove the number of threads from the queue |
| 2102 | allocated to interactive users, and create a separate thread pool |
| 2103 | of the requested size, which will be used to run commands from |
| 2104 | non-interactive users. |
| 2105 | + |
| 2106 | If the number of threads requested for non-interactive users is larger |
| 2107 | than the total number of threads allocated in sshd.threads, then the |
| 2108 | value of sshd.threads is increased to accomodate the requested value. |
| 2109 | + |
| 2110 | By default, 0. |
| 2111 | |
Kenny Root | 15ac1b8 | 2010-02-24 00:29:20 -0800 | [diff] [blame] | 2112 | [[sshd.streamThreads]]sshd.streamThreads:: |
| 2113 | + |
| 2114 | Number of threads to use when formatting events to asynchronous |
| 2115 | streaming clients. Event formatting is multiplexed onto this thread |
| 2116 | pool by a simple FIFO scheduling system. |
| 2117 | + |
| 2118 | By default, 1 plus the number of CPUs available to the JVM. |
| 2119 | |
Edwin Kempin | b5df3b8 | 2011-10-10 11:31:14 +0200 | [diff] [blame] | 2120 | [[sshd.commandStartThreads]]sshd.commandStartThreads:: |
Shawn O. Pearce | d629655 | 2011-05-15 13:56:30 -0700 | [diff] [blame] | 2121 | + |
| 2122 | Number of threads used to parse a command line submitted by a client |
| 2123 | over SSH for execution, create the internal data structures used by |
| 2124 | that command, and schedule it for execution on another thread. |
| 2125 | + |
| 2126 | By default, 2. |
| 2127 | |
Shawn O. Pearce | 8a0bf36 | 2010-11-05 17:49:41 -0700 | [diff] [blame] | 2128 | [[sshd.maxAuthTries]]sshd.maxAuthTries:: |
| 2129 | + |
| 2130 | Maximum number of authentication attempts before the server |
| 2131 | disconnects the client. Each public key that a client has loaded |
| 2132 | into its local agent counts as one auth request. Users can work |
| 2133 | around the server's limit by loading less keys into their agent, |
| 2134 | or selecting a specific key in their `~/.ssh/config` file with |
| 2135 | the `IdentityFile` option. |
| 2136 | + |
| 2137 | By default, 6. |
| 2138 | |
| 2139 | [[sshd.loginGraceTime]]sshd.loginGraceTime:: |
| 2140 | + |
| 2141 | Time in seconds that a client has to authenticate before the server |
| 2142 | automatically terminates their connection. Values should use common |
| 2143 | unit suffixes to express their setting: |
| 2144 | + |
| 2145 | * s, sec, second, seconds |
| 2146 | * m, min, minute, minutes |
| 2147 | * h, hr, hour, hours |
| 2148 | * d, day, days |
| 2149 | |
| 2150 | + |
| 2151 | By default, 2 minutes. |
| 2152 | |
| 2153 | [[sshd.maxConnectionsPerUser]]sshd.maxConnectionsPerUser:: |
| 2154 | + |
| 2155 | Maximum number of concurrent SSH sessions that a user account |
| 2156 | may open at one time. This is the number of distinct SSH logins |
David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 2157 | that each user may have active at one time, and is not related to |
Shawn O. Pearce | 8a0bf36 | 2010-11-05 17:49:41 -0700 | [diff] [blame] | 2158 | the number of commands a user may issue over a single connection. |
| 2159 | If set to 0, there is no limit. |
| 2160 | + |
| 2161 | By default, 64. |
| 2162 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 2163 | [[sshd.cipher]]sshd.cipher:: |
Shawn O. Pearce | 0bf2f52 | 2009-05-14 11:02:03 -0700 | [diff] [blame] | 2164 | + |
| 2165 | Available ciphers. To permit multiple ciphers, specify multiple |
| 2166 | `sshd.cipher` keys in the configuration file, one cipher name |
| 2167 | per key. Cipher names starting with `+` are enabled in addition |
| 2168 | to the default ciphers, cipher names starting with `-` are removed |
| 2169 | from the default cipher set. |
| 2170 | + |
| 2171 | Supported ciphers: aes128-cbc, aes128-cbc, aes256-cbc, blowfish-cbc, |
| 2172 | 3des-cbc, none. |
| 2173 | + |
| 2174 | By default, all supported ciphers except `none` are available. |
| 2175 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 2176 | [[sshd.mac]]sshd.mac:: |
Shawn O. Pearce | 0bf2f52 | 2009-05-14 11:02:03 -0700 | [diff] [blame] | 2177 | + |
| 2178 | Available MAC (message authentication code) algorithms. To permit |
| 2179 | multiple algorithms, specify multiple `sshd.mac` keys in the |
| 2180 | configuration file, one MAC per key. MAC names starting with `+` |
| 2181 | are enabled in addition to the default MACs, MAC names starting with |
| 2182 | `-` are removed from the default MACs. |
| 2183 | + |
| 2184 | Supported MACs: hmac-md5, hmac-md5-96, hmac-sha1, hmac-sha1-96. |
| 2185 | + |
| 2186 | By default, all supported MACs are available. |
| 2187 | |
Shawn O. Pearce | 07bd6fb | 2011-04-29 19:15:47 -0700 | [diff] [blame] | 2188 | [[suggest]] Section suggest |
| 2189 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 2190 | |
Dave Borowitz | 1ae8c53 | 2012-03-09 18:39:40 -0800 | [diff] [blame] | 2191 | [[suggest.accounts]]suggest.accounts:: |
Shawn O. Pearce | 07bd6fb | 2011-04-29 19:15:47 -0700 | [diff] [blame] | 2192 | + |
Dave Borowitz | 45baa89 | 2012-02-23 16:43:05 -0800 | [diff] [blame] | 2193 | If `true`, visible user accounts (according to the value of |
| 2194 | `accounts.visibility`) will be offered as completion suggestions |
| 2195 | when adding a reviewer to a change, or a user to a group. |
Shawn O. Pearce | 07bd6fb | 2011-04-29 19:15:47 -0700 | [diff] [blame] | 2196 | + |
Dave Borowitz | 45baa89 | 2012-02-23 16:43:05 -0800 | [diff] [blame] | 2197 | If `false`, account suggestion is disabled. |
Shawn O. Pearce | 07bd6fb | 2011-04-29 19:15:47 -0700 | [diff] [blame] | 2198 | + |
Dave Borowitz | 45baa89 | 2012-02-23 16:43:05 -0800 | [diff] [blame] | 2199 | Older configurations may also have one of the `accounts.visibility` |
| 2200 | values for this field, including `OFF` as a synonym for `NONE`. If |
| 2201 | `accounts.visibility` is also set, that value overrides this one; |
| 2202 | otherwise, this value applies to both `suggest.accounts` and |
| 2203 | `accounts.visibility`. |
Edwin Kempin | 4248881 | 2011-05-20 03:11:43 +0200 | [diff] [blame] | 2204 | + |
Dave Borowitz | 45baa89 | 2012-02-23 16:43:05 -0800 | [diff] [blame] | 2205 | New configurations should prefer the boolean value for this field |
| 2206 | and an enum value for `accounts.visibility`. |
Shawn O. Pearce | 07bd6fb | 2011-04-29 19:15:47 -0700 | [diff] [blame] | 2207 | |
Shawn O. Pearce | 2ba3ab4 | 2010-02-25 12:10:10 -0800 | [diff] [blame] | 2208 | [[theme]] Section theme |
| 2209 | ~~~~~~~~~~~~~~~~~~~~~~~ |
| 2210 | |
| 2211 | [[theme.backgroundColor]]theme.backgroundColor:: |
| 2212 | + |
| 2213 | Background color for the page, and major data tables like the all |
| 2214 | open changes table or the account dashboard. The value must be a |
| 2215 | valid HTML hex color code, or standard color name. |
| 2216 | + |
Shawn O. Pearce | 9ca8ae3 | 2011-05-24 08:28:40 -0700 | [diff] [blame] | 2217 | By default `FCFEEF` (a creme color) for signed-out theme and white |
| 2218 | (`FFFFFF`) for signed-in theme. |
Shawn O. Pearce | 2ba3ab4 | 2010-02-25 12:10:10 -0800 | [diff] [blame] | 2219 | |
| 2220 | [[theme.topMenuColor]]theme.topMenuColor:: |
| 2221 | + |
| 2222 | This is the color of the main menu bar at the top of the page. |
| 2223 | The value must be a valid HTML hex color code, or standard color |
| 2224 | name. The value defaults to <<theme.trimColor,trimColor>>. |
| 2225 | |
| 2226 | [[theme.textColor]]theme.textColor:: |
| 2227 | + |
| 2228 | Text color for the page, and major data tables like the all |
| 2229 | open changes table or the account dashboard. The value must be a |
| 2230 | valid HTML hex color code, or standard color name. |
| 2231 | + |
| 2232 | By default black, `000000`. |
| 2233 | |
| 2234 | [[theme.trimColor]]theme.trimColor:: |
| 2235 | + |
| 2236 | Primary color used as a background color behind text. This is |
| 2237 | the color of the main menu bar at the top, of table headers, |
| 2238 | and of major UI areas that we want to offset from other portions |
| 2239 | of the page. The value must be a valid HTML hex color code, or |
| 2240 | standard color name. |
| 2241 | + |
| 2242 | By default a shade of green, `D4E9A9`. |
| 2243 | |
| 2244 | [[theme.selectionColor]]theme.selectionColor:: |
| 2245 | + |
| 2246 | Background color used within a trimColor area to denote the currently |
| 2247 | selected tab, or the background color used in a table to denote the |
| 2248 | currently selected row. The value must be a valid HTML hex color |
| 2249 | code, or standard color name. |
| 2250 | + |
| 2251 | By default a shade of yellow, `FFFFCC`. |
| 2252 | |
Andrew Hutchings | cfd7abb | 2012-06-29 10:57:05 +0100 | [diff] [blame] | 2253 | [[theme.changeTableOutdatedColor]]theme.changeTableOutdatedColor:: |
| 2254 | + |
| 2255 | Background color used for patch outdated messages. The value must be |
| 2256 | a valid HTML hex color code, or standard color name. |
| 2257 | + |
Edwin Kempin | b034733 | 2012-07-17 10:14:32 +0200 | [diff] [blame^] | 2258 | By default a shade of red, `F08080`. |
Andrew Hutchings | cfd7abb | 2012-06-29 10:57:05 +0100 | [diff] [blame] | 2259 | |
| 2260 | [[theme.tableOddRowColor]]theme.tableOddRowColor:: |
| 2261 | + |
| 2262 | Background color for tables such as lists of open reviews for odd |
| 2263 | rows. This is so you can have a different color for odd and even |
| 2264 | rows of the table. The value must be a valid HTML hex color code, |
| 2265 | or standard color name. |
| 2266 | + |
| 2267 | By default transparent. |
| 2268 | |
| 2269 | [[theme.tableEvenRowColor]]theme.tableEvenRowColor:: |
| 2270 | + |
| 2271 | Background color for tables such as lists of open reviews for even |
| 2272 | rows. This is so you can have a different color for odd and even |
| 2273 | rows of the table. The value must be a valid HTML hex color code, |
| 2274 | or standard color name. |
| 2275 | + |
| 2276 | By default transparent. |
| 2277 | |
Shawn O. Pearce | a83bb1c | 2011-05-20 08:46:48 -0700 | [diff] [blame] | 2278 | A different theme may be used for signed-in vs. signed-out user status |
| 2279 | by using the "signed-in" and "signed-out" theme sections. Variables |
| 2280 | not specified in a section are inherited from the default theme. |
| 2281 | |
| 2282 | ---- |
| 2283 | [theme] |
| 2284 | backgroundColor = FFFFFF |
| 2285 | [theme "signed-in"] |
| 2286 | backgroundColor = C0C0C0 |
| 2287 | [theme "signed-out"] |
| 2288 | backgroundColor = 00FFFF |
| 2289 | ---- |
| 2290 | |
Goran Lungberg | 04132a1 | 2010-06-15 17:20:37 -0700 | [diff] [blame] | 2291 | [[trackingid]] Section trackingid |
Shawn O. Pearce | 91763a0 | 2010-06-16 15:39:33 -0700 | [diff] [blame] | 2292 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
Goran Lungberg | 04132a1 | 2010-06-15 17:20:37 -0700 | [diff] [blame] | 2293 | |
Shawn O. Pearce | e800b1e | 2010-06-16 17:33:43 -0700 | [diff] [blame] | 2294 | Tagged footer lines containing references to external |
| 2295 | tracking systems, parsed out of the commit message and |
| 2296 | saved in Gerrit's database. After making changes to |
| 2297 | this section, existing changes must be reindexed with the |
| 2298 | link:pgm-ScanTrackingIds.html[ScanTrackingIds] program. |
Goran Lungberg | 04132a1 | 2010-06-15 17:20:37 -0700 | [diff] [blame] | 2299 | |
Edwin Kempin | bb421f1 | 2011-08-25 11:19:00 +0200 | [diff] [blame] | 2300 | The tracking ids are searchable using tr:<tracking id> or |
Shawn O. Pearce | 91763a0 | 2010-06-16 15:39:33 -0700 | [diff] [blame] | 2301 | bug:<tracking id>. |
Goran Lungberg | 04132a1 | 2010-06-15 17:20:37 -0700 | [diff] [blame] | 2302 | |
| 2303 | ---- |
| 2304 | [trackingid "jira-bug"] |
| 2305 | footer = Bugfix: |
| 2306 | match = JRA\\d{2,8} |
| 2307 | system = JIRA |
| 2308 | |
| 2309 | [trackingid "jira-feature"] |
| 2310 | footer = Feature |
| 2311 | match = JRA(\\d{2,8}) |
| 2312 | system = JIRA |
| 2313 | ---- |
| 2314 | |
| 2315 | [[trackingid.name.footer]]trackingid.<name>.footer:: |
| 2316 | + |
| 2317 | A prefix tag that identify the footer line to parse for tracking ids. |
Kevin Degi | 9af42ea | 2011-08-01 15:54:42 -0600 | [diff] [blame] | 2318 | Several trackingid entries can have the same footer tag. A single |
| 2319 | trackingid entry can have multiple footer tags. If multiple footer |
| 2320 | tags are specified, each tag will be parsed separately. |
Goran Lungberg | 04132a1 | 2010-06-15 17:20:37 -0700 | [diff] [blame] | 2321 | (the trailing ":" is optional) |
| 2322 | |
| 2323 | [[trackingid.name.match]]trackingid.<name>.match:: |
| 2324 | + |
Magnus Bäck | e561183 | 2011-02-02 08:57:15 +0100 | [diff] [blame] | 2325 | A link:http://download.oracle.com/javase/6/docs/api/java/util/regex/Pattern.html[standard |
| 2326 | Java regular expression (java.util.regex)] used to match the |
| 2327 | external tracking id part of the footer line. The match can |
| 2328 | result in several entries in the DB. If grouping is used in the |
| 2329 | regex the first group will be interpreted as the tracking id. |
David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 2330 | Tracking ids longer than 20 characters will be ignored. |
Goran Lungberg | 04132a1 | 2010-06-15 17:20:37 -0700 | [diff] [blame] | 2331 | + |
| 2332 | The configuration file parser eats one level of backslashes, so the |
| 2333 | character class `\s` requires `\\s` in the configuration file. The |
| 2334 | parser also terminates the line at the first `#`, so a match |
| 2335 | expression containing # must be wrapped in double quotes. |
| 2336 | |
| 2337 | [[trackingid.name.system]]trackingid.<name>.system:: |
| 2338 | + |
David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 2339 | The name of the external tracking system (maximum 10 characters). |
Goran Lungberg | 04132a1 | 2010-06-15 17:20:37 -0700 | [diff] [blame] | 2340 | It is possible to have several trackingid entries for the same |
| 2341 | tracking system. |
| 2342 | |
Shawn O. Pearce | 6e4dfdd | 2010-05-12 17:26:08 -0700 | [diff] [blame] | 2343 | [[transfer]] Section transfer |
| 2344 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 2345 | |
| 2346 | [[transfer.timeout]]transfer.timeout:: |
| 2347 | + |
| 2348 | Number of seconds to wait for a single network read or write |
| 2349 | to complete before giving up and declaring the remote side is |
| 2350 | not responding. If 0, there is no timeout, and this server will |
| 2351 | wait indefinitely for a transfer to finish. |
| 2352 | + |
| 2353 | A timeout should be large enough to mostly transfer the objects to |
| 2354 | the other side. 1 second may be too small for larger projects, |
| 2355 | especially over a WAN link, while 10-30 seconds is a much more |
| 2356 | reasonable timeout value. |
| 2357 | + |
| 2358 | Defaults to 0 seconds, wait indefinitely. |
| 2359 | |
lincoln | 2be1160 | 2010-07-05 10:53:25 -0300 | [diff] [blame] | 2360 | |
| 2361 | [[upload]]Section upload |
Remy Bohmer | 203eea3 | 2012-02-19 21:21:36 +0100 | [diff] [blame] | 2362 | ~~~~~~~~~~~~~~~~~~~~~~~~ |
lincoln | 2be1160 | 2010-07-05 10:53:25 -0300 | [diff] [blame] | 2363 | Sets the group of users allowed to execute 'upload-pack' on the |
| 2364 | server, 'upload-pack' is what runs on the server during a user's |
| 2365 | fetch, clone or repo sync command. |
| 2366 | |
| 2367 | ---- |
| 2368 | [upload] |
| 2369 | allowGroup = GROUP_ALLOWED_TO_EXECUTE |
| 2370 | allowGroup = YET_ANOTHER_GROUP_ALLOWED_TO_EXECUTE |
| 2371 | ---- |
| 2372 | |
| 2373 | [[upload.allowGroup]]upload.allowGroup:: |
| 2374 | + |
| 2375 | Name of the groups of users that are allowed to execute 'upload-pack' |
| 2376 | on the server. One or more groups can be set. |
| 2377 | + |
| 2378 | If no groups are added, any user will be allowed to execute |
| 2379 | 'upload-pack' on the server. |
| 2380 | |
| 2381 | |
Shawn O. Pearce | 8efb2a7 | 2009-08-18 19:45:33 -0700 | [diff] [blame] | 2382 | [[user]] Section user |
Shawn O. Pearce | a758fef | 2009-08-19 08:29:32 -0700 | [diff] [blame] | 2383 | ~~~~~~~~~~~~~~~~~~~~~ |
Shawn O. Pearce | 0a35191 | 2009-06-01 08:14:46 -0700 | [diff] [blame] | 2384 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 2385 | [[user.name]]user.name:: |
Shawn O. Pearce | 0a35191 | 2009-06-01 08:14:46 -0700 | [diff] [blame] | 2386 | + |
| 2387 | Name that Gerrit calls itself in Git when it creates a new Git |
| 2388 | commit, such as a merge during change submission. |
| 2389 | + |
| 2390 | By default this is "Gerrit Code Review". |
| 2391 | |
Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 2392 | [[user.email]]user.email:: |
Shawn O. Pearce | 0a35191 | 2009-06-01 08:14:46 -0700 | [diff] [blame] | 2393 | + |
| 2394 | Email address that Gerrit refers to itself as when it creates a |
| 2395 | new Git commit, such as a merge commit during change submission. |
| 2396 | + |
| 2397 | If not set, Gerrit generates this as "gerrit@`hostname`", where |
| 2398 | `hostname` is the hostname of the system Gerrit is running on. |
| 2399 | + |
| 2400 | By default, not set, generating the value at startup. |
| 2401 | |
Edwin Kempin | 0e02ded | 2011-09-16 15:10:14 +0200 | [diff] [blame] | 2402 | [[user.anonymousCoward]]user.anonymousCoward:: |
| 2403 | + |
| 2404 | Username that this displayed in the Gerrit WebUI and in e-mail |
| 2405 | notifications if the full name of the user is not set. |
| 2406 | + |
| 2407 | By default "Anonymous Coward" is used. |
| 2408 | |
Shawn O. Pearce | 0bf2f52 | 2009-05-14 11:02:03 -0700 | [diff] [blame] | 2409 | |
Shawn O. Pearce | c5fed82 | 2009-11-17 16:10:10 -0800 | [diff] [blame] | 2410 | File `etc/secure.config` |
Remy Bohmer | 203eea3 | 2012-02-19 21:21:36 +0100 | [diff] [blame] | 2411 | ------------------------ |
Shawn O. Pearce | c5fed82 | 2009-11-17 16:10:10 -0800 | [diff] [blame] | 2412 | The optional file `'$site_path'/etc/secure.config` overrides (or |
| 2413 | supplements) the settings supplied by `'$site_path'/etc/gerrit.config`. |
Shawn O. Pearce | 0d4037a | 2009-11-12 18:33:46 -0800 | [diff] [blame] | 2414 | The file should be readable only by the daemon process and can be |
| 2415 | used to contain private configuration entries that wouldn't normally |
| 2416 | be exposed to everyone. |
| 2417 | |
Shawn O. Pearce | c5fed82 | 2009-11-17 16:10:10 -0800 | [diff] [blame] | 2418 | Sample `etc/secure.config`: |
Shawn O. Pearce | 0d4037a | 2009-11-12 18:33:46 -0800 | [diff] [blame] | 2419 | ---- |
Shawn O. Pearce | 34f38cf | 2011-06-16 19:18:54 -0700 | [diff] [blame] | 2420 | [auth] |
| 2421 | registerEmailPrivateKey = 2zHNrXE2bsoylzUqDxZp0H1cqUmjgWb6 |
| 2422 | |
Shawn O. Pearce | 0d4037a | 2009-11-12 18:33:46 -0800 | [diff] [blame] | 2423 | [database] |
Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 2424 | username = webuser |
| 2425 | password = s3kr3t |
Shawn O. Pearce | 0d4037a | 2009-11-12 18:33:46 -0800 | [diff] [blame] | 2426 | |
| 2427 | [ldap] |
Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 2428 | password = l3tm3srch |
Shawn O. Pearce | 0d4037a | 2009-11-12 18:33:46 -0800 | [diff] [blame] | 2429 | |
| 2430 | [httpd] |
Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 2431 | sslKeyPassword = g3rr1t |
Shawn O. Pearce | 0d4037a | 2009-11-12 18:33:46 -0800 | [diff] [blame] | 2432 | |
| 2433 | [sendemail] |
Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 2434 | smtpPass = sp@m |
Shawn O. Pearce | 7929d87 | 2011-05-15 13:33:15 -0700 | [diff] [blame] | 2435 | |
| 2436 | [remote "bar"] |
| 2437 | password = s3kr3t |
Shawn O. Pearce | 0d4037a | 2009-11-12 18:33:46 -0800 | [diff] [blame] | 2438 | ---- |
| 2439 | |
Johan Bjork | 3e5ee30 | 2012-01-27 17:59:54 +0100 | [diff] [blame] | 2440 | File `etc/peer_keys` |
| 2441 | -------------------- |
| 2442 | |
| 2443 | The optional file `'$site_path'/etc/peer_keys` controls who can |
| 2444 | login as the 'Gerrit Code Review' user, required for the link:cmd-suexec.html[suexec] |
| 2445 | command. |
| 2446 | |
| 2447 | The format is one Base-64 encoded public key per line. |
| 2448 | |
| 2449 | |
Shawn O. Pearce | 7b40571 | 2009-05-08 18:27:53 -0700 | [diff] [blame] | 2450 | Database system_config |
| 2451 | ---------------------- |
| 2452 | |
| 2453 | Several columns in the `system_config` table within the metadata |
| 2454 | database may be set to control how Gerrit behaves. |
Shawn O. Pearce | d2b73db | 2009-01-09 11:55:47 -0800 | [diff] [blame] | 2455 | |
| 2456 | [NOTE] |
| 2457 | The contents of the `system_config` table are cached at startup |
| 2458 | by Gerrit. If you modify any columns in this table, Gerrit needs |
| 2459 | to be restarted before it will use the new values. |
| 2460 | |
Shawn O. Pearce | 7b40571 | 2009-05-08 18:27:53 -0700 | [diff] [blame] | 2461 | Configurable Parameters |
| 2462 | ~~~~~~~~~~~~~~~~~~~~~~~ |
Shawn O. Pearce | d2b73db | 2009-01-09 11:55:47 -0800 | [diff] [blame] | 2463 | |
Shawn O. Pearce | 8e9c73b | 2009-05-08 17:38:25 -0700 | [diff] [blame] | 2464 | site_path:: |
| 2465 | + |
Shawn O. Pearce | d2b73db | 2009-01-09 11:55:47 -0800 | [diff] [blame] | 2466 | Local filesystem directory holding the site customization assets. |
| 2467 | Placing this directory under version control and/or backup is a |
| 2468 | good idea. |
Shawn O. Pearce | 8e9c73b | 2009-05-08 17:38:25 -0700 | [diff] [blame] | 2469 | + |
Shawn O. Pearce | c5fed82 | 2009-11-17 16:10:10 -0800 | [diff] [blame] | 2470 | Files in this directory provide additional configuration. |
Shawn O. Pearce | 8e9c73b | 2009-05-08 17:38:25 -0700 | [diff] [blame] | 2471 | + |
Shawn O. Pearce | d2b73db | 2009-01-09 11:55:47 -0800 | [diff] [blame] | 2472 | Other files support site customization. |
Shawn O. Pearce | 8e9c73b | 2009-05-08 17:38:25 -0700 | [diff] [blame] | 2473 | + |
Shawn O. Pearce | d2b73db | 2009-01-09 11:55:47 -0800 | [diff] [blame] | 2474 | * link:config-headerfooter.html[Site Header/Footer] |
| 2475 | |
Shawn O. Pearce | 5500e69 | 2009-05-28 15:55:01 -0700 | [diff] [blame] | 2476 | GERRIT |
| 2477 | ------ |
| 2478 | Part of link:index.html[Gerrit Code Review] |