| 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 | |
| Dave Borowitz | 45baa89 | 2012-02-23 16:43:05 -0800 | [diff] [blame] | 24 | [[accounts]]Section accounts |
| 25 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 26 | |
| Matthias Sohn | f336066 | 2012-04-05 15:42:52 +0200 | [diff] [blame] | 27 | [[accounts.visibility]]accounts.visibility:: |
| Dave Borowitz | 45baa89 | 2012-02-23 16:43:05 -0800 | [diff] [blame] | 28 | + |
| 29 | Controls visibility of other users' dashboard pages and |
| 30 | completion suggestions to web users. |
| 31 | + |
| 32 | If `ALL`, all users are visible to all other users, even |
| 33 | anonymous users. |
| 34 | + |
| 35 | If `SAME_GROUP`, only users who are also members of a group the |
| 36 | current user is a member of are visible. |
| 37 | + |
| 38 | If `VISIBLE_GROUP`, only users who are members of at least one group |
| 39 | that is visible to the current user are visible. |
| 40 | + |
| 41 | If `NONE`, no users other than the current user are visible. |
| 42 | + |
| 43 | Default is `ALL`. |
| 44 | |
| Edwin Kempin | 49cb3e1 | 2011-06-29 14:35:14 +0200 | [diff] [blame] | 45 | [[addreviewer]]Section addreviewer |
| 46 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 47 | |
| 48 | [[addreviewer.maxWithoutConfirmation]]addreviewer.maxWithoutConfirmation:: |
| 49 | + |
| 50 | The maximum number of reviewers a user can add at once by adding a |
| 51 | group as reviewer without being asked to confirm the operation. |
| 52 | + |
| 53 | If set to 0, the user will never be asked to confirm adding a group |
| 54 | as reviewer. |
| 55 | + |
| 56 | Default is 10. |
| Edwin Kempin | 5e65d9b | 2011-07-08 07:35:48 +0200 | [diff] [blame] | 57 | + |
| 58 | This setting only applies for adding reviewers in the Gerrit WebUI, |
| 59 | but is ignored when adding reviewers with the |
| Edwin Kempin | 33e92d0 | 2011-07-11 22:00:57 +0200 | [diff] [blame] | 60 | link:cmd-set-reviewers.html[set-reviewers] command. |
| Edwin Kempin | 49cb3e1 | 2011-06-29 14:35:14 +0200 | [diff] [blame] | 61 | |
| 62 | [[addreviewer.maxAllowed]]addreviewer.maxAllowed:: |
| 63 | + |
| 64 | The maximum number of reviewers a user can add at once by adding a |
| 65 | group as reviewer. |
| 66 | + |
| 67 | If set to 0, there is no limit for the number of reviewers that can |
| 68 | be added at once by adding a group as reviewer. |
| 69 | + |
| 70 | Default is 20. |
| 71 | |
| Shawn O. Pearce | 8efb2a7 | 2009-08-18 19:45:33 -0700 | [diff] [blame] | 72 | [[auth]]Section auth |
| 73 | ~~~~~~~~~~~~~~~~~~~~ |
| Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 74 | |
| 75 | See also link:config-sso.html[SSO configuration]. |
| 76 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 77 | [[auth.type]]auth.type:: |
| Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 78 | + |
| Shawn O. Pearce | 2920ef3 | 2009-08-03 08:03:34 -0700 | [diff] [blame] | 79 | Type of user authentication employed by Gerrit. The supported |
| 80 | values are: |
| Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 81 | + |
| 82 | * `OpenID` |
| 83 | + |
| 84 | The default setting. Gerrit uses any valid OpenID |
| 85 | provider chosen by the end-user. For more information see |
| Shawn O. Pearce | 2920ef3 | 2009-08-03 08:03:34 -0700 | [diff] [blame] | 86 | http://openid.net/[openid.net]. |
| Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 87 | + |
| James E. Blair | ca8bc3b | 2011-12-21 18:12:26 +0000 | [diff] [blame] | 88 | * `OpenID_SSO` |
| 89 | + |
| 90 | Supports OpenID from a single provider. There is no registration |
| 91 | link, and the "Sign In" link sends the user directly to the provider's |
| 92 | SSO entry point. |
| 93 | + |
| Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 94 | * `HTTP` |
| 95 | + |
| Shawn O. Pearce | 2920ef3 | 2009-08-03 08:03:34 -0700 | [diff] [blame] | 96 | Gerrit relies upon data presented in the HTTP request. This includes |
| Edwin Kempin | f1acbb8 | 2011-09-15 12:49:42 +0200 | [diff] [blame] | 97 | HTTP basic authentication, or some types of commercial single-sign-on |
| Shawn O. Pearce | 2920ef3 | 2009-08-03 08:03:34 -0700 | [diff] [blame] | 98 | solutions. With this setting enabled the authentication must |
| 99 | take place in the web server or servlet container, and not from |
| 100 | within Gerrit. |
| 101 | + |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 102 | * `HTTP_LDAP` |
| 103 | + |
| 104 | Exactly like `HTTP` (above), but additionally Gerrit pre-populates |
| 105 | a user's full name and email address based on information obtained |
| 106 | from the user's account object in LDAP. The user's group membership |
| 107 | is also pulled from LDAP, making any LDAP groups that a user is a |
| 108 | member of available as groups in Gerrit. |
| 109 | + |
| Sasa Zivkov | eabc897 | 2010-10-04 15:47:08 +0200 | [diff] [blame] | 110 | * `CLIENT_SSL_CERT_LDAP` |
| 111 | + |
| 112 | This authentication type is actually kind of SSO. Gerrit will configure |
| David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 113 | 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] | 114 | authentication to work a Gerrit administrator has to import the root |
| 115 | certificate of the trust chain used to issue the client's certificate |
| 116 | into the <review-site>/etc/keystore. |
| 117 | After the authentication is done Gerrit will obtain basic user |
| 118 | registration (name and email) from LDAP, and some group memberships. |
| 119 | Therefore, the "_LDAP" suffix in the name of this authentication type. |
| 120 | This authentication type can only be used under hosted daemon mode, and |
| 121 | the httpd.listenUrl must use https:// as the protocol. |
| Chulho Yang | b72ff8f | 2013-07-04 02:35:53 -0400 | [diff] [blame] | 122 | Optionally, certificate revocation list file can be used |
| 123 | at <review-site>/etc/crl.pem. For details, see httpd.sslCrl. |
| Sasa Zivkov | eabc897 | 2010-10-04 15:47:08 +0200 | [diff] [blame] | 124 | + |
| Shawn O. Pearce | f7e065e | 2009-09-26 20:01:10 -0700 | [diff] [blame] | 125 | * `LDAP` |
| 126 | + |
| 127 | Gerrit prompts the user to enter a username and a password, which |
| 128 | it then verifies by performing a simple bind against the configured |
| 129 | <<ldap.server,ldap.server>>. In this configuration the web server |
| 130 | is not involved in the user authentication process. |
| 131 | + |
| Shawn O. Pearce | c892d34 | 2010-02-17 17:00:50 -0800 | [diff] [blame] | 132 | The actual username used in the LDAP simple bind request is the |
| 133 | account's full DN, which is discovered by first querying the |
| 134 | directory using either an anonymous request, or the configured |
| Robin Rosenberg | a3baed0 | 2012-10-14 14:09:32 +0200 | [diff] [blame] | 135 | <<ldap.username,ldap.username>> identity. Gerrit can also use kerberos if |
| 136 | <<ldap.authentication,ldap.authentication>> is set to `GSSAPI`. |
| Shawn O. Pearce | c892d34 | 2010-02-17 17:00:50 -0800 | [diff] [blame] | 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 | + |
| David Pursehouse | 42f4204 | 2013-08-01 14:02:25 +0900 | [diff] [blame] | 145 | Unlike `LDAP` above, the username used to perform the LDAP simple bind |
| David Pursehouse | 1344f5b | 2013-08-09 17:35:47 +0900 | [diff] [blame] | 146 | request is the exact string supplied in the dialog by the user. |
| Robin Rosenberg | 524a303 | 2012-10-14 14:24:36 +0200 | [diff] [blame] | 147 | The configured <<ldap.username,ldap.username>> identity is not used to obtain |
| Shawn O. Pearce | c892d34 | 2010-02-17 17:00:50 -0800 | [diff] [blame] | 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 | 42f4204 | 2013-08-01 14:02:25 +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 |
| David Pursehouse | 42f4204 | 2013-08-01 14:02:25 +0900 | [diff] [blame] | 183 | set to `OpenID` (the default). |
| Shawn O. Pearce | d7c026d | 2009-08-05 20:11:22 -0700 | [diff] [blame] | 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 | |
| Mike Gouline | d2ab0cd | 2012-12-18 11:20:53 +1100 | [diff] [blame] | 198 | [[auth.openIdDomain]]auth.openIdDomain:: |
| 199 | + |
| 200 | List of allowed OpenID email address domains. Only used if |
| David Pursehouse | 42f4204 | 2013-08-01 14:02:25 +0900 | [diff] [blame] | 201 | `auth.type` is set to `OPENID` or `OPENID_SSO`. |
| Mike Gouline | d2ab0cd | 2012-12-18 11:20:53 +1100 | [diff] [blame] | 202 | + |
| 203 | Domain is case insensitive and must be in the same form as it |
| 204 | appears in the email address, for example, "example.com". |
| 205 | + |
| 206 | By default, any domain is accepted. |
| 207 | |
| Shawn O. Pearce | 89030bc | 2010-04-24 17:25:29 -0700 | [diff] [blame] | 208 | [[auth.maxOpenIdSessionAge]]auth.maxOpenIdSessionAge:: |
| 209 | + |
| 210 | Time in seconds before an OpenID provider must force the user |
| 211 | to authenticate themselves again before authentication to this |
| 212 | Gerrit server. Currently this is only a polite request, and users |
| 213 | coming from providers that don't support the PAPE extension will |
| 214 | be accepted anyway. In the future it may be enforced, rejecting |
| 215 | users coming from providers that don't honor the max session age. |
| 216 | + |
| 217 | If set to 0, the provider will always force the user to authenticate |
| 218 | (e.g. supply their password). Values should use common unit suffixes |
| 219 | to express their setting: |
| 220 | + |
| 221 | * s, sec, second, seconds |
| 222 | * m, min, minute, minutes |
| 223 | * h, hr, hour, hours |
| 224 | * d, day, days |
| 225 | * w, week, weeks (`1 week` is treated as `7 days`) |
| 226 | * mon, month, months (`1 month` is treated as `30 days`) |
| 227 | * y, year, years (`1 year` is treated as `365 days`) |
| 228 | |
| 229 | + |
| 230 | Default is -1, permitting infinite time between authentications. |
| 231 | |
| Shawn O. Pearce | 34f38cf | 2011-06-16 19:18:54 -0700 | [diff] [blame] | 232 | [[auth.maxRegisterEmailTokenAge]]auth.maxRegisterEmailTokenAge:: |
| 233 | + |
| 234 | Time in seconds before an email verification token sent to a user in |
| 235 | order to validate their email address expires. |
| 236 | + |
| 237 | * s, sec, second, seconds |
| 238 | * m, min, minute, minutes |
| 239 | * h, hr, hour, hours |
| 240 | * d, day, days |
| 241 | * w, week, weeks (`1 week` is treated as `7 days`) |
| 242 | * mon, month, months (`1 month` is treated as `30 days`) |
| 243 | * y, year, years (`1 year` is treated as `365 days`) |
| 244 | |
| 245 | + |
| Shawn O. Pearce | d6bd00b | 2012-01-20 12:40:51 -0800 | [diff] [blame] | 246 | Default is 12 hours. |
| Shawn O. Pearce | 34f38cf | 2011-06-16 19:18:54 -0700 | [diff] [blame] | 247 | |
| James E. Blair | ca8bc3b | 2011-12-21 18:12:26 +0000 | [diff] [blame] | 248 | [[auth.openIdSsoUrl]]auth.openIdSsoUrl:: |
| 249 | + |
| David Pursehouse | 42f4204 | 2013-08-01 14:02:25 +0900 | [diff] [blame] | 250 | The SSO entry point URL. Only used if `auth.type` is set to |
| 251 | `OpenID_SSO`. |
| James E. Blair | ca8bc3b | 2011-12-21 18:12:26 +0000 | [diff] [blame] | 252 | + |
| 253 | The "Sign In" link will send users directly to this URL. |
| 254 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 255 | [[auth.httpHeader]]auth.httpHeader:: |
| Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 256 | + |
| 257 | HTTP header to trust the username from, or unset to select HTTP basic |
| David Pursehouse | 42f4204 | 2013-08-01 14:02:25 +0900 | [diff] [blame] | 258 | 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] | 259 | |
| Luca Milanesio | 384ed6c | 2013-07-30 09:10:07 +0100 | [diff] [blame] | 260 | [[auth.httpDisplaynameHeader]]auth.httpDisplaynameHeader:: |
| 261 | + |
| 262 | HTTP header to retrieve the user's display name from. Only used if `auth.type` |
| 263 | is set to `HTTP`. |
| 264 | + |
| 265 | If set, Gerrit trusts and enforces the user's full name using the HTTP header |
| 266 | and disables the ability to manually modify the user's full name |
| 267 | from the contact information page. |
| 268 | |
| 269 | [[auth.httpEmailHeader]]auth.httpEmailHeader:: |
| 270 | + |
| 271 | HTTP header to retrieve the user's e-mail from. Only used if `auth.type` |
| 272 | is set to `HTTP`. |
| 273 | + |
| 274 | If set, Gerrit trusts and enforces the user's e-mail using the HTTP header |
| 275 | and disables the ability to manually modify or register other e-mails |
| 276 | from the contact information page. |
| 277 | |
| Luca Milanesio | 5185b04 | 2013-07-27 22:03:06 +0100 | [diff] [blame] | 278 | [[auth.loginUrl]]auth.loginUrl:: |
| 279 | + |
| 280 | URL to redirect a browser to after the end-user has clicked on the |
| David Pursehouse | 42f4204 | 2013-08-01 14:02:25 +0900 | [diff] [blame] | 281 | login link in the upper right corner. Only used if `auth.type` is set |
| 282 | to `HTTP` or `HTTP_LDAP`. |
| Luca Milanesio | 5185b04 | 2013-07-27 22:03:06 +0100 | [diff] [blame] | 283 | Organizations using an enterprise single-sign-on solution may want to |
| 284 | redirect the browser to the SSO product's sign-in page for completing the |
| 285 | login process and validate their credentials. |
| 286 | + |
| David Pursehouse | 42f4204 | 2013-08-01 14:02:25 +0900 | [diff] [blame] | 287 | If set, Gerrit allows anonymous access until the end-user performs the login |
| 288 | and provides a trusted identity through the HTTP header. |
| Luca Milanesio | 5185b04 | 2013-07-27 22:03:06 +0100 | [diff] [blame] | 289 | If not set, Gerrit requires the HTTP header with a trusted identity |
| David Pursehouse | 42f4204 | 2013-08-01 14:02:25 +0900 | [diff] [blame] | 290 | and returns the error page 'LoginRedirect.html' if such a header is not |
| 291 | present. |
| Luca Milanesio | 5185b04 | 2013-07-27 22:03:06 +0100 | [diff] [blame] | 292 | |
| 293 | [[auth.loginText]]auth.loginText:: |
| 294 | + |
| David Pursehouse | 42f4204 | 2013-08-01 14:02:25 +0900 | [diff] [blame] | 295 | Text displayed in the loginUrl link. Only used if `auth.loginUrl` is set. |
| Luca Milanesio | 5185b04 | 2013-07-27 22:03:06 +0100 | [diff] [blame] | 296 | + |
| David Pursehouse | 42f4204 | 2013-08-01 14:02:25 +0900 | [diff] [blame] | 297 | If not set, the "Sign In" text is used. |
| Luca Milanesio | 5185b04 | 2013-07-27 22:03:06 +0100 | [diff] [blame] | 298 | |
| Luca Milanesio | 111e0b7 | 2013-08-15 18:56:42 +0100 | [diff] [blame] | 299 | [[auth.registerPageUrl]]auth.registerPageUrl:: |
| 300 | + |
| David Pursehouse | 268744b | 2013-08-17 15:32:11 +0900 | [diff] [blame] | 301 | URL of the registration page to use when a new user logs in to Gerrit for |
| 302 | the first time. Used only when `auth.type` is set to `HTTP`. |
| Luca Milanesio | 111e0b7 | 2013-08-15 18:56:42 +0100 | [diff] [blame] | 303 | + |
| 304 | If not set, the standard Gerrit registration page `/#/register/` is displayed. |
| 305 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 306 | [[auth.logoutUrl]]auth.logoutUrl:: |
| Shawn O. Pearce | 12b5d84 | 2009-08-15 15:11:10 -0700 | [diff] [blame] | 307 | + |
| 308 | URL to redirect a browser to after the end-user has clicked on the |
| 309 | "Sign Out" link in the upper right corner. Organizations using an |
| 310 | enterprise single-sign-on solution may want to redirect the browser |
| 311 | to the SSO product's sign-out page. |
| 312 | + |
| 313 | If not set, the redirect returns to the list of all open changes. |
| 314 | |
| Shawn O. Pearce | c9d26b5 | 2009-12-16 08:05:27 -0800 | [diff] [blame] | 315 | [[auth.registerUrl]]auth.registerUrl:: |
| 316 | + |
| 317 | Target for the "Register" link in the upper right corner. Used only |
| David Pursehouse | 42f4204 | 2013-08-01 14:02:25 +0900 | [diff] [blame] | 318 | when `auth.type` is `LDAP`. |
| Shawn O. Pearce | c9d26b5 | 2009-12-16 08:05:27 -0800 | [diff] [blame] | 319 | + |
| 320 | If not set, no "Register" link is displayed. |
| 321 | |
| Chad Horohoe | 6589708 | 2012-11-10 10:26:25 -0800 | [diff] [blame] | 322 | [[auth.registerText]]auth.registerText:: |
| 323 | + |
| 324 | Text for the "Register" link in the upper right corner. Used only |
| David Pursehouse | 42f4204 | 2013-08-01 14:02:25 +0900 | [diff] [blame] | 325 | when `auth.type` is `LDAP`. |
| Chad Horohoe | 6589708 | 2012-11-10 10:26:25 -0800 | [diff] [blame] | 326 | + |
| 327 | If not set, defaults to "Register". |
| 328 | |
| David Pursehouse | 3d60449 | 2013-01-25 17:41:53 +0900 | [diff] [blame] | 329 | [[auth.editFullNameUrl]]auth.editFullNameUrl:: |
| 330 | + |
| 331 | Target for the "Edit" button when the user is allowed to edit their |
| 332 | full name. |
| 333 | |
| 334 | [[auth.httpPasswordUrl]]auth.httpPasswordUrl:: |
| 335 | + |
| David Pursehouse | 42f4204 | 2013-08-01 14:02:25 +0900 | [diff] [blame] | 336 | Target for the "Obtain Password" link. Used only when `auth.type` is |
| David Pursehouse | 3d60449 | 2013-01-25 17:41:53 +0900 | [diff] [blame] | 337 | `LDAP`, `LDAP_BIND` or `CUSTOM_EXTENSION`. |
| Shawn Pearce | e0cafe4 | 2013-08-29 23:28:13 -0700 | [diff] [blame] | 338 | |
| 339 | [[auth.switchAccountUrl]]auth.switchAccountUrl:: |
| David Pursehouse | 3d60449 | 2013-01-25 17:41:53 +0900 | [diff] [blame] | 340 | + |
| Shawn Pearce | e0cafe4 | 2013-08-29 23:28:13 -0700 | [diff] [blame] | 341 | URL to switch user identities and login as a different account than |
| 342 | the currently active account. This is disabled by default except when |
| 343 | `auth.type` is `OPENID` and `DEVELOPMENT_BECOME_ANY_ACCOUNT`. If set |
| 344 | the "Switch Account" link is displayed next to "Sign Out". |
| 345 | + |
| 346 | When `auth.type` does not normally enable this URL administrators may |
| 347 | set this to `login/` or `$canonicalWebUrl/login`, allowing users to |
| 348 | begin a new web session. |
| David Pursehouse | 3d60449 | 2013-01-25 17:41:53 +0900 | [diff] [blame] | 349 | |
| Piotr Sikora | 7cec2f8 | 2011-02-26 12:57:30 +0000 | [diff] [blame] | 350 | [[auth.cookiePath]]auth.cookiePath:: |
| 351 | + |
| 352 | Sets "path" attribute of the authentication cookie. |
| 353 | + |
| 354 | If not set, HTTP request's path is used. |
| 355 | |
| 356 | [[auth.cookieSecure]]auth.cookieSecure:: |
| 357 | + |
| 358 | Sets "secure" flag of the authentication cookie. If true, cookies |
| 359 | will be transmitted only over HTTPS protocol. |
| 360 | + |
| 361 | By default, false. |
| 362 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 363 | [[auth.emailFormat]]auth.emailFormat:: |
| Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 364 | + |
| 365 | Optional format string to construct user email addresses out of |
| David Pursehouse | 42f4204 | 2013-08-01 14:02:25 +0900 | [diff] [blame] | 366 | user login names. Only used if `auth.type` is `HTTP`, `HTTP_LDAP` |
| Shawn O. Pearce | f7e065e | 2009-09-26 20:01:10 -0700 | [diff] [blame] | 367 | or `LDAP`. |
| Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 368 | + |
| Shawn O. Pearce | 44221bf | 2011-06-27 10:37:30 -0700 | [diff] [blame] | 369 | 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] | 370 | with the login name. E.g. "\{0\}+gerrit@example.com" with a user |
| 371 | login name of "foo" will produce "foo+gerrit@example.com" during |
| 372 | the first time user "foo" registers. |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 373 | + |
| Shawn O. Pearce | f7e065e | 2009-09-26 20:01:10 -0700 | [diff] [blame] | 374 | If the site is using `HTTP_LDAP` or `LDAP`, using this option is |
| 375 | discouraged. Setting `ldap.accountEmailAddress` and importing the |
| 376 | email address from the LDAP directory is generally preferred. |
| Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 377 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 378 | [[auth.contributorAgreements]]auth.contributorAgreements:: |
| Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 379 | + |
| 380 | Controls whether or not the contributor agreement features are |
| 381 | enabled for the Gerrit site. If enabled a user must complete a |
| 382 | contributor agreement before they can upload changes. |
| 383 | + |
| Marc Petit-Huguenin | bbb8549 | 2012-12-03 11:11:00 -0800 | [diff] [blame] | 384 | If enabled, the admin must also add one or more |
| 385 | link:config-cla.html[contributor-agreement sections] |
| 386 | in project.config and create agreement files under |
| Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 387 | `'$site_path'/static`, so users can actually complete one or |
| Grzegorz Kossakowski | 28e4e1b | 2009-09-23 11:33:34 -0700 | [diff] [blame] | 388 | more agreements. |
| Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 389 | + |
| 390 | By default this is false (no agreements are used). |
| Fredrik Luthander | a3cf354 | 2012-07-04 16:55:35 -0700 | [diff] [blame] | 391 | + |
| 392 | To enable the actual usage of contributor agreement the project |
| 393 | specific config option in the `project.config` must be set: |
| 394 | link:config-project-config.html[receive.requireContributorAgreement]. |
| Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 395 | |
| Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 396 | auth.allowGoogleAccountUpgrade:: |
| 397 | + |
| Shawn O. Pearce | 48eea07 | 2009-08-31 10:53:12 -0700 | [diff] [blame] | 398 | Allows Google Account users to automatically update their Gerrit |
| 399 | account when/if their Google Account OpenID identity token changes. |
| 400 | Identity tokens can change if the server changes hostnames, or |
| 401 | for other reasons known only to Google. The upgrade path works |
| 402 | by matching users by email address if the identity is not present, |
| 403 | and then changing the identity. |
| Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 404 | + |
| Shawn O. Pearce | 48eea07 | 2009-08-31 10:53:12 -0700 | [diff] [blame] | 405 | This setting also permits old Gerrit 1.x users to seamlessly upgrade |
| 406 | from Google Accounts on Google App Engine to OpenID authentication. |
| Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 407 | + |
| Shawn O. Pearce | 48eea07 | 2009-08-31 10:53:12 -0700 | [diff] [blame] | 408 | Having this enabled incurs an extra database query when Google |
| Shawn O. Pearce | e31d02c | 2009-12-08 12:21:37 -0800 | [diff] [blame] | 409 | Account users register with the Gerrit server. |
| Shawn O. Pearce | 0d3ecff | 2009-06-01 08:34:17 -0700 | [diff] [blame] | 410 | + |
| 411 | By default, unset/false. |
| 412 | |
| Christian Halstrick | a3d88a5 | 2011-08-31 09:21:41 +0200 | [diff] [blame] | 413 | [[auth.trustContainerAuth]]auth.trustContainerAuth:: |
| 414 | + |
| 415 | If true then it is the responsibility of the container hosting |
| 416 | Gerrit to authenticate users. In this case Gerrit will blindly trust |
| 417 | the container. |
| 418 | + |
| 419 | This parameter only affects git over http traffic. If set to false |
| 420 | then Gerrit will do the authentication (using DIGEST authentication). |
| 421 | + |
| 422 | By default this is set to false. |
| 423 | |
| Luca Milanesio | 4205884 | 2012-01-05 21:25:38 +0000 | [diff] [blame] | 424 | [[auth.gitBasicAuth]]auth.gitBasicAuth:: |
| 425 | + |
| 426 | If true then Git over HTTP and HTTP/S traffic is authenticated using |
| 427 | standard BasicAuth and credentials validated using the same auth |
| 428 | method configured for Gerrit Web UI. |
| 429 | + |
| 430 | This parameter only affects git over http traffic. If set to false |
| 431 | then Gerrit will authenticate through DIGEST authentication and |
| 432 | the randomly generated HTTP password in Gerrit DB. |
| 433 | + |
| 434 | By default this is set to false. |
| 435 | |
| Edwin Kempin | 4b9e5e7 | 2011-09-22 15:06:14 +0200 | [diff] [blame] | 436 | [[auth.userNameToLowerCase]]auth.userNameToLowerCase:: |
| 437 | + |
| 438 | If set the username that is received to authenticate a git operation |
| 439 | is converted to lower case for looking up the user account in Gerrit. |
| 440 | + |
| 441 | By setting this parameter a case insensitive authentication for the |
| 442 | git operations can be achieved, if it is ensured that the usernames in |
| 443 | Gerrit (scheme `username`) are stored in lower case (e.g. if the |
| 444 | parameter link:#ldap.accountSshUserName[ldap.accountSshUserName] is |
| 445 | set to `${sAMAccountName.toLowerCase}`). It is important that for all |
| 446 | existing accounts this username is already in lower case. It is not |
| 447 | possible to convert the usernames of the existing accounts to lower |
| 448 | case because this would break the access to existing per-user |
| 449 | branches. |
| 450 | + |
| 451 | This parameter only affects git over http and git over SSH traffic. |
| 452 | + |
| 453 | By default this is set to false. |
| 454 | |
| Shawn Pearce | a931fe1 | 2013-06-11 12:29:17 -0700 | [diff] [blame] | 455 | [[auth.enableRunAs]]auth.enableRunAs:: |
| 456 | + |
| 457 | If true HTTP REST APIs will accept the `X-Gerrit-RunAs` HTTP request |
| 458 | header from any users granted the link:access-control.html#capability_runAs[Run As] |
| 459 | capability. The header and capability permit the authenticated user |
| 460 | to impersonate another account. |
| 461 | + |
| 462 | If false the feature is disabled and cannot be re-enabled without |
| 463 | editing gerrit.config and restarting the server. |
| 464 | + |
| 465 | Default is true. |
| 466 | |
| Shawn O. Pearce | 8efb2a7 | 2009-08-18 19:45:33 -0700 | [diff] [blame] | 467 | [[cache]]Section cache |
| 468 | ~~~~~~~~~~~~~~~~~~~~~~ |
| Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 469 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 470 | [[cache.directory]]cache.directory:: |
| Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 471 | + |
| 472 | 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] | 473 | future lookup. This local disk cache is used to retain potentially |
| 474 | expensive to compute information across restarts. If the location |
| 475 | does not exist, Gerrit will try to create it. |
| Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 476 | + |
| Shawn O. Pearce | 4b21228 | 2009-08-05 19:45:56 -0700 | [diff] [blame] | 477 | If not absolute, the path is resolved relative to `$site_path`. |
| Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 478 | + |
| Shawn O. Pearce | 4b21228 | 2009-08-05 19:45:56 -0700 | [diff] [blame] | 479 | Default is unset, no disk cache. |
| Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 480 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 481 | [[cache.name.maxAge]]cache.<name>.maxAge:: |
| Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 482 | + |
| Shawn O. Pearce | 2e1cb2b | 2012-05-24 14:28:40 -0700 | [diff] [blame] | 483 | Maximum age to keep an entry in the cache. Entries are removed from |
| 484 | the cache and refreshed from source data every maxAge interval. |
| Shawn O. Pearce | d9c403e | 2009-08-19 08:35:41 -0700 | [diff] [blame] | 485 | Values should use common unit suffixes to express their setting: |
| Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 486 | + |
| Shawn O. Pearce | d9c403e | 2009-08-19 08:35:41 -0700 | [diff] [blame] | 487 | * s, sec, second, seconds |
| 488 | * m, min, minute, minutes |
| 489 | * h, hr, hour, hours |
| 490 | * d, day, days |
| 491 | * w, week, weeks (`1 week` is treated as `7 days`) |
| 492 | * mon, month, months (`1 month` is treated as `30 days`) |
| 493 | * y, year, years (`1 year` is treated as `365 days`) |
| 494 | |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 495 | + |
| Edwin Kempin | abcd504 | 2013-03-12 16:04:37 +0100 | [diff] [blame] | 496 | If a unit suffix is not specified, `seconds` is assumed. If 0 is |
| Shawn O. Pearce | 3fdbf39 | 2009-09-04 18:08:26 -0700 | [diff] [blame] | 497 | supplied, the maximum age is infinite and items are never purged |
| 498 | except when the cache is full. |
| Shawn O. Pearce | d9c403e | 2009-08-19 08:35:41 -0700 | [diff] [blame] | 499 | + |
| Shawn O. Pearce | 2e1cb2b | 2012-05-24 14:28:40 -0700 | [diff] [blame] | 500 | Default is `0`, meaning store forever with no expire, except: |
| Shawn O. Pearce | d9c403e | 2009-08-19 08:35:41 -0700 | [diff] [blame] | 501 | + |
| Shawn O. Pearce | 05687e9 | 2011-04-04 17:29:03 -0400 | [diff] [blame] | 502 | * `"adv_bases"`: default is `10 minutes` |
| Shawn O. Pearce | d9c403e | 2009-08-19 08:35:41 -0700 | [diff] [blame] | 503 | * `"ldap_groups"`: default is `1 hour` |
| Shawn O. Pearce | d9c403e | 2009-08-19 08:35:41 -0700 | [diff] [blame] | 504 | * `"web_sessions"`: default is `12 hours` |
| Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 505 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 506 | [[cache.name.memoryLimit]]cache.<name>.memoryLimit:: |
| Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 507 | + |
| Shawn O. Pearce | 2e1cb2b | 2012-05-24 14:28:40 -0700 | [diff] [blame] | 508 | The total cost of entries to retain in memory. The cost computation |
| 509 | varies by the cache. For most caches where the in-memory size of each |
| 510 | entry is relatively the same, memoryLimit is currently defined to be |
| 511 | the number of entries held by the cache (each entry costs 1). |
| 512 | + |
| 513 | For caches where the size of an entry can vary significantly between |
| 514 | individual entries (notably `"diff"`, `"diff_intraline"`), memoryLimit |
| 515 | is an approximation of the total number of bytes stored by the cache. |
| 516 | Larger entries that represent bigger patch sets or longer source files |
| 517 | will consume a bigger portion of the memoryLimit. For these caches the |
| 518 | memoryLimit should be set to roughly the amount of RAM (in bytes) the |
| 519 | administrator can dedicate to the cache. |
| Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 520 | + |
| Shawn O. Pearce | efaf979 | 2009-09-02 18:12:52 -0700 | [diff] [blame] | 521 | Default is 1024 for most caches, except: |
| 522 | + |
| Shawn O. Pearce | 05687e9 | 2011-04-04 17:29:03 -0400 | [diff] [blame] | 523 | * `"adv_bases"`: default is `4096` |
| Shawn O. Pearce | 2e1cb2b | 2012-05-24 14:28:40 -0700 | [diff] [blame] | 524 | * `"diff"`: default is `10m` (10 MiB of memory) |
| 525 | * `"diff_intraline"`: default is `10m` (10 MiB of memory) |
| 526 | * `"plugin_resources"`: default is 2m (2 MiB of memory) |
| 527 | |
| 528 | + |
| 529 | If set to 0 the cache is disabled. Entries are removed immediately |
| 530 | 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] | 531 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 532 | [[cache.name.diskLimit]]cache.<name>.diskLimit:: |
| Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 533 | + |
| Shawn O. Pearce | 2e1cb2b | 2012-05-24 14:28:40 -0700 | [diff] [blame] | 534 | Total size in bytes of the keys and values stored on disk. Caches that |
| 535 | have grown bigger than this size are scanned daily at 1 AM local |
| 536 | server time to trim the cache. Entries are removed in least recently |
| 537 | accessed order until the cache fits within this limit. Caches may |
| 538 | grow larger than this during the day, as the size check is only |
| 539 | performed once every 24 hours. |
| Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 540 | + |
| Shawn O. Pearce | 2e1cb2b | 2012-05-24 14:28:40 -0700 | [diff] [blame] | 541 | Default is 128 MiB per cache. |
| Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 542 | + |
| Shawn O. Pearce | 2e1cb2b | 2012-05-24 14:28:40 -0700 | [diff] [blame] | 543 | If 0, disk storage for the cache is disabled. |
| Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 544 | |
| Shawn O. Pearce | 8efb2a7 | 2009-08-18 19:45:33 -0700 | [diff] [blame] | 545 | [[cache_names]]Standard Caches |
| Shawn O. Pearce | 4016a93 | 2009-05-28 15:12:40 -0700 | [diff] [blame] | 546 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
| Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 547 | |
| Shawn O. Pearce | 4a45271 | 2009-05-28 20:12:33 -0700 | [diff] [blame] | 548 | cache `"accounts"`:: |
| 549 | + |
| Shawn O. Pearce | 4dba988 | 2009-08-05 19:55:15 -0700 | [diff] [blame] | 550 | Cache entries contain important details of an active user, including |
| 551 | their display name, preferences, known email addresses, and group |
| 552 | memberships. Entry information is obtained from the following |
| 553 | database tables: |
| 554 | + |
| 555 | * `accounts` |
| 556 | + |
| 557 | * `account_group_members` |
| 558 | + |
| 559 | * `account_external_ids` |
| 560 | |
| 561 | + |
| 562 | If direct updates are made to any of these database tables, this |
| 563 | cache should be flushed. |
| 564 | |
| 565 | cache `"accounts_byemail"`:: |
| 566 | + |
| 567 | Caches account identities keyed by email address, which is scanned |
| 568 | from the `account_external_ids` database table. If updates are |
| 569 | made to this table, this cache should be flushed. |
| Shawn O. Pearce | 4a45271 | 2009-05-28 20:12:33 -0700 | [diff] [blame] | 570 | |
| Shawn O. Pearce | 05687e9 | 2011-04-04 17:29:03 -0400 | [diff] [blame] | 571 | cache `"adv_bases"`:: |
| 572 | + |
| 573 | Used only for push over smart HTTP when branch level access controls |
| David Pursehouse | 9246356 | 2013-06-24 10:16:28 +0900 | [diff] [blame] | 574 | are enabled. The cache entry contains all commits that are available |
| Shawn O. Pearce | 05687e9 | 2011-04-04 17:29:03 -0400 | [diff] [blame] | 575 | for the client to use as potential delta bases. Push over smart HTTP |
| 576 | requires two HTTP requests, and this cache tries to carry state from |
| 577 | the first request into the second to ensure it can complete. |
| 578 | |
| Gustaf Lundh | 47ce4e3 | 2012-05-21 11:18:42 +0200 | [diff] [blame] | 579 | cache `"changes"`:: |
| 580 | + |
| Gustaf Lundh | 3353c36 | 2013-04-24 17:25:39 +0200 | [diff] [blame] | 581 | The size of `memoryLimit` determines the number of projects for which |
| 582 | all changes will be cached. If the cache is set to 1024, this means all |
| 583 | changes for up to 1024 projects can be held in the cache. |
| Gustaf Lundh | 5349377 | 2012-11-18 18:41:15 -0800 | [diff] [blame] | 584 | + |
| Gustaf Lundh | 3353c36 | 2013-04-24 17:25:39 +0200 | [diff] [blame] | 585 | Default value is 0 (disabled). It is disabled by default due to the fact |
| 586 | that change updates are not communicated between Gerrit servers. Hence |
| 587 | this cache should be disabled in an multi-master/multi-slave setup. |
| Gustaf Lundh | 5349377 | 2012-11-18 18:41:15 -0800 | [diff] [blame] | 588 | + |
| 589 | The cache should be flushed whenever the database changes table is modified |
| Matt Baker | 8ce12fc | 2013-11-26 21:43:12 -0700 | [diff] [blame] | 590 | outside of Gerrit. |
| Gustaf Lundh | 47ce4e3 | 2012-05-21 11:18:42 +0200 | [diff] [blame] | 591 | |
| Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 592 | cache `"diff"`:: |
| 593 | + |
| Shawn O. Pearce | efaf979 | 2009-09-02 18:12:52 -0700 | [diff] [blame] | 594 | Each item caches the differences between two commits, at both the |
| 595 | directory and file levels. Gerrit uses this cache to accelerate |
| 596 | the display of affected file names, as well as file contents. |
| Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 597 | + |
| Shawn O. Pearce | 2e1cb2b | 2012-05-24 14:28:40 -0700 | [diff] [blame] | 598 | Entries in this cache are relatively large, so memoryLimit is an |
| 599 | estimate in bytes of memory used. Administrators should try to target |
| 600 | cache.diff.memoryLimit to fit all changes users will view in a 1 or 2 |
| 601 | day span. |
| Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 602 | |
| Shawn O. Pearce | f0cfe53 | 2011-04-11 23:40:06 -0400 | [diff] [blame] | 603 | cache `"diff_intraline"`:: |
| 604 | + |
| 605 | Each item caches the intraline difference of one file, when compared |
| 606 | between two commits. Gerrit uses this cache to accelerate display of |
| 607 | intraline differences when viewing a file. |
| 608 | + |
| Shawn O. Pearce | 2e1cb2b | 2012-05-24 14:28:40 -0700 | [diff] [blame] | 609 | Entries in this cache are relatively large, so memoryLimit is an |
| 610 | estimate in bytes of memory used. Administrators should try to target |
| 611 | cache.diff.memoryLimit to fit all files users will view in a 1 or 2 |
| 612 | day span. |
| Shawn O. Pearce | f0cfe53 | 2011-04-11 23:40:06 -0400 | [diff] [blame] | 613 | |
| Shawn O. Pearce | 2d65d29 | 2011-06-24 08:12:02 -0700 | [diff] [blame] | 614 | cache `"git_tags"`:: |
| 615 | + |
| 616 | If branch or reference level READ access controls are used, this |
| 617 | cache tracks which tags are reachable from the branch tips of a |
| 618 | repository. Gerrit uses this information to determine the set |
| 619 | of tags that a client may access, derived from which tags are |
| 620 | part of the history of a visible branch. |
| 621 | + |
| 622 | The cache is persisted to disk across server restarts as it can |
| 623 | be expensive to compute (60 or more seconds for a large history |
| 624 | like the Linux kernel repository). |
| 625 | |
| Shawn O. Pearce | 4a45271 | 2009-05-28 20:12:33 -0700 | [diff] [blame] | 626 | cache `"groups"`:: |
| 627 | + |
| Shawn O. Pearce | 4dba988 | 2009-08-05 19:55:15 -0700 | [diff] [blame] | 628 | Caches the basic group information from the `account_groups` table, |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 629 | including the group owner, name, and description. |
| 630 | + |
| 631 | Gerrit group membership obtained from the `account_group_members` |
| 632 | table is cached under the `"accounts"` cache, above. External group |
| 633 | membership obtained from LDAP is cached under `"ldap_groups"`. |
| 634 | |
| Matt Fischer | 620255a | 2011-03-22 14:28:23 -0500 | [diff] [blame] | 635 | cache `"groups_byinclude"`:: |
| 636 | + |
| 637 | Caches group inclusions in other groups. If direct updates are made |
| 638 | to the `account_group_includes` table, this cache should be flushed. |
| 639 | |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 640 | cache `"ldap_groups"`:: |
| 641 | + |
| 642 | Caches the LDAP groups that a user belongs to, if LDAP has been |
| 643 | configured on this server. This cache should be configured with a |
| 644 | low maxAge setting, to ensure LDAP modifications are picked up in |
| 645 | a timely fashion. |
| Shawn O. Pearce | 4a45271 | 2009-05-28 20:12:33 -0700 | [diff] [blame] | 646 | |
| Gustaf Lundh | 0919a49 | 2012-10-19 15:29:23 +0200 | [diff] [blame] | 647 | cache `"ldap_groups_byinclude"`:: |
| 648 | + |
| 649 | Caches the hierarchical structure of LDAP groups. |
| 650 | |
| Shawn O. Pearce | 6d26f4a | 2009-08-24 15:43:52 -0700 | [diff] [blame] | 651 | cache `"ldap_usernames"`:: |
| 652 | + |
| 653 | Caches a mapping of LDAP username to Gerrit account identity. The |
| 654 | cache automatically updates when a user first creates their account |
| 655 | within Gerrit, so the cache expire time is largely irrelevant. |
| 656 | |
| Shawn O. Pearce | 0c1abdb | 2011-06-24 11:01:25 -0700 | [diff] [blame] | 657 | cache `"permission_sort"`:: |
| 658 | + |
| David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 659 | 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] | 660 | reference. Sorting the sections can be expensive when regular |
| 661 | expressions are used, so this cache remembers the ordering for |
| 662 | each branch. |
| 663 | |
| Shawn O. Pearce | 2e1cb2b | 2012-05-24 14:28:40 -0700 | [diff] [blame] | 664 | cache `"plugin_resources"`:: |
| 665 | + |
| 666 | Caches formatted plugin resources, such as plugin documentation that |
| 667 | has been converted from Markdown to HTML. The memoryLimit refers to |
| 668 | the bytes of memory dedicated to storing the documentation. |
| 669 | |
| Shawn O. Pearce | 4a45271 | 2009-05-28 20:12:33 -0700 | [diff] [blame] | 670 | cache `"projects"`:: |
| 671 | + |
| 672 | Caches the project description records, from the `projects` table |
| 673 | in the database. If a project record is updated or deleted, this |
| 674 | cache should be flushed. Newly inserted projects do not require |
| 675 | a cache flush, as they will be read upon first reference. |
| 676 | |
| Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 677 | cache `"sshkeys"`:: |
| 678 | + |
| 679 | Caches unpacked versions of user SSH keys, so the internal SSH daemon |
| 680 | can match against them during authentication. The unit of storage |
| 681 | is per-user, so 1024 items translates to 1024 unique user accounts. |
| 682 | As each individual user account may configure multiple SSH keys, |
| 683 | 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] | 684 | + |
| 685 | This cache is based off the `account_ssh_keys` table and the |
| 686 | `accounts.ssh_user_name` column in the database. If either is |
| 687 | modified directly, this cache should be flushed. |
| Shawn O. Pearce | 51967cd | 2009-05-08 19:46:57 -0700 | [diff] [blame] | 688 | |
| Shawn O. Pearce | b09322b | 2009-08-15 17:49:00 -0700 | [diff] [blame] | 689 | cache `"web_sessions"`:: |
| 690 | + |
| 691 | Tracks the live user sessions coming in over HTTP. Flushing this |
| 692 | cache would cause all users to be signed out immediately, forcing |
| Shawn O. Pearce | 727d80f | 2009-08-17 07:57:54 -0700 | [diff] [blame] | 693 | them to sign-in again. To avoid breaking active users, this cache |
| 694 | is not flushed automatically by `gerrit flush-caches --all`, but |
| 695 | instead must be explicitly requested. |
| 696 | + |
| 697 | If no disk cache is configured (or `cache.web_sessions.diskLimit` |
| 698 | is set to 0) a server restart will force all users to sign-out, |
| 699 | and need to sign-in again after the restart, as the cache was |
| 700 | unable to persist the session information. Enabling a disk cache |
| 701 | is strongly recommended. |
| 702 | + |
| Shawn O. Pearce | 2e1cb2b | 2012-05-24 14:28:40 -0700 | [diff] [blame] | 703 | Session storage is relatively inexpensive. The average entry in |
| 704 | this cache is approximately 346 bytes. |
| Shawn O. Pearce | b09322b | 2009-08-15 17:49:00 -0700 | [diff] [blame] | 705 | |
| Shawn O. Pearce | 4016a93 | 2009-05-28 15:12:40 -0700 | [diff] [blame] | 706 | See also link:cmd-flush-caches.html[gerrit flush-caches]. |
| 707 | |
| Shawn O. Pearce | 29de436 | 2010-03-03 17:51:26 -0800 | [diff] [blame] | 708 | [[cache_options]]Cache Options |
| 709 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
| 710 | |
| Shawn O. Pearce | 617aa39 | 2010-11-15 14:03:28 -0800 | [diff] [blame] | 711 | cache.diff_intraline.maxIdleWorkers:: |
| 712 | + |
| 713 | Number of idle worker threads to maintain for the intraline difference |
| 714 | computations. There is no upper bound on how many concurrent requests |
| 715 | 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] | 716 | load, only this many will remain idle afterwards. |
| Shawn O. Pearce | 617aa39 | 2010-11-15 14:03:28 -0800 | [diff] [blame] | 717 | + |
| 718 | Default is 1.5x number of available CPUs. |
| 719 | |
| 720 | cache.diff_intraline.timeout:: |
| 721 | + |
| 722 | Maximum number of milliseconds to wait for intraline difference data |
| 723 | before giving up and disabling it for a particular file pair. This is |
| 724 | a work around for an infinite loop bug in the intraline difference |
| David Pursehouse | e8c1fb9 | 2013-04-17 17:18:43 +0900 | [diff] [blame] | 725 | implementation. |
| 726 | + |
| 727 | If computation takes longer than the timeout, the worker thread is |
| 728 | terminated, an error message is shown, and no intraline difference is |
| 729 | displayed for the file pair. |
| Shawn O. Pearce | 617aa39 | 2010-11-15 14:03:28 -0800 | [diff] [blame] | 730 | + |
| 731 | Values should use common unit suffixes to express their setting: |
| 732 | + |
| 733 | * ms, milliseconds |
| 734 | * s, sec, second, seconds |
| 735 | * m, min, minute, minutes |
| 736 | * h, hr, hour, hours |
| 737 | |
| 738 | + |
| 739 | If a unit suffix is not specified, `milliseconds` is assumed. |
| 740 | + |
| 741 | Default is 5 seconds. |
| 742 | |
| Shawn O. Pearce | 307dd4e | 2010-11-15 12:12:20 -0800 | [diff] [blame] | 743 | cache.diff_intraline.enabled:: |
| Shawn O. Pearce | 29de436 | 2010-03-03 17:51:26 -0800 | [diff] [blame] | 744 | + |
| 745 | Boolean to enable or disable the computation of intraline differences |
| Shawn O. Pearce | 307dd4e | 2010-11-15 12:12:20 -0800 | [diff] [blame] | 746 | when populating a diff cache entry. This flag is provided primarily |
| 747 | as a backdoor to disable the intraline difference feature if |
| David Pursehouse | 9246356 | 2013-06-24 10:16:28 +0900 | [diff] [blame] | 748 | necessary. To maintain backwards compatibility with prior versions, |
| Shawn O. Pearce | 307dd4e | 2010-11-15 12:12:20 -0800 | [diff] [blame] | 749 | this setting will fallback to `cache.diff.intraline` if not set in the |
| 750 | configuration. |
| Shawn O. Pearce | 29de436 | 2010-03-03 17:51:26 -0800 | [diff] [blame] | 751 | + |
| 752 | Default is true, enabled. |
| 753 | |
| Shawn O. Pearce | b8e4e35 | 2011-05-19 18:09:01 -0700 | [diff] [blame] | 754 | cache.projects.checkFrequency:: |
| 755 | + |
| 756 | How often project configuration should be checked for update from Git. |
| 757 | Gerrit Code Review caches project access rules and configuration in |
| 758 | memory, checking the refs/meta/config branch every checkFrequency |
| 759 | minutes to see if a new revision should be loaded and used for future |
| 760 | access. Values can be specified using standard time unit abbreviations |
| 761 | ('ms', 'sec', 'min', etc.). |
| 762 | + |
| 763 | If set to 0, checks occur every time, which may slow down operations. |
| Shawn Pearce | c825ef1 | 2013-02-20 11:29:46 -0800 | [diff] [blame] | 764 | If set to 'disabled' or 'off', no check will ever be done. |
| Shawn O. Pearce | b8e4e35 | 2011-05-19 18:09:01 -0700 | [diff] [blame] | 765 | Administrators may force the cache to flush with |
| 766 | link:cmd-flush-caches.html[gerrit flush-caches]. |
| 767 | + |
| 768 | Default is 5 minutes. |
| 769 | |
| Shawn Pearce | b9ebb66 | 2013-07-19 19:45:25 -0700 | [diff] [blame] | 770 | [[change]]Section change |
| 771 | ~~~~~~~~~~~~~~~~~~~~~~~~ |
| 772 | |
| 773 | [[change.updateDelay]]change.updateDelay:: |
| 774 | + |
| 775 | How often in seconds the web interface should poll for updates to the |
| 776 | currently open change. The poller relies on the client's browser |
| 777 | cache to use If-Modified-Since and respect `304 Not Modified` HTTP |
| Matt Baker | 8ce12fc | 2013-11-26 21:43:12 -0700 | [diff] [blame] | 778 | responses. This allows for fast polls, often under 8 milliseconds. |
| Shawn Pearce | b9ebb66 | 2013-07-19 19:45:25 -0700 | [diff] [blame] | 779 | + |
| 780 | With a configured 30 second delay a server with 4900 active users will |
| 781 | typically need to dedicate 1 CPU to the update check. 4900 users |
| 782 | divided by an average delay of 30 seconds is 163 requests arriving per |
| 783 | second. If requests are served at ~6 ms response time, 1 CPU is |
| 784 | necessary to keep up with the update request traffic. On a smaller |
| 785 | user base of 500 active users, the default 30 second delay is only 17 |
| 786 | requests per second and requires ~10% CPU. |
| 787 | + |
| 788 | If 0 the update polling is disabled. |
| 789 | + |
| 790 | Default is 30 seconds. |
| 791 | |
| carloseduardo.baldacin | 14246de | 2011-07-14 17:52:22 -0300 | [diff] [blame] | 792 | [[changeMerge]]Section changeMerge |
| Remy Bohmer | 203eea3 | 2012-02-19 21:21:36 +0100 | [diff] [blame] | 793 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| carloseduardo.baldacin | 14246de | 2011-07-14 17:52:22 -0300 | [diff] [blame] | 794 | |
| Dave Borowitz | 204669c2 | 2012-10-11 11:06:08 -0700 | [diff] [blame] | 795 | changeMerge.checkFrequency:: |
| 796 | + |
| 797 | How often the database should be rescanned for changes that have been |
| 798 | submitted but not merged due to transient errors. Values can be |
| 799 | specified using standard time unit abbreviations ('ms', 'sec', 'min', |
| 800 | etc.). Set to 0 to disable periodic rescanning, only scanning once on |
| 801 | master node startup. |
| 802 | + |
| 803 | Default is 300 seconds (5 minutes). |
| 804 | |
| 805 | changeMerge.test:: |
| 806 | + |
| carloseduardo.baldacin | 14246de | 2011-07-14 17:52:22 -0300 | [diff] [blame] | 807 | Controls whether or not the mergeability test of changes is |
| 808 | enabled. If enabled, when the change page is loaded, the test is |
| 809 | triggered. The submit button will be enabled or disabled according to |
| 810 | the result. |
| Dave Borowitz | 204669c2 | 2012-10-11 11:06:08 -0700 | [diff] [blame] | 811 | + |
| carloseduardo.baldacin | 14246de | 2011-07-14 17:52:22 -0300 | [diff] [blame] | 812 | By default this is false (test is not enabled). |
| 813 | |
| Brad Larson | 991a31b | 2009-11-03 14:30:26 -0600 | [diff] [blame] | 814 | [[commentlink]]Section commentlink |
| Remy Bohmer | 203eea3 | 2012-02-19 21:21:36 +0100 | [diff] [blame] | 815 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| Brad Larson | 991a31b | 2009-11-03 14:30:26 -0600 | [diff] [blame] | 816 | Comment links are find/replace strings applied to change descriptions, |
| Chris Harris | 63c7cdd | 2012-11-23 12:17:36 -0500 | [diff] [blame] | 817 | patch comments, in-line code comments and approval category value descriptions |
| 818 | to turn set strings into hyperlinks. One common use is for linking to |
| 819 | bug-tracking systems. |
| Brad Larson | 991a31b | 2009-11-03 14:30:26 -0600 | [diff] [blame] | 820 | |
| 821 | In the following example configuration the 'changeid' comment link |
| Shawn O. Pearce | da866ae | 2009-12-16 15:46:03 -0800 | [diff] [blame] | 822 | will match typical Gerrit Change-Id values and create a hyperlink |
| 823 | to changes which reference it. The second configuration 'bugzilla' |
| 824 | will hyperlink terms such as 'bug 42' to an external bug tracker, |
| 825 | supplying the argument record number '42' for display. The third |
| David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 826 | configuration 'tracker' uses raw HTML to more precisely control |
| Shawn O. Pearce | da866ae | 2009-12-16 15:46:03 -0800 | [diff] [blame] | 827 | how the replacement is displayed to the user. |
| Brad Larson | 991a31b | 2009-11-03 14:30:26 -0600 | [diff] [blame] | 828 | |
| Shawn O. Pearce | da866ae | 2009-12-16 15:46:03 -0800 | [diff] [blame] | 829 | ---- |
| 830 | [commentlink "changeid"] |
| 831 | match = (I[0-9a-f]{8,40}) |
| 832 | link = "#q,$1,n,z" |
| Brad Larson | 991a31b | 2009-11-03 14:30:26 -0600 | [diff] [blame] | 833 | |
| Shawn O. Pearce | da866ae | 2009-12-16 15:46:03 -0800 | [diff] [blame] | 834 | [commentlink "bugzilla"] |
| Shawn O. Pearce | c99630a | 2010-02-21 19:11:56 -0800 | [diff] [blame] | 835 | match = "(bug\\s+#?)(\\d+)" |
| Shawn O. Pearce | da866ae | 2009-12-16 15:46:03 -0800 | [diff] [blame] | 836 | link = http://bugs.example.com/show_bug.cgi?id=$2 |
| Brad Larson | 991a31b | 2009-11-03 14:30:26 -0600 | [diff] [blame] | 837 | |
| Shawn O. Pearce | da866ae | 2009-12-16 15:46:03 -0800 | [diff] [blame] | 838 | [commentlink "tracker"] |
| 839 | match = ([Bb]ug:\\s+)(\\d+) |
| 840 | html = $1<a href=\"http://trak.example.com/$2\">$2</a> |
| 841 | ---- |
| 842 | |
| Dave Borowitz | 13b3800 | 2013-04-08 12:03:29 -0700 | [diff] [blame] | 843 | Comment links can also be specified in `project.config` and sections in |
| 844 | children override those in parents. The only restriction is that to |
| 845 | avoid injecting arbitrary user-supplied HTML in the page, comment links |
| 846 | defined in `project.config` may only supply `link`, not `html`. |
| 847 | |
| Shawn O. Pearce | da866ae | 2009-12-16 15:46:03 -0800 | [diff] [blame] | 848 | [[commentlink.name.match]]commentlink.<name>.match:: |
| Brad Larson | 991a31b | 2009-11-03 14:30:26 -0600 | [diff] [blame] | 849 | + |
| Shawn O. Pearce | da866ae | 2009-12-16 15:46:03 -0800 | [diff] [blame] | 850 | A JavaScript regular expression to match positions to be replaced |
| 851 | with a hyperlink. Subexpressions of the matched string can be |
| 852 | stored using groups and accessed with `$'n'` syntax, where 'n' |
| 853 | is the group number, starting from 1. |
| Brad Larson | 991a31b | 2009-11-03 14:30:26 -0600 | [diff] [blame] | 854 | + |
| Shawn O. Pearce | c99630a | 2010-02-21 19:11:56 -0800 | [diff] [blame] | 855 | The configuration file parser eats one level of backslashes, so the |
| 856 | character class `\s` requires `\\s` in the configuration file. The |
| 857 | parser also terminates the line at the first `#`, so a match |
| 858 | expression containing # must be wrapped in double quotes. |
| Shawn O. Pearce | da866ae | 2009-12-16 15:46:03 -0800 | [diff] [blame] | 859 | + |
| Shawn O. Pearce | 665beaa | 2010-02-21 22:41:03 -0800 | [diff] [blame] | 860 | To match case insensitive strings, a character class with both the |
| 861 | upper and lower case character for each position must be used. For |
| 862 | example, to match the string `bug` in a case insensitive way the match |
| 863 | pattern `[bB][uU][gG]` needs to be used. |
| 864 | + |
| Shawn O. Pearce | da866ae | 2009-12-16 15:46:03 -0800 | [diff] [blame] | 865 | A common pattern to match is `bug\\s+(\\d+)`. |
| Brad Larson | 991a31b | 2009-11-03 14:30:26 -0600 | [diff] [blame] | 866 | |
| Shawn O. Pearce | da866ae | 2009-12-16 15:46:03 -0800 | [diff] [blame] | 867 | [[commentlink.name.link]]commentlink.<name>.link:: |
| Brad Larson | 991a31b | 2009-11-03 14:30:26 -0600 | [diff] [blame] | 868 | + |
| Shawn O. Pearce | da866ae | 2009-12-16 15:46:03 -0800 | [diff] [blame] | 869 | The URL to direct the user to whenever the regular expression is |
| 870 | matched. Groups in the match expression may be accessed as `$'n'`. |
| 871 | + |
| 872 | The link property is used only when the html property is not present. |
| 873 | |
| 874 | [[commentlink.name.html]]commentlink.<name>.html:: |
| 875 | + |
| 876 | HTML to replace the entire matched string with. If present, |
| 877 | this property overrides the link property above. Groups in the |
| 878 | match expression may be accessed as `$'n'`. |
| 879 | + |
| 880 | The configuration file eats double quotes, so escaping them as |
| 881 | `\"` is necessary to protect them from the parser. |
| Brad Larson | 991a31b | 2009-11-03 14:30:26 -0600 | [diff] [blame] | 882 | |
| Dave Borowitz | 82d79c0 | 2013-04-08 15:45:12 -0700 | [diff] [blame] | 883 | [[commentlink.name.enabled]]commentlink.<name>.enabled:: |
| 884 | + |
| 885 | Whether the comment link is enabled. A child project may override a |
| 886 | section in a parent or the site-wide config that is disabled by |
| 887 | specifying `enabled = true`. |
| 888 | + |
| 889 | Disabling sections in `gerrit.config` can be used by site administrators |
| 890 | to create a library of comment links with `html` set that are not |
| 891 | user-supplied and thus can be verified to be XSS-free, but are only |
| 892 | enabled for a subset of projects. |
| 893 | + |
| 894 | Note that the names and contents of disabled sections are visible even |
| 895 | to anonymous users via the |
| 896 | link:rest-api-projects.html#get-config[REST API]. |
| 897 | |
| Brad Larson | 991a31b | 2009-11-03 14:30:26 -0600 | [diff] [blame] | 898 | |
| Shawn O. Pearce | 8efb2a7 | 2009-08-18 19:45:33 -0700 | [diff] [blame] | 899 | [[contactstore]]Section contactstore |
| 900 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| Shawn O. Pearce | 6854bdc | 2009-06-01 08:14:15 -0700 | [diff] [blame] | 901 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 902 | [[contactstore.url]]contactstore.url:: |
| Shawn O. Pearce | 6854bdc | 2009-06-01 08:14:15 -0700 | [diff] [blame] | 903 | + |
| 904 | URL of the web based contact store Gerrit will send any offline |
| 905 | contact information to when it collects the data from users as part |
| 906 | of a contributor agreement. |
| 907 | + |
| 908 | See link:config-contact.html[Contact Information]. |
| 909 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 910 | [[contactstore.appsec]]contactstore.appsec:: |
| Shawn O. Pearce | 6854bdc | 2009-06-01 08:14:15 -0700 | [diff] [blame] | 911 | + |
| 912 | Shared secret of the web based contact store. |
| 913 | |
| Shawn O. Pearce | e24c71fb | 2009-12-07 20:32:40 -0800 | [diff] [blame] | 914 | |
| 915 | [[container]]Section container |
| 916 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 917 | |
| 918 | These settings are applied only if Gerrit is started as the container |
| 919 | process through Gerrit's 'gerrit.sh' rc.d compatible wrapper script. |
| 920 | |
| 921 | [[container.heapLimit]]container.heapLimit:: |
| 922 | + |
| 923 | Maximum heap size of the Java process running Gerrit, in bytes. |
| 924 | This property is translated into the '-Xmx' flag for the JVM. |
| 925 | + |
| 926 | Default is platform and JVM specific. |
| 927 | + |
| 928 | Common unit suffixes of 'k', 'm', or 'g' are supported. |
| 929 | |
| 930 | [[container.javaHome]]container.javaHome:: |
| 931 | + |
| 932 | Path of the JRE/JDK installation to run Gerrit with. If not set, the |
| 933 | Gerrit startup script will attempt to search your system and guess |
| 934 | a suitable JRE. Overrides the environment variable 'JAVA_HOME'. |
| 935 | |
| 936 | [[container.javaOptions]]container.javaOptions:: |
| 937 | + |
| 938 | Additional options to pass along to the Java runtime. If multiple |
| 939 | values are configured, they are passed in order on the command line, |
| 940 | separated by spaces. These options are appended onto 'JAVA_OPTIONS'. |
| 941 | |
| David Ostrovsky | c772bd8 | 2013-10-03 10:37:51 +0200 | [diff] [blame] | 942 | For example, it is possible to overwrite Gerrit's default log4j |
| 943 | configuration: |
| 944 | |
| 945 | ---- |
| 946 | javaOptions = -Dlog4j.configuration=file:///home/gerrit/site/etc/log4j.properties |
| 947 | ---- |
| 948 | |
| Fredrik Luthander | b8f7d6d | 2010-05-18 21:11:22 +0200 | [diff] [blame] | 949 | [[container.slave]]container.slave:: |
| 950 | + |
| 951 | Used on Gerrit slave installations. If set to true the Gerrit JVM is |
| 952 | called with the '--slave' switch, enabling slave mode. If no value is |
| Matt Baker | 8ce12fc | 2013-11-26 21:43:12 -0700 | [diff] [blame] | 953 | set (or any other value), Gerrit defaults to master mode. |
| Fredrik Luthander | b8f7d6d | 2010-05-18 21:11:22 +0200 | [diff] [blame] | 954 | |
| Shawn O. Pearce | e24c71fb | 2009-12-07 20:32:40 -0800 | [diff] [blame] | 955 | [[container.user]]container.user:: |
| 956 | + |
| 957 | Login name (or UID) of the operating system user the Gerrit JVM |
| 958 | will execute as. If not set, defaults to the user who launched |
| 959 | the 'gerrit.sh' wrapper script. |
| 960 | |
| 961 | [[container.war]]container.war:: |
| 962 | + |
| 963 | Path of the JAR file to start daemon execution with. This should |
| 964 | be the path of the local 'gerrit.war' archive. Overrides the |
| 965 | environment variable 'GERRIT_WAR'. |
| 966 | + |
| 967 | If not set, defaults to '$site_path/bin/gerrit.war', or to |
| 968 | '$HOME/gerrit.war'. |
| 969 | |
| 970 | |
| Shawn O. Pearce | 8efb2a7 | 2009-08-18 19:45:33 -0700 | [diff] [blame] | 971 | [[core]]Section core |
| 972 | ~~~~~~~~~~~~~~~~~~~~ |
| Shawn O. Pearce | 6854bdc | 2009-06-01 08:14:15 -0700 | [diff] [blame] | 973 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 974 | [[core.packedGitWindowSize]]core.packedGitWindowSize:: |
| Shawn O. Pearce | 6854bdc | 2009-06-01 08:14:15 -0700 | [diff] [blame] | 975 | + |
| 976 | Number of bytes of a pack file to load into memory in a single |
| 977 | read operation. This is the "page size" of the JGit buffer cache, |
| 978 | used for all pack access operations. All disk IO occurs as single |
| 979 | window reads. Setting this too large may cause the process to load |
| 980 | more data than is required; setting this too small may increase |
| 981 | the frequency of `read()` system calls. |
| 982 | + |
| 983 | Default on JGit is 8 KiB on all platforms. |
| 984 | + |
| 985 | Common unit suffixes of 'k', 'm', or 'g' are supported. |
| 986 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 987 | [[core.packedGitLimit]]core.packedGitLimit:: |
| Shawn O. Pearce | 6854bdc | 2009-06-01 08:14:15 -0700 | [diff] [blame] | 988 | + |
| 989 | Maximum number of bytes to load and cache in memory from pack files. |
| 990 | If JGit needs to access more than this many bytes it will unload less |
| 991 | frequently used windows to reclaim memory space within the process. |
| 992 | As this buffer must be shared with the rest of the JVM heap, it |
| 993 | should be a fraction of the total memory available. |
| 994 | + |
| 995 | Default on JGit is 10 MiB on all platforms. |
| 996 | + |
| 997 | Common unit suffixes of 'k', 'm', or 'g' are supported. |
| 998 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 999 | [[core.deltaBaseCaseLimit]]core.deltaBaseCacheLimit:: |
| Shawn O. Pearce | 6854bdc | 2009-06-01 08:14:15 -0700 | [diff] [blame] | 1000 | + |
| 1001 | Maximum number of bytes to reserve for caching base objects |
| 1002 | that multiple deltafied objects reference. By storing the entire |
| 1003 | decompressed base object in a cache Git is able to avoid unpacking |
| 1004 | and decompressing frequently used base objects multiple times. |
| 1005 | + |
| 1006 | Default on JGit is 10 MiB on all platforms. You probably do not |
| 1007 | need to adjust this value. |
| 1008 | + |
| 1009 | Common unit suffixes of 'k', 'm', or 'g' are supported. |
| 1010 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1011 | [[core.packedGitOpenFiles]]core.packedGitOpenFiles:: |
| Shawn O. Pearce | 6854bdc | 2009-06-01 08:14:15 -0700 | [diff] [blame] | 1012 | + |
| 1013 | Maximum number of pack files to have open at once. A pack file |
| 1014 | must be opened in order for any of its data to be available in |
| 1015 | a cached window. |
| 1016 | + |
| 1017 | If you increase this to a larger setting you may need to also adjust |
| 1018 | the ulimit on file descriptors for the host JVM, as Gerrit needs |
| 1019 | additional file descriptors available for network sockets and other |
| 1020 | repository data manipulation. |
| 1021 | + |
| 1022 | Default on JGit is 128 file descriptors on all platforms. |
| 1023 | |
| Shawn O. Pearce | 329fe79 | 2010-09-03 15:44:23 -0700 | [diff] [blame] | 1024 | [[core.streamFileThreshold]]core.streamFileThreshold:: |
| 1025 | + |
| 1026 | Largest object size, in bytes, that JGit will allocate as a |
| 1027 | contiguous byte array. Any file revision larger than this threshold |
| 1028 | will have to be streamed, typically requiring the use of temporary |
| David Pursehouse | 9246356 | 2013-06-24 10:16:28 +0900 | [diff] [blame] | 1029 | files under '$GIT_DIR/objects' to implement pseudo-random access |
| Shawn O. Pearce | 329fe79 | 2010-09-03 15:44:23 -0700 | [diff] [blame] | 1030 | during delta decompression. |
| 1031 | + |
| 1032 | Servers with very high traffic should set this to be larger than |
| 1033 | the size of their common big files. For example a server managing |
| 1034 | the Android platform typically has to deal with ~10-12 MiB XML |
| 1035 | files, so `15 m` would be a reasonable setting in that environment. |
| 1036 | Setting this too high may cause the JVM to run out of heap space |
| 1037 | when handling very big binary files, such as device firmware or |
| 1038 | CD-ROM ISO images. |
| 1039 | + |
| Shawn O. Pearce | e3febd9 | 2010-10-13 21:17:53 -0700 | [diff] [blame] | 1040 | 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] | 1041 | this value was effectively 2047 MiB. |
| 1042 | + |
| 1043 | Common unit suffixes of 'k', 'm', or 'g' are supported. |
| 1044 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1045 | [[core.packedGitMmap]]core.packedGitMmap:: |
| Shawn O. Pearce | 6854bdc | 2009-06-01 08:14:15 -0700 | [diff] [blame] | 1046 | + |
| 1047 | When true, JGit will use `mmap()` rather than `malloc()+read()` |
| 1048 | to load data from pack files. The use of mmap can be problematic |
| 1049 | on some JVMs as the garbage collector must deduce that a memory |
| 1050 | mapped segment is no longer in use before a call to `munmap()` |
| 1051 | can be made by the JVM native code. |
| 1052 | + |
| 1053 | In server applications (such as Gerrit) that need to access many |
| David Pursehouse | 9246356 | 2013-06-24 10:16:28 +0900 | [diff] [blame] | 1054 | pack files, setting this to true risks artificially running out |
| Shawn O. Pearce | 6854bdc | 2009-06-01 08:14:15 -0700 | [diff] [blame] | 1055 | of virtual address space, as the garbage collector cannot reclaim |
| 1056 | unused mapped spaces fast enough. |
| 1057 | + |
| 1058 | Default on JGit is false. Although potentially slower, it yields |
| 1059 | much more predictable behavior. |
| 1060 | |
| Sasa Zivkov | f69aeb1 | 2012-06-11 14:05:14 +0200 | [diff] [blame] | 1061 | [[core.asyncLoggingBufferSize]]core.asyncLoggingBufferSize:: |
| 1062 | + |
| 1063 | Size of the buffer to store logging events for asynchronous logging. |
| 1064 | Putting a larger value can protect threads from stalling when the |
| 1065 | AsyncAppender threads are not fast enough to consume the logging events |
| 1066 | from the buffer. It also protects from loosing log entries in this case. |
| 1067 | + |
| 1068 | Default is 64 entries. |
| 1069 | |
| Dave Borowitz | 1bec65a | 2013-03-13 10:59:01 -0700 | [diff] [blame] | 1070 | [[core.useRecursiveMerge]]core.useRecursiveMerge:: |
| 1071 | + |
| 1072 | Use JGit's new, experimental recursive merger for three-way merges. |
| 1073 | This only affects projects configured to automatically resolve |
| 1074 | conflicts. |
| 1075 | + |
| 1076 | Default is false, but in a future release may default to true. |
| 1077 | |
| Shawn O. Pearce | fb5548e | 2009-11-11 07:39:21 -0800 | [diff] [blame] | 1078 | [[database]]Section database |
| 1079 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 1080 | |
| 1081 | The database section configures where Gerrit stores its metadata |
| 1082 | records about user accounts and change reviews. |
| 1083 | |
| Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 1084 | ---- |
| 1085 | [database] |
| Shawn O. Pearce | 1be3906 | 2009-12-19 14:11:52 -0800 | [diff] [blame] | 1086 | type = POSTGRESQL |
| Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 1087 | hostname = localhost |
| 1088 | database = reviewdb |
| 1089 | username = gerrit2 |
| 1090 | password = s3kr3t |
| 1091 | ---- |
| Shawn O. Pearce | fb5548e | 2009-11-11 07:39:21 -0800 | [diff] [blame] | 1092 | |
| 1093 | [[database.type]]database.type:: |
| 1094 | + |
| 1095 | Type of database server to connect to. If set this value will be |
| 1096 | used to automatically create correct database.driver and database.url |
| 1097 | values to open the connection. |
| 1098 | + |
| Shawn O. Pearce | 1be3906 | 2009-12-19 14:11:52 -0800 | [diff] [blame] | 1099 | * `POSTGRESQL` |
| Shawn O. Pearce | fb5548e | 2009-11-11 07:39:21 -0800 | [diff] [blame] | 1100 | + |
| 1101 | Connect to a PostgreSQL database server. |
| 1102 | + |
| 1103 | * `H2` |
| 1104 | + |
| Shawn O. Pearce | 1be3906 | 2009-12-19 14:11:52 -0800 | [diff] [blame] | 1105 | Connect to a local embedded H2 database. |
| Shawn O. Pearce | fb5548e | 2009-11-11 07:39:21 -0800 | [diff] [blame] | 1106 | + |
| Shawn O. Pearce | 1be3906 | 2009-12-19 14:11:52 -0800 | [diff] [blame] | 1107 | * `MYSQL` |
| Shawn O. Pearce | fb5548e | 2009-11-11 07:39:21 -0800 | [diff] [blame] | 1108 | + |
| 1109 | Connect to a MySQL database server. |
| Shawn O. Pearce | 1be3906 | 2009-12-19 14:11:52 -0800 | [diff] [blame] | 1110 | + |
| 1111 | * `JDBC` |
| 1112 | + |
| 1113 | Connect using a JDBC driver class name and URL. |
| Shawn O. Pearce | fb5548e | 2009-11-11 07:39:21 -0800 | [diff] [blame] | 1114 | |
| 1115 | + |
| 1116 | If not specified, database.driver and database.url are used as-is, |
| 1117 | and if they are also not specified, defaults to H2. |
| 1118 | |
| 1119 | [[database.hostname]]database.hostname:: |
| 1120 | + |
| 1121 | Hostname of the database server. Defaults to 'localhost'. |
| 1122 | |
| 1123 | [[database.port]]database.port:: |
| 1124 | + |
| 1125 | Port number of the database server. Defaults to the default port |
| 1126 | of the server named by database.type. |
| 1127 | |
| 1128 | [[database.database]]database.database:: |
| 1129 | + |
| Shawn O. Pearce | 1be3906 | 2009-12-19 14:11:52 -0800 | [diff] [blame] | 1130 | 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] | 1131 | + |
| 1132 | 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] | 1133 | relative to `'$site_path'`. |
| Shawn O. Pearce | fb5548e | 2009-11-11 07:39:21 -0800 | [diff] [blame] | 1134 | |
| 1135 | [[database.username]]database.username:: |
| 1136 | + |
| 1137 | Username to connect to the database server as. |
| 1138 | |
| 1139 | [[database.password]]database.password:: |
| 1140 | + |
| 1141 | Password to authenticate to the database server with. |
| 1142 | |
| 1143 | [[database.driver]]database.driver:: |
| 1144 | + |
| Shawn O. Pearce | 1be3906 | 2009-12-19 14:11:52 -0800 | [diff] [blame] | 1145 | Name of the JDBC driver class to connect to the database with. |
| 1146 | Setting this usually isn't necessary as it can be derived from |
| 1147 | database.type or database.url for any supported database. |
| Shawn O. Pearce | fb5548e | 2009-11-11 07:39:21 -0800 | [diff] [blame] | 1148 | |
| 1149 | [[database.url]]database.url:: |
| 1150 | + |
| Shawn O. Pearce | 1be3906 | 2009-12-19 14:11:52 -0800 | [diff] [blame] | 1151 | 'jdbc:' URL for the database. Setting this variable usually |
| 1152 | isn't necessary as it can be constructed from the all of the |
| 1153 | above properties. |
| Shawn O. Pearce | fb5548e | 2009-11-11 07:39:21 -0800 | [diff] [blame] | 1154 | |
| Christian Aistleitner | 851072a | 2013-05-05 15:04:09 +0200 | [diff] [blame] | 1155 | [[database.connectionPool]]database.connectionPool:: |
| 1156 | + |
| 1157 | If true, use connection pooling for database connections. Otherwise, a |
| 1158 | new database connection is opened for each request. |
| 1159 | + |
| 1160 | Default is false for MySQL, and true for other database backends. |
| 1161 | |
| Shawn O. Pearce | 07f35177d | 2010-02-23 09:47:10 -0800 | [diff] [blame] | 1162 | [[database.poolLimit]]database.poolLimit:: |
| 1163 | + |
| 1164 | Maximum number of open database connections. If the server needs |
| 1165 | more than this number, request processing threads will wait up |
| 1166 | to <<database.poolMaxWait, poolMaxWait>> seconds for a |
| 1167 | connection to be released before they abort with an exception. |
| 1168 | This limit must be several units higher than the total number of |
| 1169 | httpd and sshd threads as some request processing code paths may |
| 1170 | need multiple connections. |
| 1171 | + |
| 1172 | Default is 8. |
| Christian Aistleitner | 851072a | 2013-05-05 15:04:09 +0200 | [diff] [blame] | 1173 | + |
| 1174 | This setting only applies if |
| 1175 | <<database.connectionPool,database.connectionPool>> is true. |
| Shawn O. Pearce | 07f35177d | 2010-02-23 09:47:10 -0800 | [diff] [blame] | 1176 | |
| Shawn O. Pearce | f458bf6 | 2010-02-25 09:03:03 -0800 | [diff] [blame] | 1177 | [[database.poolMinIdle]]database.poolMinIdle:: |
| Shawn O. Pearce | 07f35177d | 2010-02-23 09:47:10 -0800 | [diff] [blame] | 1178 | + |
| 1179 | Minimum number of connections to keep idle in the pool. |
| 1180 | Default is 4. |
| Christian Aistleitner | 851072a | 2013-05-05 15:04:09 +0200 | [diff] [blame] | 1181 | + |
| 1182 | This setting only applies if |
| 1183 | <<database.connectionPool,database.connectionPool>> is true. |
| Shawn O. Pearce | 07f35177d | 2010-02-23 09:47:10 -0800 | [diff] [blame] | 1184 | |
| Shawn O. Pearce | f458bf6 | 2010-02-25 09:03:03 -0800 | [diff] [blame] | 1185 | [[database.poolMaxIdle]]database.poolMaxIdle:: |
| Shawn O. Pearce | 07f35177d | 2010-02-23 09:47:10 -0800 | [diff] [blame] | 1186 | + |
| 1187 | Maximum number of connections to keep idle in the pool. If there |
| 1188 | are more idle connections, connections will be closed instead of |
| 1189 | being returned back to the pool. |
| 1190 | Default is 4. |
| Christian Aistleitner | 851072a | 2013-05-05 15:04:09 +0200 | [diff] [blame] | 1191 | + |
| 1192 | This setting only applies if |
| 1193 | <<database.connectionPool,database.connectionPool>> is true. |
| Shawn O. Pearce | 07f35177d | 2010-02-23 09:47:10 -0800 | [diff] [blame] | 1194 | |
| 1195 | [[database.poolMaxWait]]database.poolMaxWait:: |
| 1196 | + |
| 1197 | Maximum amount of time a request processing thread will wait to |
| 1198 | acquire a database connection from the pool. If no connection is |
| 1199 | released within this time period, the processing thread will abort |
| 1200 | its current operations and return an error to the client. |
| 1201 | Values should use common unit suffixes to express their setting: |
| 1202 | + |
| 1203 | * ms, milliseconds |
| 1204 | * s, sec, second, seconds |
| 1205 | * m, min, minute, minutes |
| 1206 | * h, hr, hour, hours |
| 1207 | |
| 1208 | + |
| 1209 | If a unit suffix is not specified, `milliseconds` is assumed. |
| 1210 | + |
| 1211 | Default is `30 seconds`. |
| Christian Aistleitner | 851072a | 2013-05-05 15:04:09 +0200 | [diff] [blame] | 1212 | + |
| 1213 | This setting only applies if |
| 1214 | <<database.connectionPool,database.connectionPool>> is true. |
| Shawn O. Pearce | 07f35177d | 2010-02-23 09:47:10 -0800 | [diff] [blame] | 1215 | |
| monica.dionisio | 3f63044 | 2010-06-29 15:42:57 -0300 | [diff] [blame] | 1216 | [[download]]Section download |
| Nasser Grainawi | b9a5037 | 2010-08-10 07:57:47 -0600 | [diff] [blame] | 1217 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| monica.dionisio | 3f63044 | 2010-06-29 15:42:57 -0300 | [diff] [blame] | 1218 | |
| 1219 | ---- |
| 1220 | [download] |
| Edwin Kempin | 08b03a2 | 2012-09-14 16:32:57 +0200 | [diff] [blame] | 1221 | command = checkout |
| 1222 | command = cherry_pick |
| 1223 | command = pull |
| 1224 | command = format_patch |
| monica.dionisio | 3f63044 | 2010-06-29 15:42:57 -0300 | [diff] [blame] | 1225 | scheme = ssh |
| 1226 | scheme = http |
| 1227 | scheme = anon_http |
| 1228 | scheme = anon_git |
| 1229 | scheme = repo_download |
| 1230 | ---- |
| 1231 | |
| 1232 | The download section configures the allowed download methods. |
| 1233 | |
| Edwin Kempin | 08b03a2 | 2012-09-14 16:32:57 +0200 | [diff] [blame] | 1234 | [[download.command]]download.command:: |
| 1235 | + |
| 1236 | Commands that should be offered to download changes. |
| 1237 | + |
| 1238 | Multiple commands are supported: |
| 1239 | + |
| 1240 | * `checkout` |
| 1241 | + |
| 1242 | Command to fetch and checkout the patch set. |
| 1243 | + |
| 1244 | * `cherry_pick` |
| 1245 | + |
| 1246 | Command to fetch the patch set and to cherry-pick it onto the current |
| 1247 | commit. |
| 1248 | + |
| 1249 | * `pull` |
| 1250 | + |
| 1251 | Command to pull the patch set. |
| 1252 | + |
| 1253 | * `format_patch` |
| 1254 | + |
| 1255 | Command to fetch the patch set and to feed it into the `format-patch` |
| 1256 | command. |
| 1257 | |
| 1258 | + |
| 1259 | If `download.command` is not specified, all download commands are |
| 1260 | offered. |
| 1261 | |
| monica.dionisio | 3f63044 | 2010-06-29 15:42:57 -0300 | [diff] [blame] | 1262 | [[download.scheme]]download.scheme:: |
| 1263 | + |
| 1264 | Schemes that should be used to download changes. |
| 1265 | + |
| 1266 | Multiple schemes are supported: |
| 1267 | + |
| 1268 | * `http` |
| 1269 | + |
| Shawn O. Pearce | 5c46a07 | 2010-08-23 08:33:32 -0700 | [diff] [blame] | 1270 | Authenticated HTTP download is allowed. |
| monica.dionisio | 3f63044 | 2010-06-29 15:42:57 -0300 | [diff] [blame] | 1271 | + |
| 1272 | * `ssh` |
| 1273 | + |
| Shawn O. Pearce | 5c46a07 | 2010-08-23 08:33:32 -0700 | [diff] [blame] | 1274 | Authenticated SSH download is allowed. |
| monica.dionisio | 3f63044 | 2010-06-29 15:42:57 -0300 | [diff] [blame] | 1275 | + |
| 1276 | * `anon_http` |
| 1277 | + |
| 1278 | Anonymous HTTP download is allowed. |
| 1279 | + |
| 1280 | * `anon_git` |
| 1281 | + |
| Shawn O. Pearce | 5c46a07 | 2010-08-23 08:33:32 -0700 | [diff] [blame] | 1282 | Anonymous Git download is allowed. This is not default, it is also |
| 1283 | necessary to set <<gerrit.canonicalGitUrl,gerrit.canonicalGitUrl>> |
| 1284 | variable. |
| monica.dionisio | 3f63044 | 2010-06-29 15:42:57 -0300 | [diff] [blame] | 1285 | + |
| 1286 | * `repo_download` |
| 1287 | + |
| Shawn O. Pearce | 5c46a07 | 2010-08-23 08:33:32 -0700 | [diff] [blame] | 1288 | Gerrit advertises patch set downloads with the `repo download` |
| 1289 | command, assuming that all projects managed by this instance are |
| 1290 | generally worked on with the repo multi-repository tool. This is |
| 1291 | not default, as not all instances will deploy repo. |
| monica.dionisio | 3f63044 | 2010-06-29 15:42:57 -0300 | [diff] [blame] | 1292 | |
| 1293 | + |
| Edwin Kempin | 08b03a2 | 2012-09-14 16:32:57 +0200 | [diff] [blame] | 1294 | If `download.scheme` is not specified, SSH, HTTP and Anonymous HTTP |
| Shawn O. Pearce | 5c46a07 | 2010-08-23 08:33:32 -0700 | [diff] [blame] | 1295 | downloads are allowed. |
| Shawn O. Pearce | fb5548e | 2009-11-11 07:39:21 -0800 | [diff] [blame] | 1296 | |
| Shawn O. Pearce | 8efb2a7 | 2009-08-18 19:45:33 -0700 | [diff] [blame] | 1297 | [[gerrit]]Section gerrit |
| 1298 | ~~~~~~~~~~~~~~~~~~~~~~~~ |
| Shawn O. Pearce | eb7f8ce | 2009-06-01 09:57:15 -0700 | [diff] [blame] | 1299 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1300 | [[gerrit.basePath]]gerrit.basePath:: |
| Shawn O. Pearce | 9743d0b | 2009-06-01 10:10:06 -0700 | [diff] [blame] | 1301 | + |
| 1302 | Local filesystem directory holding all Git repositories that |
| 1303 | Gerrit knows about and can process changes for. A project |
| 1304 | entity in Gerrit maps to a local Git repository by creating |
| Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1305 | the path string `"${basePath}/${project_name}.git"`. |
| Shawn O. Pearce | 9743d0b | 2009-06-01 10:10:06 -0700 | [diff] [blame] | 1306 | + |
| 1307 | If relative, the path is resolved relative to `'$site_path'`. |
| 1308 | |
| Shawn O. Pearce | 897d921 | 2011-06-16 16:59:59 -0700 | [diff] [blame] | 1309 | [[gerrit.allProjects]]gerrit.allProjects:: |
| 1310 | + |
| 1311 | Name of the permissions-only project defining global server |
| 1312 | access controls and settings. These are inherited into every |
| 1313 | other project managed by the running server. The name is |
| 1314 | relative to `gerrit.basePath`. |
| 1315 | + |
| 1316 | Defaults to `All-Projects` if not set. |
| 1317 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1318 | [[gerrit.canonicalWebUrl]]gerrit.canonicalWebUrl:: |
| Shawn O. Pearce | eb7f8ce | 2009-06-01 09:57:15 -0700 | [diff] [blame] | 1319 | + |
| 1320 | The default URL for Gerrit to be accessed through. |
| 1321 | + |
| 1322 | Typically this would be set to "http://review.example.com/" or |
| 1323 | "http://example.com/gerrit/" so Gerrit can output links that point |
| 1324 | back to itself. |
| 1325 | + |
| 1326 | Setting this is highly recommended, as its necessary for the upload |
| 1327 | code invoked by "git push" or "repo upload" to output hyperlinks |
| 1328 | to the newly uploaded changes. |
| 1329 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1330 | [[gerrit.canonicalGitUrl]]gerrit.canonicalGitUrl:: |
| Shawn O. Pearce | eb7f8ce | 2009-06-01 09:57:15 -0700 | [diff] [blame] | 1331 | + |
| 1332 | Optional base URL for repositories available over the anonymous git |
| 1333 | protocol. For example, set this to `git://mirror.example.com/base/` |
| 1334 | to have Gerrit display patch set download URLs in the UI. Gerrit |
| 1335 | automatically appends the project name onto the end of the URL. |
| 1336 | + |
| 1337 | By default unset, as the git daemon must be configured externally |
| 1338 | by the system administrator, and might not even be running on the |
| 1339 | same host as Gerrit. |
| 1340 | |
| Dave Borowitz | 76ab1a1 | 2013-05-10 17:01:29 +0100 | [diff] [blame] | 1341 | [[gerrit.installCommitMsgHookCommand]]gerrit.installCommitMsgHookCommand:: |
| 1342 | + |
| 1343 | Optional command to install the `commit-msg` hook. Typically of the |
| 1344 | form: |
| 1345 | ---- |
| 1346 | fetch-cmd some://url/to/commit-msg .git/hooks/commit-msg ; chmod +x .git/hooks/commit-msg |
| 1347 | ---- |
| Shawn Pearce | 6d731f5 | 2013-09-24 12:13:50 -0700 | [diff] [blame] | 1348 | |
| Dave Borowitz | 76ab1a1 | 2013-05-10 17:01:29 +0100 | [diff] [blame] | 1349 | + |
| 1350 | By default unset; falls back to using scp from the canonical SSH host, |
| 1351 | or curl from the canonical HTTP URL for the server. Only necessary if a |
| 1352 | proxy or other server/network configuration prevents clients from |
| 1353 | fetching from the default location. |
| 1354 | |
| Shawn O. Pearce | 5d6de52 | 2011-10-07 18:00:16 -0700 | [diff] [blame] | 1355 | [[gerrit.gitHttpUrl]]gerrit.gitHttpUrl:: |
| 1356 | + |
| 1357 | Optional base URL for repositories available over the HTTP |
| 1358 | protocol. For example, set this to `http://mirror.example.com/base/` |
| 1359 | to have Gerrit display URLs from this server, rather than itself. |
| 1360 | + |
| 1361 | By default unset, as the HTTP daemon must be configured externally |
| 1362 | by the system administrator, and might not even be running on the |
| 1363 | same host as Gerrit. |
| 1364 | |
| Shawn O. Pearce | b8bea1b | 2012-08-16 17:18:58 -0700 | [diff] [blame] | 1365 | [[gerrit.reportBugUrl]]gerrit.reportBugUrl:: |
| 1366 | + |
| 1367 | URL to direct users to when they need to report a bug about the |
| 1368 | Gerrit service. By default this links to the upstream Gerrit |
| 1369 | Code Review's own bug tracker but could be directed to the system |
| 1370 | administrator's ticket queue. |
| 1371 | |
| Shawn Pearce | 6d731f5 | 2013-09-24 12:13:50 -0700 | [diff] [blame] | 1372 | [[gerrit.changeScreen]]gerrit.changeScreen:: |
| 1373 | + |
| 1374 | Default change screen UI to direct users to. Valid values are |
| 1375 | `OLD_UI` and `CHANGE_SCREEN2`. Default is `OLD_UI`. |
| 1376 | |
| Shawn O. Pearce | 8efb2a7 | 2009-08-18 19:45:33 -0700 | [diff] [blame] | 1377 | [[gitweb]]Section gitweb |
| 1378 | ~~~~~~~~~~~~~~~~~~~~~~~~ |
| Shawn O. Pearce | d7ba11f | 2009-06-01 09:35:41 -0700 | [diff] [blame] | 1379 | |
| Shawn O. Pearce | 618dae2 | 2010-03-12 19:07:43 -0800 | [diff] [blame] | 1380 | Gerrit can forward requests to either an internally managed gitweb |
| 1381 | (which allows Gerrit to enforce some access controls), or to an |
| 1382 | externally managed gitweb (where the web server manages access). |
| Shawn O. Pearce | d7ba11f | 2009-06-01 09:35:41 -0700 | [diff] [blame] | 1383 | See also link:config-gitweb.html[Gitweb Integration]. |
| 1384 | |
| Shawn O. Pearce | 618dae2 | 2010-03-12 19:07:43 -0800 | [diff] [blame] | 1385 | [[gitweb.cgi]]gitweb.cgi:: |
| 1386 | + |
| 1387 | Path to the locally installed `gitweb.cgi` executable. This CGI will |
| 1388 | be called by Gerrit Code Review when the URL `/gitweb` is accessed. |
| 1389 | Project level access controls are enforced prior to calling the CGI. |
| 1390 | + |
| 1391 | Defaults to `/usr/lib/cgi-bin/gitweb.cgi` if gitweb.url is not set. |
| 1392 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1393 | [[gitweb.url]]gitweb.url:: |
| Shawn O. Pearce | d7ba11f | 2009-06-01 09:35:41 -0700 | [diff] [blame] | 1394 | + |
| 1395 | Optional URL of an affiliated gitweb service. Defines the |
| 1396 | web location where a `gitweb.cgi` is installed to browse |
| Shawn O. Pearce | 9743d0b | 2009-06-01 10:10:06 -0700 | [diff] [blame] | 1397 | gerrit.basePath and the repositories it contains. |
| Shawn O. Pearce | d7ba11f | 2009-06-01 09:35:41 -0700 | [diff] [blame] | 1398 | + |
| 1399 | Gerrit appends any necessary query arguments onto the end of this URL. |
| 1400 | For example, "?p=$project.git;h=$commit". |
| 1401 | |
| Shane Mc Cormack | 27868a4 | 2009-12-28 04:49:39 +0000 | [diff] [blame] | 1402 | [[gitweb.type]]gitweb.type:: |
| 1403 | + |
| 1404 | Optional type of affiliated gitweb service. This allows using |
| Shawn O. Pearce | 2b11da0 | 2011-09-06 16:18:12 -0700 | [diff] [blame] | 1405 | alternatives to gitweb, such as cgit. If set to disabled there |
| 1406 | is no gitweb hyperlinking support. |
| Shane Mc Cormack | 27868a4 | 2009-12-28 04:49:39 +0000 | [diff] [blame] | 1407 | + |
| Shawn O. Pearce | 2b11da0 | 2011-09-06 16:18:12 -0700 | [diff] [blame] | 1408 | Valid values are `gitweb`, `cgit`, `disabled` or `custom`. |
| Shane Mc Cormack | 27868a4 | 2009-12-28 04:49:39 +0000 | [diff] [blame] | 1409 | |
| Edwin Kempin | d86909c | 2012-03-26 10:36:29 +0200 | [diff] [blame] | 1410 | [[gitweb.revision]]gitweb.revision:: |
| Shane Mc Cormack | 27868a4 | 2009-12-28 04:49:39 +0000 | [diff] [blame] | 1411 | + |
| 1412 | Optional pattern to use for constructing the gitweb URL when pointing |
| 1413 | at a specific commit when `custom` is used above. |
| 1414 | + |
| Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1415 | Valid replacements are `${project}` for the project name in Gerrit |
| 1416 | and `${commit}` for the SHA1 hash for the commit. |
| Shane Mc Cormack | 27868a4 | 2009-12-28 04:49:39 +0000 | [diff] [blame] | 1417 | |
| Edwin Kempin | d86909c | 2012-03-26 10:36:29 +0200 | [diff] [blame] | 1418 | [[gitweb.project]]gitweb.project:: |
| Shane Mc Cormack | 27868a4 | 2009-12-28 04:49:39 +0000 | [diff] [blame] | 1419 | + |
| 1420 | Optional pattern to use for constructing the gitweb URL when pointing |
| 1421 | at a specific project when `custom` is used above. |
| 1422 | + |
| Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1423 | Valid replacements are `${project}` for the project name in Gerrit. |
| Shane Mc Cormack | 27868a4 | 2009-12-28 04:49:39 +0000 | [diff] [blame] | 1424 | |
| Edwin Kempin | d86909c | 2012-03-26 10:36:29 +0200 | [diff] [blame] | 1425 | [[gitweb.branch]]gitweb.branch:: |
| Shane Mc Cormack | 27868a4 | 2009-12-28 04:49:39 +0000 | [diff] [blame] | 1426 | + |
| 1427 | Optional pattern to use for constructing the gitweb URL when pointing |
| 1428 | at a specific branch when `custom` is used above. |
| 1429 | + |
| Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1430 | Valid replacements are `${project}` for the project name in Gerrit |
| 1431 | and `${branch}` for the name of the branch. |
| Shane Mc Cormack | 27868a4 | 2009-12-28 04:49:39 +0000 | [diff] [blame] | 1432 | |
| Edwin Kempin | 6401156 | 2012-03-26 10:50:12 +0200 | [diff] [blame] | 1433 | [[gitweb.filehistory]]gitweb.filehistory:: |
| 1434 | + |
| 1435 | Optional pattern to use for constructing the gitweb URL when pointing |
| 1436 | at the history of a file in a specific branch when `custom` is used |
| 1437 | above. |
| 1438 | + |
| 1439 | Valid replacements are `${project}` for the project name in Gerrit, |
| 1440 | `${file}` for the file name and `${branch}` for the name of the |
| 1441 | branch. |
| 1442 | |
| Gustaf Lundh | a07d2e7 | 2011-10-27 15:26:35 -0700 | [diff] [blame] | 1443 | [[gitweb.linkname]]gitweb.linkname:: |
| 1444 | + |
| 1445 | Optional setting for modifying the link name presented to the user |
| 1446 | in the Gerrit web-UI. |
| 1447 | + |
| 1448 | Default linkname for custom type is "gitweb". |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1449 | |
| Adrian Goerler | f200707 | 2011-11-10 08:39:55 +0100 | [diff] [blame] | 1450 | [[gitweb.pathSeparator]]gitweb.pathSeparator:: |
| 1451 | + |
| 1452 | Optional character to substitute the standard path separator (slash) in |
| 1453 | project names and branch names. |
| 1454 | + |
| 1455 | By default, Gerrit will use hexadecimal encoding for slashes in project and |
| 1456 | branch names. Some web servers, such as Tomcat, reject this hexadecimal |
| 1457 | encoding in the URL. |
| 1458 | + |
| 1459 | Some alternative gitweb services, such as link:http://gitblit.com[Gitblit], |
| 1460 | allow using an alternative path separator character. In Gitblit, this can be |
| 1461 | configured through the property link:http://gitblit.com/properties.html[web.forwardSlashCharacter]. |
| 1462 | In Gerrit, the alternative path separator can be configured correspondingly |
| 1463 | using the property 'gitweb.pathSeparator'. |
| 1464 | + |
| 1465 | Valid values are the characters '*', '(' and ')'. |
| 1466 | |
| Luca Milanesio | 2531203 | 2013-10-11 11:34:39 +0100 | [diff] [blame] | 1467 | [[gitweb.linkDrafts]]gitweb.urlEncode:: |
| 1468 | + |
| 1469 | Whether or not Gerrit should encode the generated viewer URL. |
| 1470 | + |
| 1471 | Gerrit composes the viewer URL using information about the project, branch, file |
| 1472 | or commit of the target object to be displayed. Typically viewers such as CGit |
| 1473 | and GitWeb do need those parts to be encoded, including the '/' in project's name, |
| 1474 | for being correctly parsed. |
| 1475 | However other viewers could instead require an unencoded URL (e.g. GitHub web |
| 1476 | based viewer) |
| 1477 | + |
| 1478 | Valid values are "true" and "false," default is "true." |
| 1479 | |
| Chad Horohoe | 1dfe36c | 2013-04-12 14:52:56 -0400 | [diff] [blame] | 1480 | [[gitweb.linkDrafts]]gitweb.linkDrafts:: |
| 1481 | + |
| 1482 | Whether or not Gerrit should provide links to gitweb on draft patch sets. |
| 1483 | + |
| 1484 | By default, Gerrit will show links to gitweb on all patch sets. If gitweb |
| 1485 | only allows publicly viewable references, set this to false to remove |
| 1486 | the links to draft patch sets from the change review screen. |
| 1487 | + |
| Luca Milanesio | 2531203 | 2013-10-11 11:34:39 +0100 | [diff] [blame] | 1488 | Valid values are "true" and "false," default is "true". |
| Chad Horohoe | 1dfe36c | 2013-04-12 14:52:56 -0400 | [diff] [blame] | 1489 | |
| Edwin Kempin | 4bbff70 | 2013-01-11 09:59:53 +0100 | [diff] [blame] | 1490 | [[groups]]Section groups |
| 1491 | ~~~~~~~~~~~~~~~~~~~~~~~~ |
| 1492 | |
| 1493 | [[groups.newGroupsVisibleToAll]]groups.newGroupsVisibleToAll:: |
| 1494 | + |
| 1495 | Controls whether newly created groups should be by default visible to |
| 1496 | all registered users. |
| 1497 | + |
| 1498 | By default, false. |
| 1499 | |
| Shane Mc Cormack | 6c2b677 | 2010-01-12 21:56:44 +0000 | [diff] [blame] | 1500 | [[hooks]]Section hooks |
| Remy Bohmer | 203eea3 | 2012-02-19 21:21:36 +0100 | [diff] [blame] | 1501 | ~~~~~~~~~~~~~~~~~~~~~~ |
| Shane Mc Cormack | 6c2b677 | 2010-01-12 21:56:44 +0000 | [diff] [blame] | 1502 | |
| 1503 | See also link:config-hooks.html[Hooks]. |
| 1504 | |
| 1505 | [[hooks.path]]hooks.path:: |
| 1506 | + |
| 1507 | Optional path to hooks, if not specified then `'$site_path'/hooks` will be used. |
| 1508 | |
| 1509 | [[hooks.patchsetCreatedHook]]hooks.patchsetCreatedHook:: |
| 1510 | + |
| 1511 | Optional filename for the patchset created hook, if not specified then |
| 1512 | `patchset-created` will be used. |
| 1513 | |
| David Pursehouse | d556c19 | 2012-06-12 18:34:37 +0900 | [diff] [blame] | 1514 | [[hooks.draftPublishedHook]]hooks.draftPublishedHook:: |
| 1515 | + |
| 1516 | Optional filename for the draft published hook, if not specified then |
| 1517 | `draft-published` will be used. |
| 1518 | |
| Shane Mc Cormack | 6c2b677 | 2010-01-12 21:56:44 +0000 | [diff] [blame] | 1519 | [[hooks.commentAddedHook]]hooks.commentAddedHook:: |
| 1520 | + |
| 1521 | Optional filename for the comment added hook, if not specified then |
| 1522 | `comment-added` will be used. |
| 1523 | |
| 1524 | [[hooks.changeMergedHook]]hooks.changeMergedHook:: |
| 1525 | + |
| 1526 | Optional filename for the change merged hook, if not specified then |
| 1527 | `change-merged` will be used. |
| 1528 | |
| David Pursehouse | f9f3b27 | 2012-09-28 19:58:59 +0900 | [diff] [blame] | 1529 | [[hooks.mergeFailedHook]]hooks.mergeFailedHook:: |
| 1530 | + |
| 1531 | Optional filename for the merge failed hook, if not specified then |
| 1532 | `merge-failed` will be used. |
| 1533 | |
| Shane Mc Cormack | 6c2b677 | 2010-01-12 21:56:44 +0000 | [diff] [blame] | 1534 | [[hooks.changeAbandonedHook]]hooks.changeAbandonedHook:: |
| 1535 | + |
| 1536 | Optional filename for the change abandoned hook, if not specified then |
| 1537 | `change-abandoned` will be used. |
| 1538 | |
| David Pursehouse | a93c930 | 2012-06-15 16:29:26 +0900 | [diff] [blame] | 1539 | [[hooks.changeRestoredHook]]hooks.changeRestoredHook:: |
| 1540 | + |
| 1541 | Optional filename for the change restored hook, if not specified then |
| 1542 | `change-restored` will be used. |
| 1543 | |
| 1544 | [[hooks.refUpdatedHook]]hooks.refUpdatedHook:: |
| 1545 | + |
| 1546 | Optional filename for the ref updated hook, if not specified then |
| 1547 | `ref-updated` will be used. |
| 1548 | |
| David Pursehouse | 2336bd8 | 2012-09-21 12:50:19 +0900 | [diff] [blame] | 1549 | [[hooks.reviewerAddedHook]]hooks.reviewerAddedHook:: |
| 1550 | + |
| 1551 | Optional filename for the reviewer added hook, if not specified then |
| 1552 | `reviewer-added` will be used. |
| 1553 | |
| David Pursehouse | ba3e28d | 2013-07-12 14:48:51 +0900 | [diff] [blame] | 1554 | [[hooks.topicChangedHook]]hooks.topicChangedHook:: |
| 1555 | + |
| 1556 | Optional filename for the topic changed hook, if not specified then |
| 1557 | `topic-changed` will be used. |
| 1558 | |
| David Pursehouse | a93c930 | 2012-06-15 16:29:26 +0900 | [diff] [blame] | 1559 | [[hooks.claSignedHook]]hooks.claSignedHook:: |
| 1560 | + |
| 1561 | Optional filename for the CLA signed hook, if not specified then |
| 1562 | `cla-signed` will be used. |
| 1563 | |
| Chris Harris | f736d6c | 2012-11-21 09:35:56 -0500 | [diff] [blame] | 1564 | [[hooks.refUpdateHook]]hooks.refUpdateHook:: |
| 1565 | + |
| 1566 | Optional filename for the ref update hook, if not specified then |
| 1567 | `ref-update` will be used. |
| 1568 | |
| 1569 | [[hooks.syncHookTimeout]]hooks.syncHookTimeout:: |
| David Pursehouse | 6fdc8d9 | 2012-11-28 12:34:18 +0900 | [diff] [blame] | 1570 | + |
| 1571 | Optional timeout value in seconds for synchronous hooks, if not specified |
| Chris Harris | f736d6c | 2012-11-21 09:35:56 -0500 | [diff] [blame] | 1572 | then 30 seconds will be used. |
| 1573 | |
| Shawn O. Pearce | 309d8d3 | 2009-11-17 16:03:16 -0800 | [diff] [blame] | 1574 | [[http]]Section http |
| 1575 | ~~~~~~~~~~~~~~~~~~~~ |
| 1576 | |
| 1577 | [[http.proxy]]http.proxy:: |
| Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 1578 | + |
| 1579 | URL of the proxy server when making outgoing HTTP |
| 1580 | connections for OpenID login transactions. Syntax |
| 1581 | should be `http://`'hostname'`:`'port'. |
| Shawn O. Pearce | 309d8d3 | 2009-11-17 16:03:16 -0800 | [diff] [blame] | 1582 | |
| 1583 | [[http.proxyUsername]]http.proxyUsername:: |
| Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 1584 | + |
| 1585 | Optional username to authenticate to the HTTP proxy with. |
| Robin Rosenberg | 524a303 | 2012-10-14 14:24:36 +0200 | [diff] [blame] | 1586 | This property is honored only if the username does not |
| Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 1587 | appear in the http.proxy property above. |
| Shawn O. Pearce | 309d8d3 | 2009-11-17 16:03:16 -0800 | [diff] [blame] | 1588 | |
| 1589 | [[http.proxyPassword]]http.proxyPassword:: |
| Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 1590 | + |
| 1591 | Optional password to authenticate to the HTTP proxy with. |
| Robin Rosenberg | 524a303 | 2012-10-14 14:24:36 +0200 | [diff] [blame] | 1592 | This property is honored only if the password does not |
| Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 1593 | appear in the http.proxy property above. |
| Shawn O. Pearce | 309d8d3 | 2009-11-17 16:03:16 -0800 | [diff] [blame] | 1594 | |
| 1595 | |
| 1596 | [[httpd]]Section httpd |
| 1597 | ~~~~~~~~~~~~~~~~~~~~~~ |
| Shawn O. Pearce | fa2486a | 2009-11-11 14:51:30 -0800 | [diff] [blame] | 1598 | |
| 1599 | The httpd section configures the embedded servlet container. |
| 1600 | |
| 1601 | [[httpd.listenUrl]]httpd.listenUrl:: |
| 1602 | + |
| 1603 | Specifies the URLs the internal HTTP daemon should listen for |
| Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 1604 | connections on. The special hostname '*' may be used to listen |
| Shawn O. Pearce | fa2486a | 2009-11-11 14:51:30 -0800 | [diff] [blame] | 1605 | on all local addresses. A context path may optionally be included, |
| 1606 | placing Gerrit Code Review's web address within a subdirectory of |
| 1607 | the server. |
| 1608 | + |
| 1609 | Multiple protocol schemes are supported: |
| 1610 | + |
| 1611 | * `http://`'hostname'`:`'port' |
| 1612 | + |
| 1613 | Plain-text HTTP protocol. If port is not supplied, defaults to 80, |
| 1614 | the standard HTTP port. |
| 1615 | + |
| 1616 | * `https://`'hostname'`:`'port' |
| 1617 | + |
| 1618 | SSL encrypted HTTP protocol. If port is not supplied, defaults to |
| 1619 | 443, the standard HTTPS port. |
| 1620 | + |
| 1621 | Externally facing production sites are encouraged to use a reverse |
| 1622 | proxy configuration and `proxy-https://` (below), rather than using |
| 1623 | the embedded servlet container to implement the SSL processing. |
| 1624 | The proxy server with SSL support is probably easier to configure, |
| 1625 | provides more configuration options to control cipher usage, and |
| 1626 | is likely using natively compiled encryption algorithms, resulting |
| 1627 | in higher throughput. |
| 1628 | + |
| 1629 | * `proxy-http://`'hostname'`:`'port' |
| 1630 | + |
| 1631 | Plain-text HTTP relayed from a reverse proxy. If port is not |
| 1632 | supplied, defaults to 8080. |
| 1633 | + |
| 1634 | Like http, but additional header parsing features are |
| 1635 | enabled to honor X-Forwarded-For, X-Forwarded-Host and |
| 1636 | X-Forwarded-Server. These headers are typically set by Apache's |
| 1637 | link:http://httpd.apache.org/docs/2.2/mod/mod_proxy.html#x-headers[mod_proxy]. |
| 1638 | + |
| 1639 | * `proxy-https://`'hostname'`:`'port' |
| 1640 | + |
| 1641 | Plain text HTTP relayed from a reverse proxy that has already |
| 1642 | handled the SSL encryption/decryption. If port is not supplied, |
| 1643 | defaults to 8080. |
| 1644 | + |
| 1645 | Behaves exactly like proxy-http, but also sets the scheme to assume |
| 1646 | 'https://' is the proper URL back to the server. |
| 1647 | |
| 1648 | + |
| 1649 | If multiple values are supplied, the daemon will listen on all |
| 1650 | of them. |
| 1651 | + |
| 1652 | By default, http://*:8080. |
| 1653 | |
| 1654 | [[httpd.reuseAddress]]httpd.reuseAddress:: |
| 1655 | + |
| 1656 | If true, permits the daemon to bind to the port even if the port |
| 1657 | is already in use. If false, the daemon ensures the port is not |
| 1658 | in use before starting. Busy sites may need to set this to true |
| 1659 | to permit fast restarts. |
| 1660 | + |
| 1661 | By default, true. |
| 1662 | |
| 1663 | [[httpd.requestHeaderSize]]httpd.requestHeaderSize:: |
| 1664 | + |
| 1665 | Size, in bytes, of the buffer used to parse the HTTP headers of an |
| 1666 | incoming HTTP request. The entire request headers, including any |
| 1667 | cookies sent by the browser, must fit within this buffer, otherwise |
| 1668 | the server aborts with the response '413 Request Entity Too Large'. |
| 1669 | + |
| 1670 | One buffer of this size is allocated per active connection. |
| 1671 | Allocating a buffer that is too large wastes memory that cannot be |
| 1672 | reclaimed, allocating a buffer that is too small may cause unexpected |
| 1673 | errors caused by very long Referer URLs or large cookie values. |
| 1674 | + |
| 1675 | By default, 16384 (16 K), which is sufficient for most OpenID and |
| 1676 | other web-based single-sign-on integrations. |
| 1677 | |
| Chulho Yang | b72ff8f | 2013-07-04 02:35:53 -0400 | [diff] [blame] | 1678 | [[httpd.sslCrl]]httpd.sslCrl:: |
| 1679 | + |
| 1680 | Path of the certificate revocation list file in PEM format. This |
| 1681 | crl file is optional, and available for CLIENT_SSL_CERT_LDAP |
| 1682 | authentication. |
| 1683 | + |
| 1684 | To create and view a crl using openssl: |
| 1685 | + |
| 1686 | ---- |
| 1687 | openssl ca -gencrl -out crl.pem |
| 1688 | openssl crl -in crl.pem -text |
| 1689 | ---- |
| 1690 | + |
| 1691 | If not absolute, the path is resolved relative to `$site_path`. |
| 1692 | + |
| 1693 | By default, `$site_path/etc/crl.pem`. |
| 1694 | |
| Shawn O. Pearce | fa2486a | 2009-11-11 14:51:30 -0800 | [diff] [blame] | 1695 | [[httpd.sslKeyStore]]httpd.sslKeyStore:: |
| 1696 | + |
| 1697 | Path of the Java keystore containing the server's SSL certificate |
| 1698 | and private key. This keystore is required for `https://` in URL. |
| 1699 | + |
| 1700 | To create a self-signed certificate for simple internal usage: |
| 1701 | + |
| Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 1702 | ---- |
| 1703 | keytool -keystore keystore -alias jetty -genkey -keyalg RSA |
| 1704 | chmod 600 keystore |
| 1705 | ---- |
| Shawn O. Pearce | fa2486a | 2009-11-11 14:51:30 -0800 | [diff] [blame] | 1706 | + |
| 1707 | If not absolute, the path is resolved relative to `$site_path`. |
| 1708 | + |
| Shawn O. Pearce | c5fed82 | 2009-11-17 16:10:10 -0800 | [diff] [blame] | 1709 | By default, `$site_path/etc/keystore`. |
| Shawn O. Pearce | fa2486a | 2009-11-11 14:51:30 -0800 | [diff] [blame] | 1710 | |
| 1711 | [[httpd.sslKeyPassword]]httpd.sslKeyPassword:: |
| 1712 | + |
| 1713 | Password used to decrypt the private portion of the sslKeyStore. |
| David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 1714 | Java keystores require a password, even if the administrator |
| Shawn O. Pearce | fa2486a | 2009-11-11 14:51:30 -0800 | [diff] [blame] | 1715 | doesn't want to enable one. |
| 1716 | + |
| 1717 | If set to the empty string the embedded server will prompt for the |
| 1718 | password during startup. |
| 1719 | + |
| 1720 | By default, `gerrit`. |
| 1721 | |
| Shawn O. Pearce | 1766f50 | 2010-01-15 10:49:46 -0800 | [diff] [blame] | 1722 | [[httpd.requestLog]]httpd.requestLog:: |
| 1723 | + |
| 1724 | Enable (or disable) the `'$site_path'/logs/httpd_log` request log. |
| 1725 | If enabled, an NCSA combined log format request log file is written |
| 1726 | out by the internal HTTP daemon. |
| 1727 | + |
| 1728 | By default, true if httpd.listenUrl uses http:// or https://, |
| 1729 | and false if httpd.listenUrl uses proxy-http:// or proxy-https://. |
| 1730 | |
| Shawn O. Pearce | fa2486a | 2009-11-11 14:51:30 -0800 | [diff] [blame] | 1731 | [[httpd.acceptorThreads]]httpd.acceptorThreads:: |
| 1732 | + |
| 1733 | Number of worker threads dedicated to accepting new incoming TCP |
| David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 1734 | connections and allocating them connection-specific resources. |
| Shawn O. Pearce | fa2486a | 2009-11-11 14:51:30 -0800 | [diff] [blame] | 1735 | + |
| 1736 | By default, 2, which should be suitable for most high-traffic sites. |
| 1737 | |
| 1738 | [[httpd.minThreads]]httpd.minThreads:: |
| 1739 | + |
| 1740 | Minimum number of spare threads to keep in the worker thread pool. |
| 1741 | This number must be at least 1 larger than httpd.acceptorThreads |
| David Pursehouse | 9246356 | 2013-06-24 10:16:28 +0900 | [diff] [blame] | 1742 | multiplied by the number of httpd.listenUrls configured. |
| Shawn O. Pearce | fa2486a | 2009-11-11 14:51:30 -0800 | [diff] [blame] | 1743 | + |
| 1744 | By default, 5, suitable for most lower-volume traffic sites. |
| 1745 | |
| 1746 | [[httpd.maxThreads]]httpd.maxThreads:: |
| 1747 | + |
| 1748 | Maximum number of threads to permit in the worker thread pool. |
| 1749 | + |
| 1750 | By default 25, suitable for most lower-volume traffic sites. |
| 1751 | |
| 1752 | [[httpd.maxQueued]]httpd.maxQueued:: |
| 1753 | + |
| 1754 | Maximum number of client connections which can enter the worker |
| 1755 | thread pool waiting for a worker thread to become available. |
| 1756 | 0 disables the queue and permits infinite number of connections. |
| 1757 | + |
| 1758 | By default 50. |
| 1759 | |
| Shawn O. Pearce | e5452b7 | 2010-01-15 14:32:50 -0800 | [diff] [blame] | 1760 | [[httpd.maxWait]]httpd.maxWait:: |
| 1761 | + |
| David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 1762 | Maximum amount of time a client will wait for an available |
| Shawn O. Pearce | e5452b7 | 2010-01-15 14:32:50 -0800 | [diff] [blame] | 1763 | thread to handle a project clone, fetch or push request over the |
| 1764 | smart HTTP transport. |
| 1765 | + |
| 1766 | Values should use common unit suffixes to express their setting: |
| 1767 | + |
| 1768 | * s, sec, second, seconds |
| 1769 | * m, min, minute, minutes |
| 1770 | * h, hr, hour, hours |
| 1771 | * d, day, days |
| 1772 | * w, week, weeks (`1 week` is treated as `7 days`) |
| 1773 | * mon, month, months (`1 month` is treated as `30 days`) |
| 1774 | * y, year, years (`1 year` is treated as `365 days`) |
| 1775 | |
| 1776 | + |
| 1777 | If a unit suffix is not specified, `minutes` is assumed. If 0 |
| 1778 | is supplied, the maximum age is infinite and connections will not |
| 1779 | abort until the client disconnects. |
| 1780 | + |
| 1781 | By default, 5 minutes. |
| 1782 | |
| Luca Milanesio | ce7b745 | 2013-06-18 11:40:49 +0100 | [diff] [blame] | 1783 | [[httpd.filterClass]]httpd.filterClass:: |
| 1784 | + |
| 1785 | Class that implements the javax.servlet.Filter interface |
| 1786 | for filtering any HTTP related traffic going through the Gerrit |
| 1787 | HTTP protocol. |
| 1788 | Class is loaded and configured in the Gerrit Jetty container |
| 1789 | and run in front of all Gerrit URL handlers, allowing the filter |
| 1790 | to inspect, modify, allow or reject each request. |
| 1791 | It needs to be provided as JAR library |
| 1792 | under $GERRIT_SITE/lib as it is resolved using the default Gerrit class |
| 1793 | loader and cannot be dynamically loaded by a plugin. |
| 1794 | + |
| 1795 | Failing to load the Filter class would result in a Gerrit start-up |
| 1796 | failure, as this class is supposed to provide mandatory filtering |
| 1797 | in front of Gerrit HTTP protocol. |
| 1798 | + |
| David Pursehouse | 42f4204 | 2013-08-01 14:02:25 +0900 | [diff] [blame] | 1799 | Typical usage is in conjunction with the `auth.type=HTTP` as replacement |
| Luca Milanesio | ce7b745 | 2013-06-18 11:40:49 +0100 | [diff] [blame] | 1800 | of an Apache HTTP proxy layer as security enforcement on top of Gerrit |
| 1801 | by returning a trusted username as HTTP Header. |
| 1802 | + |
| 1803 | Example of using a security library secure.jar under $GERRIT_SITE/lib |
| 1804 | that provides a org.anyorg.MySecureFilter Servlet Filter that enforces |
| 1805 | a trusted username in the `TRUSTED_USER` HTTP Header: |
| 1806 | |
| 1807 | ---- |
| 1808 | [auth] |
| 1809 | type = HTTP |
| 1810 | httpHeader = TRUSTED_USER |
| 1811 | |
| 1812 | [http] |
| 1813 | filterClass = org.anyorg.MySecureFilter |
| 1814 | ---- |
| Shawn O. Pearce | fa2486a | 2009-11-11 14:51:30 -0800 | [diff] [blame] | 1815 | |
| Juan Hernandez | ec51256 | 2013-08-06 16:30:50 +0200 | [diff] [blame] | 1816 | [[httpd.robotsFile]]httpd.robotsFile:: |
| 1817 | + |
| 1818 | Location of an external robots.txt file to be used instead of the one |
| 1819 | bundled with the .war of the application. |
| 1820 | + |
| 1821 | If not absolute, the path is resolved relative to `$site_path`. |
| 1822 | + |
| 1823 | If the file doesn't exist or can't be read the default robots.txt file |
| 1824 | bundled with the .war will be used instead. |
| 1825 | |
| David Pursehouse | 6d45843 | 2013-08-23 16:17:18 +0900 | [diff] [blame] | 1826 | [[index]]Section index |
| 1827 | ~~~~~~~~~~~~~~~~~~~~~~ |
| 1828 | |
| 1829 | The index section configures the secondary index. |
| 1830 | |
| David Pursehouse | 3fc5ee3 | 2014-03-17 18:35:32 +0900 | [diff] [blame] | 1831 | Note that after enabling the secondary index, the index must be built |
| 1832 | using the link:pgm-reindex.html[reindex program] before restarting the |
| 1833 | Gerrit server. |
| 1834 | |
| 1835 | Open and closed changes are indexed in separate indexes named |
| 1836 | 'changes_open' and 'changes_closed' respectively. |
| 1837 | |
| David Pursehouse | 6d45843 | 2013-08-23 16:17:18 +0900 | [diff] [blame] | 1838 | [[index.type]]index.type:: |
| 1839 | + |
| 1840 | Type of secondary indexing employed by Gerrit. The supported |
| 1841 | values are: |
| 1842 | + |
| 1843 | * `LUCENE` |
| 1844 | + |
| 1845 | A link:http://lucene.apache.org/[Lucene] index is used. |
| 1846 | + |
| 1847 | * `SOLR` |
| 1848 | + |
| 1849 | A link:http://lucene.apache.org/solr/[Solr] index is used. |
| 1850 | + |
| 1851 | * `SQL` |
| 1852 | + |
| 1853 | No secondary index. Not all query operators are supported. Other |
| 1854 | query operators are routed through the standard SQL query engine. |
| 1855 | |
| 1856 | + |
| 1857 | By default, `SQL`. |
| David Pursehouse | 15c4328 | 2013-12-04 13:32:59 +0900 | [diff] [blame] | 1858 | |
| David Pursehouse | 904db30 | 2014-03-17 18:55:38 +0900 | [diff] [blame] | 1859 | [[index.threads]]index.threads:: |
| 1860 | + |
| 1861 | Determines the number of threads to use for indexing. |
| 1862 | + |
| 1863 | Defaults to 1 if not set, or set to a negative value. |
| 1864 | |
| David Pursehouse | 00c8214 | 2014-01-22 17:41:09 +0900 | [diff] [blame] | 1865 | [[index.name.ramBufferSize]]index.name.ramBufferSize:: |
| 1866 | + |
| 1867 | Only used when the type is `LUCENE`. |
| 1868 | + |
| 1869 | Determines the amount of RAM that may be used for buffering added documents |
| 1870 | and deletions before they are flushed to the index. See the |
| 1871 | link:http://lucene.apache.org/core/4_6_0/core/org/apache/lucene/index/LiveIndexWriterConfig.html#setRAMBufferSizeMB(double)[ |
| 1872 | Lucene documentation] for further details. |
| 1873 | + |
| 1874 | Defaults to 16M. |
| 1875 | |
| 1876 | [[index.name.maxBufferedDocs]]index.name.maxBufferedDocs:: |
| 1877 | + |
| 1878 | Only used when the type is `LUCENE`. |
| 1879 | + |
| 1880 | Determines the minimal number of documents required before the buffered |
| 1881 | in-memory documents are flushed to the index. Large values generally |
| 1882 | give faster indexing. See the |
| 1883 | link:http://lucene.apache.org/core/4_6_0/core/org/apache/lucene/index/LiveIndexWriterConfig.html#setMaxBufferedDocs(int)[ |
| 1884 | Lucene documentation] for further details. |
| 1885 | + |
| 1886 | Defaults to -1, meaning no maximum is set and the writer will flush |
| 1887 | according to RAM usage. |
| 1888 | |
| Dave Borowitz | d08b045 | 2014-02-13 11:56:03 -0800 | [diff] [blame] | 1889 | [[index.name.commitWithin]]index.name.commitWithin:: |
| 1890 | + |
| 1891 | Only used when the type is `LUCENE`. |
| 1892 | + |
| 1893 | Determines the period at which changes are automatically committed to |
| 1894 | stable store on disk. This is a costly operation and may block |
| 1895 | additional index writes, so lower with caution. |
| 1896 | + |
| Bruce Zu | af058e6 | 2014-03-21 10:03:05 +0800 | [diff] [blame^] | 1897 | If zero, changes are committed after every write. This is very costly |
| 1898 | but may be useful if offline reindexing is infeasible, or for development |
| 1899 | servers. |
| Dave Borowitz | d08b045 | 2014-02-13 11:56:03 -0800 | [diff] [blame] | 1900 | + |
| Bruce Zu | af058e6 | 2014-03-21 10:03:05 +0800 | [diff] [blame^] | 1901 | Values can be specified using standard time unit abbreviations (`ms`, `sec`, |
| 1902 | `min`, etc.). |
| David Pursehouse | 9354c1a | 2014-03-22 12:23:43 -0700 | [diff] [blame] | 1903 | + |
| Bruce Zu | af058e6 | 2014-03-21 10:03:05 +0800 | [diff] [blame^] | 1904 | If negative, `commitWithin` is disabled. Changes are flushed to disk when |
| 1905 | the in-memory buffer fills, but only committed and guaranteed to be synced |
| 1906 | to disk when the process finishes. |
| David Pursehouse | 3cd6de0 | 2014-03-14 16:13:56 +0900 | [diff] [blame] | 1907 | |
| Dave Borowitz | d08b045 | 2014-02-13 11:56:03 -0800 | [diff] [blame] | 1908 | Defaults to 300000 ms (5 minutes). |
| 1909 | |
| David Pursehouse | 00c8214 | 2014-01-22 17:41:09 +0900 | [diff] [blame] | 1910 | Sample index configuration: |
| 1911 | ---- |
| 1912 | [index] |
| 1913 | type = LUCENE |
| 1914 | |
| 1915 | [index "changes_open"] |
| 1916 | ramBufferSize = 60 m |
| 1917 | maxBufferedDocs = 3000 |
| 1918 | |
| 1919 | [index "changes_closed"] |
| 1920 | ramBufferSize = 20 m |
| 1921 | maxBufferedDocs = 500 |
| 1922 | ---- |
| 1923 | |
| Shawn O. Pearce | 8efb2a7 | 2009-08-18 19:45:33 -0700 | [diff] [blame] | 1924 | [[ldap]]Section ldap |
| 1925 | ~~~~~~~~~~~~~~~~~~~~ |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1926 | |
| David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 1927 | LDAP integration is only enabled if `auth.type` is set to |
| Sasa Zivkov | eabc897 | 2010-10-04 15:47:08 +0200 | [diff] [blame] | 1928 | `HTTP_LDAP`, `LDAP` or `CLIENT_SSL_CERT_LDAP`. See above for a |
| David Pursehouse | 42f4204 | 2013-08-01 14:02:25 +0900 | [diff] [blame] | 1929 | detailed description of the `auth.type` settings and their |
| Sasa Zivkov | eabc897 | 2010-10-04 15:47:08 +0200 | [diff] [blame] | 1930 | implications. |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1931 | |
| Shawn O. Pearce | 02c2e80 | 2009-10-29 14:46:03 -0700 | [diff] [blame] | 1932 | An example LDAP configuration follows, and then discussion of |
| 1933 | the parameters introduced here. Suitable defaults for most |
| 1934 | parameters are automatically guessed based on the type of server |
| 1935 | detected during startup. The guessed defaults support both |
| 1936 | link:http://www.ietf.org/rfc/rfc2307.txt[RFC 2307] and Active |
| 1937 | Directory. |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1938 | |
| Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 1939 | ---- |
| 1940 | [ldap] |
| 1941 | server = ldap://ldap.example.com |
| 1942 | |
| 1943 | accountBase = ou=people,dc=example,dc=com |
| 1944 | accountPattern = (&(objectClass=person)(uid=${username})) |
| 1945 | accountFullName = displayName |
| 1946 | accountEmailAddress = mail |
| 1947 | |
| 1948 | groupBase = ou=groups,dc=example,dc=com |
| 1949 | groupMemberPattern = (&(objectClass=group)(member=${dn})) |
| 1950 | ---- |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1951 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1952 | [[ldap.server]]ldap.server:: |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1953 | + |
| 1954 | URL of the organization's LDAP server to query for user information |
| 1955 | and group membership from. Must be of the form `ldap://host` or |
| 1956 | `ldaps://host` to bind with either a plaintext or SSL connection. |
| Shawn O. Pearce | f7e065e | 2009-09-26 20:01:10 -0700 | [diff] [blame] | 1957 | + |
| David Pursehouse | 42f4204 | 2013-08-01 14:02:25 +0900 | [diff] [blame] | 1958 | If `auth.type` is `LDAP` this setting should use `ldaps://` to |
| Shawn O. Pearce | f7e065e | 2009-09-26 20:01:10 -0700 | [diff] [blame] | 1959 | ensure the end user's plaintext password is transmitted only over |
| 1960 | an encrypted connection. |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1961 | |
| Shawn O. Pearce | 02c2e80 | 2009-10-29 14:46:03 -0700 | [diff] [blame] | 1962 | [[ldap.sslVerify]]ldap.sslVerify:: |
| 1963 | + |
| 1964 | If false and ldap.server is an `ldaps://` style URL, Gerrit |
| 1965 | will not verify the server certificate when it connects to |
| 1966 | perform a query. |
| 1967 | + |
| 1968 | By default, true, requiring the certificate to be verified. |
| 1969 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1970 | [[ldap.username]]ldap.username:: |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1971 | + |
| 1972 | _(Optional)_ Username to bind to the LDAP server with. If not set, |
| 1973 | an anonymous connection to the LDAP server is attempted. |
| 1974 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 1975 | [[ldap.password]]ldap.password:: |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 1976 | + |
| 1977 | _(Optional)_ Password for the user identified by `ldap.username`. |
| 1978 | If not set, an anonymous (or passwordless) connection to the LDAP |
| 1979 | server is attempted. |
| 1980 | |
| Ben Wu | 0410a15 | 2010-06-04 16:17:24 +0800 | [diff] [blame] | 1981 | [[ldap.referral]]ldap.referral:: |
| 1982 | + |
| 1983 | _(Optional)_ How an LDAP referral should be handled if it is |
| 1984 | encountered during directory traversal. Set to `follow` to |
| James Y Knight | 1244ed0 | 2011-01-04 02:40:32 -0500 | [diff] [blame] | 1985 | automatically follow any referrals, or `ignore` to ignore the |
| 1986 | referrals. |
| Ben Wu | 0410a15 | 2010-06-04 16:17:24 +0800 | [diff] [blame] | 1987 | + |
| 1988 | By default, `ignore`. |
| 1989 | |
| Sasa Zivkov | 100bd4b | 2011-11-07 14:58:46 +0100 | [diff] [blame] | 1990 | [[ldap.readTimeout]]ldap.readTimeout:: |
| 1991 | + |
| 1992 | _(Optional)_ The read timeout for an LDAP operation. The value is |
| 1993 | in the usual time-unit format like "1 s", "100 ms", etc... |
| 1994 | 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] | 1995 | threads in case the LDAP server becomes slow. |
| Sasa Zivkov | 100bd4b | 2011-11-07 14:58:46 +0100 | [diff] [blame] | 1996 | + |
| 1997 | By default there is no timeout and Gerrit will wait for the LDAP |
| 1998 | server to respond until the TCP connection times out. |
| 1999 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 2000 | [[ldap.accountBase]]ldap.accountBase:: |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 2001 | + |
| 2002 | Root of the tree containing all user accounts. This is typically |
| 2003 | of the form `ou=people,dc=example,dc=com`. |
| 2004 | |
| Shawn O. Pearce | 304ccdb | 2009-08-25 12:25:27 -0700 | [diff] [blame] | 2005 | [[ldap.accountScope]]ldap.accountScope:: |
| 2006 | + |
| 2007 | Scope of the search performed for accounts. Must be one of: |
| 2008 | + |
| 2009 | * `one`: Search only one level below accountBase, but not recursive |
| 2010 | * `sub` or `subtree`: Search recursively below accountBase |
| 2011 | * `base` or `object`: Search exactly accountBase; probably not desired |
| 2012 | |
| 2013 | + |
| 2014 | Default is `subtree` as many directories have several levels. |
| 2015 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 2016 | [[ldap.accountPattern]]ldap.accountPattern:: |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 2017 | + |
| 2018 | Query pattern to use when searching for a user account. This may be |
| 2019 | any valid LDAP query expression, including the standard `(&...)` and |
| David Pursehouse | 42f4204 | 2013-08-01 14:02:25 +0900 | [diff] [blame] | 2020 | `(|...)` operators. If `auth.type` is `HTTP_LDAP` then the variable |
| Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 2021 | `${username}` is replaced with a parameter set to the username |
| David Pursehouse | 42f4204 | 2013-08-01 14:02:25 +0900 | [diff] [blame] | 2022 | 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] | 2023 | the variable `${username}` is replaced by the string entered by |
| Shawn O. Pearce | f7e065e | 2009-09-26 20:01:10 -0700 | [diff] [blame] | 2024 | the end user. |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 2025 | + |
| 2026 | This pattern is used to search the objects contained directly under |
| 2027 | the `ldap.accountBase` tree. A typical setting for this parameter |
| Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 2028 | is `(uid=${username})` or `(cn=${username})`, but the proper |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 2029 | setting depends on the LDAP schema used by the directory server. |
| 2030 | + |
| Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 2031 | Default is `(uid=${username})` for RFC 2307 servers, |
| Shawn O. Pearce | 02c2e80 | 2009-10-29 14:46:03 -0700 | [diff] [blame] | 2032 | and `(&(objectClass=user)(sAMAccountName=${username}))` |
| 2033 | for Active Directory. |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 2034 | |
| Shawn O. Pearce | 37dc1f8 | 2009-08-19 09:49:07 -0700 | [diff] [blame] | 2035 | [[ldap.accountFullName]]ldap.accountFullName:: |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 2036 | + |
| 2037 | _(Optional)_ Name of an attribute on the user account object which |
| 2038 | contains the initial value for the user's full name field in Gerrit. |
| 2039 | Typically this is the `displayName` property in LDAP, but could |
| 2040 | also be `legalName` or `cn`. |
| 2041 | + |
| David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 2042 | Attribute values may be concatenated with literal strings. For |
| 2043 | example to join given name and surname together, use the pattern |
| Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 2044 | `${givenName} ${SN}`. |
| Shawn O. Pearce | b86ae00 | 2009-09-26 16:54:05 -0700 | [diff] [blame] | 2045 | + |
| Shawn O. Pearce | 3ca1dcf | 2009-08-20 08:56:23 -0700 | [diff] [blame] | 2046 | If set, users will be unable to modify their full name field, as |
| 2047 | Gerrit will populate it only from the LDAP data. |
| 2048 | + |
| Shawn O. Pearce | 02c2e80 | 2009-10-29 14:46:03 -0700 | [diff] [blame] | 2049 | Default is `displayName` for RFC 2307 servers, |
| 2050 | and `${givenName} ${sn}` for Active Directory. |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 2051 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 2052 | [[ldap.accountEmailAddress]]ldap.accountEmailAddress:: |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 2053 | + |
| 2054 | _(Optional)_ Name of an attribute on the user account object which |
| 2055 | contains the user's Internet email address, as defined by this |
| 2056 | LDAP server. |
| 2057 | + |
| Shawn O. Pearce | b86ae00 | 2009-09-26 16:54:05 -0700 | [diff] [blame] | 2058 | Attribute values may be concatenated with literal strings, |
| 2059 | for example to set the email address to the lowercase form |
| 2060 | of sAMAccountName followed by a constant domain name, use |
| Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 2061 | `${sAMAccountName.toLowerCase}@example.com`. |
| Shawn O. Pearce | b86ae00 | 2009-09-26 16:54:05 -0700 | [diff] [blame] | 2062 | + |
| Shawn O. Pearce | 3ca1dcf | 2009-08-20 08:56:23 -0700 | [diff] [blame] | 2063 | If set, the preferred email address will be prefilled from LDAP, |
| David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 2064 | but users may still be able to register additional email addresses, |
| Shawn O. Pearce | 3ca1dcf | 2009-08-20 08:56:23 -0700 | [diff] [blame] | 2065 | and select a different preferred email address. |
| 2066 | + |
| Shawn O. Pearce | 02c2e80 | 2009-10-29 14:46:03 -0700 | [diff] [blame] | 2067 | Default is `mail`. |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 2068 | |
| Shawn O. Pearce | 59e0922 | 2009-08-19 09:04:49 -0700 | [diff] [blame] | 2069 | [[ldap.accountSshUserName]]ldap.accountSshUserName:: |
| 2070 | + |
| 2071 | _(Optional)_ Name of an attribute on the user account object which |
| 2072 | contains the initial value for the user's SSH username field in |
| 2073 | Gerrit. Typically this is the `uid` property in LDAP, but could |
| 2074 | also be `cn`. Administrators should prefer to match the attribute |
| 2075 | corresponding to the user's workstation username, as this is what |
| 2076 | SSH clients will default to. |
| 2077 | + |
| Shawn O. Pearce | b86ae00 | 2009-09-26 16:54:05 -0700 | [diff] [blame] | 2078 | Attribute values may also be forced to lowercase, or to uppercase in |
| Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 2079 | an expression. For example, `${sAMAccountName.toLowerCase}` will |
| Shawn O. Pearce | b86ae00 | 2009-09-26 16:54:05 -0700 | [diff] [blame] | 2080 | force the value of sAMAccountName, if defined, to be all lowercase. |
| 2081 | The suffix `.toUpperCase` can be used for the other direction. |
| 2082 | The suffix `.localPart` can be used to split attribute values of |
| 2083 | 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] | 2084 | example `${userPrincipalName.localPart}` would provide only 'user'. |
| Shawn O. Pearce | b86ae00 | 2009-09-26 16:54:05 -0700 | [diff] [blame] | 2085 | + |
| Shawn O. Pearce | 3ca1dcf | 2009-08-20 08:56:23 -0700 | [diff] [blame] | 2086 | If set, users will be unable to modify their SSH username field, as |
| 2087 | Gerrit will populate it only from the LDAP data. |
| 2088 | + |
| Shawn O. Pearce | 02c2e80 | 2009-10-29 14:46:03 -0700 | [diff] [blame] | 2089 | Default is `uid` for RFC 2307 servers, |
| 2090 | and `${sAMAccountName.toLowerCase}` for Active Directory. |
| Shawn O. Pearce | 59e0922 | 2009-08-19 09:04:49 -0700 | [diff] [blame] | 2091 | |
| Shawn O. Pearce | 7d25f78 | 2009-10-30 08:01:03 -0700 | [diff] [blame] | 2092 | [[ldap.accountMemberField]]ldap.accountMemberField:: |
| Anthony | 93de7db | 2009-10-03 10:01:50 -0400 | [diff] [blame] | 2093 | + |
| 2094 | _(Optional)_ Name of an attribute on the user account object which |
| Shawn O. Pearce | 7d25f78 | 2009-10-30 08:01:03 -0700 | [diff] [blame] | 2095 | contains the groups the user is part of. Typically used for Active |
| 2096 | Directory servers. |
| Anthony | 93de7db | 2009-10-03 10:01:50 -0400 | [diff] [blame] | 2097 | + |
| Shawn O. Pearce | 02c2e80 | 2009-10-29 14:46:03 -0700 | [diff] [blame] | 2098 | Default is unset for RFC 2307 servers (disabled) |
| 2099 | and `memberOf` for Active Directory. |
| Anthony | 93de7db | 2009-10-03 10:01:50 -0400 | [diff] [blame] | 2100 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 2101 | [[ldap.groupBase]]ldap.groupBase:: |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 2102 | + |
| 2103 | Root of the tree containing all group objects. This is typically |
| 2104 | of the form `ou=groups,dc=example,dc=com`. |
| 2105 | |
| Shawn O. Pearce | 304ccdb | 2009-08-25 12:25:27 -0700 | [diff] [blame] | 2106 | [[ldap.groupScope]]ldap.groupScope:: |
| 2107 | + |
| 2108 | Scope of the search performed for group objects. Must be one of: |
| 2109 | + |
| 2110 | * `one`: Search only one level below groupBase, but not recursive |
| 2111 | * `sub` or `subtree`: Search recursively below groupBase |
| 2112 | * `base` or `object`: Search exactly groupBase; probably not desired |
| 2113 | |
| 2114 | + |
| 2115 | Default is `subtree` as many directories have several levels. |
| 2116 | |
| Shawn O. Pearce | 7d25f78 | 2009-10-30 08:01:03 -0700 | [diff] [blame] | 2117 | [[ldap.groupPattern]]ldap.groupPattern:: |
| 2118 | + |
| 2119 | Query pattern used when searching for an LDAP group to connect |
| 2120 | to a Gerrit group. This may be any valid LDAP query expression, |
| 2121 | including the standard `(&...)` and `(|...)` operators. The variable |
| Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 2122 | `${groupname}` is replaced with the search term supplied by the |
| Shawn O. Pearce | 7d25f78 | 2009-10-30 08:01:03 -0700 | [diff] [blame] | 2123 | group owner. |
| 2124 | + |
| Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 2125 | Default is `(cn=${groupname})` for RFC 2307, |
| 2126 | and `(&(objectClass=group)(cn=${groupname}))` for Active Directory. |
| Shawn O. Pearce | 7d25f78 | 2009-10-30 08:01:03 -0700 | [diff] [blame] | 2127 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 2128 | [[ldap.groupMemberPattern]]ldap.groupMemberPattern:: |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 2129 | + |
| 2130 | Query pattern to use when searching for the groups that a user |
| 2131 | account is currently a member of. This may be any valid LDAP query |
| 2132 | expression, including the standard `(&...)` and `(|...)` operators. |
| 2133 | + |
| David Pursehouse | 42f4204 | 2013-08-01 14:02:25 +0900 | [diff] [blame] | 2134 | If `auth.type` is `HTTP_LDAP` then the variable `${username}` is |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 2135 | replaced with a parameter set to the username that was supplied |
| 2136 | by the HTTP server. Other variables appearing in the pattern, |
| Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 2137 | such as `${fooBarAttribute}`, are replaced with the value of the |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 2138 | corresponding attribute (in this case, `fooBarAttribute`) as read |
| 2139 | from the user's account object matched under `ldap.accountBase`. |
| Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 2140 | Attributes such as `${dn}` or `${uidNumber}` may be useful. |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 2141 | + |
| Scott Dial | 5045750 | 2013-08-11 16:52:51 -0400 | [diff] [blame] | 2142 | Default is `(|(memberUid=${username})(gidNumber=${gidNumber}))` for |
| 2143 | RFC 2307, and unset (disabled) for Active Directory. |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 2144 | |
| Auke Schrijnen | 5780913 | 2012-09-26 21:05:39 +0200 | [diff] [blame] | 2145 | [[ldap.groupName]]ldap.groupName:: |
| 2146 | + |
| David Pursehouse | 39489ae | 2012-10-12 13:50:04 +0900 | [diff] [blame] | 2147 | _(Optional)_ Name of the attribute on the group object which contains |
| 2148 | the value to use as the group name in Gerrit. |
| Auke Schrijnen | 5780913 | 2012-09-26 21:05:39 +0200 | [diff] [blame] | 2149 | + |
| David Pursehouse | 39489ae | 2012-10-12 13:50:04 +0900 | [diff] [blame] | 2150 | Typically the attribute name is `cn` for RFC 2307 and Active Directory |
| 2151 | servers. For other servers the attribute name may differ, for example |
| 2152 | `apple-group-realname` on Apple MacOS X Server. |
| Auke Schrijnen | 5780913 | 2012-09-26 21:05:39 +0200 | [diff] [blame] | 2153 | + |
| David Pursehouse | 39489ae | 2012-10-12 13:50:04 +0900 | [diff] [blame] | 2154 | It is also possible to specify a literal string containing a pattern of |
| 2155 | attribute values. For example to create a Gerrit group name consisting of |
| 2156 | LDAP group name and group ID, use the pattern `${cn} (${gidNumber})`. |
| 2157 | + |
| 2158 | Default is `cn`. |
| Auke Schrijnen | 5780913 | 2012-09-26 21:05:39 +0200 | [diff] [blame] | 2159 | |
| Edwin Kempin | b3b0d29 | 2011-09-14 14:17:34 +0200 | [diff] [blame] | 2160 | [[ldap.localUsernameToLowerCase]]ldap.localUsernameToLowerCase:: |
| 2161 | + |
| 2162 | Converts the local username, that is used to login into the Gerrit |
| 2163 | WebUI, to lower case before doing the LDAP authentication. By setting |
| 2164 | this parameter to true, a case insensitive login to the Gerrit WebUI |
| 2165 | can be achieved. |
| 2166 | + |
| 2167 | If set, it must be ensured that the local usernames for all existing |
| 2168 | accounts are converted to lower case, otherwise a user that has a |
| David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 2169 | 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] | 2170 | anymore. The local usernames for the existing accounts can be |
| 2171 | converted to lower case by running the server program |
| 2172 | link:pgm-LocalUsernamesToLowerCase.html[LocalUsernamesToLowerCase]. |
| 2173 | Please be aware that the conversion of the local usernames to lower |
| 2174 | case can't be undone. For newly created accounts the local username |
| 2175 | will be directly stored in lower case. |
| 2176 | + |
| 2177 | By default, unset/false. |
| Shawn O. Pearce | 302a7dd | 2009-08-18 19:33:15 -0700 | [diff] [blame] | 2178 | |
| Robin Rosenberg | a3baed0 | 2012-10-14 14:09:32 +0200 | [diff] [blame] | 2179 | [[ldap.authentication]]ldap.authentication:: |
| 2180 | + |
| 2181 | Defines how Gerrit authenticates with the server. When set to `GSSAPI` |
| 2182 | Gerrit will use Kerberos. To use kerberos the |
| 2183 | `java.security.auth.login.config` system property must point to a |
| 2184 | login to a JAAS configuration file and, if Java 6 is used, the system |
| 2185 | property `java.security.krb5.conf` must point to the appropriate |
| 2186 | krb5.ini file with references to the KDC. |
| 2187 | |
| 2188 | Typical jaas.conf. |
| 2189 | |
| 2190 | ---- |
| 2191 | KerberosLogin { |
| 2192 | com.sun.security.auth.module.Krb5LoginModule |
| 2193 | required |
| 2194 | useTicketCache=true |
| 2195 | doNotPrompt=true |
| 2196 | renewTGT=true; |
| 2197 | }; |
| 2198 | ---- |
| 2199 | |
| 2200 | See Java documentation on how to create the krb5.ini file. |
| 2201 | |
| 2202 | Note the `renewTGT` property to make sure the TGT does not expire, |
| 2203 | and `useTicketCache` to use the TGT supplied by the operating system. As |
| 2204 | the whole point of using GSSAPI is to have passwordless authentication |
| David Pursehouse | 9246356 | 2013-06-24 10:16:28 +0900 | [diff] [blame] | 2205 | to the LDAP service, this option does not acquire a new TGT on its own. |
| Robin Rosenberg | a3baed0 | 2012-10-14 14:09:32 +0200 | [diff] [blame] | 2206 | |
| 2207 | On Windows servers the registry key `HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\Lsa\Kerberos\Parameters` |
| 2208 | must have the DWORD value `allowtgtsessionkey` set to 1 and the account must not |
| 2209 | have local administrator privileges. |
| 2210 | |
| Shawn O. Pearce | 8efb2a7 | 2009-08-18 19:45:33 -0700 | [diff] [blame] | 2211 | [[mimetype]]Section mimetype |
| 2212 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| Shawn O. Pearce | 01cb1190 | 2009-07-15 08:19:01 -0700 | [diff] [blame] | 2213 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 2214 | [[mimetype.name.safe]]mimetype.<name>.safe:: |
| Shawn O. Pearce | 01cb1190 | 2009-07-15 08:19:01 -0700 | [diff] [blame] | 2215 | + |
| 2216 | If set to true, files with the MIME type `<name>` will be sent as |
| 2217 | direct downloads to the user's browser, rather than being wrapped up |
| 2218 | inside of zipped archives. The type name may be a complete type |
| Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 2219 | name, e.g. `image/gif`, a generic media type, e.g. `image/*`, |
| 2220 | or the wildcard `*/*` to match all types. |
| Shawn O. Pearce | 01cb1190 | 2009-07-15 08:19:01 -0700 | [diff] [blame] | 2221 | + |
| 2222 | By default, false for all MIME types. |
| 2223 | |
| 2224 | Common examples: |
| Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 2225 | ---- |
| 2226 | [mimetype "image/*"] |
| 2227 | safe = true |
| 2228 | |
| 2229 | [mimetype "application/pdf"] |
| 2230 | safe = true |
| 2231 | |
| 2232 | [mimetype "application/msword"] |
| 2233 | safe = true |
| 2234 | |
| 2235 | [mimetype "application/vnd.ms-excel"] |
| 2236 | safe = true |
| 2237 | ---- |
| Shawn O. Pearce | 01cb1190 | 2009-07-15 08:19:01 -0700 | [diff] [blame] | 2238 | |
| Shawn O. Pearce | 5f11b29 | 2010-08-05 17:57:35 -0700 | [diff] [blame] | 2239 | |
| 2240 | [[pack]]Section pack |
| 2241 | ~~~~~~~~~~~~~~~~~~~~ |
| 2242 | Global settings controlling how Gerrit Code Review creates pack |
| 2243 | streams for Git clients running clone, fetch, or pull. Most of these |
| 2244 | variables are per-client request, and thus should be carefully set |
| 2245 | given the expected concurrent request load and available CPU and |
| 2246 | memory resources. |
| 2247 | |
| 2248 | [[pack.deltacompression]]pack.deltacompression:: |
| 2249 | + |
| 2250 | If true, delta compression between objects is enabled. This may |
| 2251 | result in a smaller overall transfer for the client, but requires |
| 2252 | more server memory and CPU time. |
| 2253 | + |
| 2254 | False (off) by default, matching Gerrit Code Review 2.1.4. |
| 2255 | |
| 2256 | [[pack.threads]]pack.threads:: |
| 2257 | + |
| 2258 | Maximum number of threads to use for delta compression (if enabled). |
| 2259 | This is per-client request. If set to 0 then the number of CPUs is |
| 2260 | auto-detected and one thread per CPU is used, per client request. |
| 2261 | + |
| 2262 | By default, 1. |
| 2263 | |
| 2264 | |
| Shawn O. Pearce | 5ad16ea | 2012-05-09 14:24:25 -0700 | [diff] [blame] | 2265 | [[plugins]]Section plugins |
| 2266 | ~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 2267 | |
| 2268 | [[plugins.checkFrequency]]plugins.checkFrequency:: |
| 2269 | + |
| 2270 | How often plugins should be examined for new plugins to load, removed |
| 2271 | plugins to be unloaded, or updated plugins to be reloaded. Values can |
| 2272 | be specified using standard time unit abbreviations ('ms', 'sec', |
| 2273 | 'min', etc.). |
| 2274 | + |
| 2275 | If set to 0, automatic plugin reloading is disabled. Administrators |
| 2276 | may force reloading with link:cmd-plugin.html[gerrit plugin reload]. |
| 2277 | + |
| 2278 | Default is 1 minute. |
| 2279 | |
| 2280 | |
| lincoln | 2be1160 | 2010-07-05 10:53:25 -0300 | [diff] [blame] | 2281 | [[receive]]Section receive |
| 2282 | ~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| Sasa Zivkov | 59d89c3 | 2011-11-18 15:32:35 +0100 | [diff] [blame] | 2283 | This section is used to set who can execute the 'receive-pack' and |
| 2284 | to limit the maximum Git object size that 'receive-pack' will accept. |
| 2285 | '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] | 2286 | repo upload command. It also contains some advanced options for tuning the |
| 2287 | behavior of Gerrit's 'receive-pack' mechanism. |
| lincoln | 2be1160 | 2010-07-05 10:53:25 -0300 | [diff] [blame] | 2288 | |
| 2289 | ---- |
| 2290 | [receive] |
| 2291 | allowGroup = GROUP_ALLOWED_TO_EXECUTE |
| 2292 | allowGroup = YET_ANOTHER_GROUP_ALLOWED_TO_EXECUTE |
| Sasa Zivkov | 59d89c3 | 2011-11-18 15:32:35 +0100 | [diff] [blame] | 2293 | maxObjectSizeLimit = 40 m |
| lincoln | 2be1160 | 2010-07-05 10:53:25 -0300 | [diff] [blame] | 2294 | ---- |
| 2295 | |
| Shawn Pearce | 5cb31bf | 2013-02-27 16:20:26 -0800 | [diff] [blame] | 2296 | [[receive.checkMagicRefs]]receive.checkMagicRefs:: |
| 2297 | + |
| 2298 | If true, Gerrit will verify the destination repository has |
| 2299 | no references under the magic 'refs/drafts', 'refs/for', or |
| 2300 | 'refs/publish' branch namespaces. Names under these locations |
| 2301 | confuse clients when trying to upload code reviews so Gerrit |
| 2302 | requires them to be empty. |
| 2303 | + |
| 2304 | If false Gerrit skips the sanity check and assumes administrators |
| 2305 | have ensured the repository does not contain any magic references. |
| 2306 | Setting to false to skip the check can decrease latency during push. |
| 2307 | + |
| 2308 | Default is true. |
| 2309 | |
| Gustaf Lundh | 9062fd6 | 2013-02-14 17:23:11 +0100 | [diff] [blame] | 2310 | [[receive.checkReferencedObjectsAreReachable]]receive.checkReferencedObjectsAreReachable:: |
| 2311 | + |
| 2312 | If set to true, Gerrit will validate that all referenced objects that |
| 2313 | are not included in the received pack are reachable by the user. |
| 2314 | + |
| 2315 | Carrying out this check on gits with many refs and commits can be a |
| 2316 | very CPU-heavy operation. For non public Gerrit-servers this check may |
| 2317 | be overkill. |
| 2318 | + |
| 2319 | Only disable this check if you trust the clients not to forge SHA1 |
| 2320 | references to access commits intended to be hidden from the user. |
| 2321 | + |
| 2322 | Default is true. |
| 2323 | |
| lincoln | 2be1160 | 2010-07-05 10:53:25 -0300 | [diff] [blame] | 2324 | [[receive.allowGroup]]receive.allowGroup:: |
| 2325 | + |
| 2326 | Name of the groups of users that are allowed to execute |
| 2327 | 'receive-pack' on the server. One or more groups can be set. |
| 2328 | + |
| 2329 | If no groups are added, any user will be allowed to execute |
| 2330 | 'receive-pack' on the server. |
| 2331 | |
| Sasa Zivkov | 59d89c3 | 2011-11-18 15:32:35 +0100 | [diff] [blame] | 2332 | [[receive.maxObjectSizeLimit]]receive.maxObjectSizeLimit:: |
| 2333 | + |
| 2334 | Maximum allowed Git object size that 'receive-pack' will accept. |
| 2335 | If an object is larger than the given size the pack-parsing will abort |
| 2336 | and the push operation will fail. If set to zero then there is no |
| 2337 | limit. |
| 2338 | + |
| David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 2339 | Gerrit administrators can use this setting to prevent developers |
| Sasa Zivkov | 59d89c3 | 2011-11-18 15:32:35 +0100 | [diff] [blame] | 2340 | from pushing objects which are too large to Gerrit. |
| 2341 | + |
| Fredrik Luthander | a3cf354 | 2012-07-04 16:55:35 -0700 | [diff] [blame] | 2342 | This setting can also be set in the `project.config` |
| 2343 | link:config-project-config.html[receive.maxObjectSizeLimit] in order |
| 2344 | to further reduce the global setting. The project specific setting is |
| 2345 | only honored when it further reduces the global limit. |
| Sasa Zivkov | 5a708a8 | 2013-06-28 17:07:55 +0200 | [diff] [blame] | 2346 | + |
| Sasa Zivkov | 59d89c3 | 2011-11-18 15:32:35 +0100 | [diff] [blame] | 2347 | Default is zero. |
| 2348 | + |
| 2349 | Common unit suffixes of 'k', 'm', or 'g' are supported. |
| 2350 | |
| Dave Borowitz | 234734a | 2012-03-01 14:22:29 -0800 | [diff] [blame] | 2351 | [[receive.threadPoolSize]]receive.threadPoolSize:: |
| 2352 | + |
| 2353 | Maximum size of the thread pool in which the change data in received packs is |
| 2354 | processed. |
| 2355 | + |
| 2356 | Defaults to the number of available CPUs according to the Java runtime. |
| 2357 | |
| Shawn O. Pearce | c545c09 | 2012-07-27 16:38:55 -0700 | [diff] [blame] | 2358 | [[receive.changeUpdateThreads]]receive.changeUpdateThreads:: |
| 2359 | + |
| 2360 | Number of threads to perform change creation or patch set updates |
| 2361 | concurrently. Each thread uses its own database connection from |
| 2362 | the database connection pool, and if all threads are busy then |
| 2363 | main receive thread will also perform a change creation or patch |
| 2364 | set update. |
| 2365 | + |
| 2366 | Defaults to 1, using only the main receive thread. This feature is for |
| David Pursehouse | 9246356 | 2013-06-24 10:16:28 +0900 | [diff] [blame] | 2367 | databases with very high latency that can benefit from concurrent |
| Shawn O. Pearce | c545c09 | 2012-07-27 16:38:55 -0700 | [diff] [blame] | 2368 | operations when multiple changes are impacted at once. |
| 2369 | |
| Dave Borowitz | 1c40136 | 2012-03-02 17:39:17 -0800 | [diff] [blame] | 2370 | [[receive.timeout]]receive.timeout:: |
| 2371 | + |
| Shawn O. Pearce | 00dd12d | 2012-03-12 15:52:11 -0700 | [diff] [blame] | 2372 | Overall timeout on the time taken to process the change data in |
| 2373 | received packs. Only includes the time processing Gerrit changes |
| 2374 | and updating references, not the time to index the pack. Values can |
| 2375 | be specified using standard time unit abbreviations ('ms', 'sec', |
| 2376 | 'min', etc.). |
| Dave Borowitz | 1c40136 | 2012-03-02 17:39:17 -0800 | [diff] [blame] | 2377 | + |
| David Pursehouse | 9246356 | 2013-06-24 10:16:28 +0900 | [diff] [blame] | 2378 | Default is 2 minutes. If no unit is specified, milliseconds |
| Shawn O. Pearce | 00dd12d | 2012-03-12 15:52:11 -0700 | [diff] [blame] | 2379 | is assumed. |
| Dave Borowitz | 1c40136 | 2012-03-02 17:39:17 -0800 | [diff] [blame] | 2380 | |
| lincoln | 2be1160 | 2010-07-05 10:53:25 -0300 | [diff] [blame] | 2381 | |
| Hugo Josefson | 072b470 | 2010-04-21 19:27:11 +0200 | [diff] [blame] | 2382 | [[repository]]Section repository |
| 2383 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 2384 | Repositories in this sense are the same as projects. |
| 2385 | |
| Shawn O. Pearce | 897d921 | 2011-06-16 16:59:59 -0700 | [diff] [blame] | 2386 | In the following example configuration `Registered Users` is set |
| 2387 | to be the default owner of new projects. |
| Hugo Josefson | 072b470 | 2010-04-21 19:27:11 +0200 | [diff] [blame] | 2388 | |
| 2389 | ---- |
| 2390 | [repository "*"] |
| Hugo Josefson | 072b470 | 2010-04-21 19:27:11 +0200 | [diff] [blame] | 2391 | ownerGroup = Registered Users |
| 2392 | ---- |
| 2393 | |
| 2394 | [NOTE] |
| 2395 | Currently only the repository name `*` is supported. |
| 2396 | This is a wildcard designating all repositories. |
| 2397 | |
| Hugo Josefson | 072b470 | 2010-04-21 19:27:11 +0200 | [diff] [blame] | 2398 | [[repository.name.ownerGroup]]repository.<name>.ownerGroup:: |
| 2399 | + |
| 2400 | A name of a group which exists in the database. Zero, one or many |
| 2401 | groups are allowed. Each on its own line. Groups which don't exist |
| 2402 | in the database are ignored. |
| Hugo Josefson | 072b470 | 2010-04-21 19:27:11 +0200 | [diff] [blame] | 2403 | |
| Shawn O. Pearce | 94860ee | 2011-09-29 13:11:08 -0700 | [diff] [blame] | 2404 | [[rules]]Section rules |
| 2405 | ~~~~~~~~~~~~~~~~~~~~~~ |
| 2406 | |
| 2407 | [[rules.enable]]rules.enable:: |
| 2408 | + |
| Matt Baker | 8ce12fc | 2013-11-26 21:43:12 -0700 | [diff] [blame] | 2409 | If true, Gerrit will load and execute 'rules.pl' files in each |
| Shawn O. Pearce | 94860ee | 2011-09-29 13:11:08 -0700 | [diff] [blame] | 2410 | project's refs/meta/config branch, if present. When set to false, |
| 2411 | only the default internal rules will be used. |
| 2412 | + |
| 2413 | Default is true, to execute project specific rules. |
| 2414 | |
| Shawn O. Pearce | 8efb2a7 | 2009-08-18 19:45:33 -0700 | [diff] [blame] | 2415 | [[sendemail]]Section sendemail |
| 2416 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| Shawn O. Pearce | b0572c6 | 2009-06-01 14:18:22 -0700 | [diff] [blame] | 2417 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 2418 | [[sendemail.enable]]sendemail.enable:: |
| Shawn O. Pearce | 2e4573b | 2009-06-02 09:09:50 -0700 | [diff] [blame] | 2419 | + |
| 2420 | If false Gerrit will not send email messages, for any reason, |
| 2421 | and all other properties of section sendemail are ignored. |
| 2422 | + |
| 2423 | By default, true, allowing notifications to be sent. |
| 2424 | |
| Shawn O. Pearce | 5c31bd7 | 2009-09-10 18:13:33 -0700 | [diff] [blame] | 2425 | [[sendemail.from]]sendemail.from:: |
| 2426 | + |
| 2427 | Designates what name and address Gerrit will place in the From |
| 2428 | field of any generated email messages. The supported values are: |
| 2429 | + |
| 2430 | * `USER` |
| 2431 | + |
| 2432 | Gerrit will set the From header to use the current user's |
| David Pursehouse | 9246356 | 2013-06-24 10:16:28 +0900 | [diff] [blame] | 2433 | Full Name and Preferred Email. This may cause messages to be |
| Shawn O. Pearce | 5c31bd7 | 2009-09-10 18:13:33 -0700 | [diff] [blame] | 2434 | classified as spam if the user's domain has SPF or DKIM enabled |
| 2435 | and <<sendemail.smtpServer,sendemail.smtpServer>> is not a trusted |
| 2436 | relay for that domain. |
| 2437 | + |
| 2438 | * `MIXED` |
| 2439 | + |
| Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 2440 | Shorthand for `${user} (Code Review) <review@example.com>` where |
| Shawn O. Pearce | 5c31bd7 | 2009-09-10 18:13:33 -0700 | [diff] [blame] | 2441 | `review@example.com` is the same as <<user.email,user.email>>. |
| 2442 | See below for a description of how the replacement is handled. |
| 2443 | + |
| 2444 | * `SERVER` |
| 2445 | + |
| 2446 | Gerrit will set the From header to the same name and address |
| 2447 | it records in any commits Gerrit creates. This is set by |
| 2448 | <<user.name,user.name>> and <<user.email,user.email>>, or guessed |
| 2449 | from the local operating system. |
| 2450 | + |
| 2451 | * 'Code Review' `<`'review'`@`'example.com'`>` |
| 2452 | + |
| 2453 | If set to a name and email address in brackets, Gerrit will use |
| 2454 | this name and email address for any messages, overriding the name |
| 2455 | 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] | 2456 | Optionally, the name portion may contain the placeholder `${user}`, |
| Shawn O. Pearce | 5c31bd7 | 2009-09-10 18:13:33 -0700 | [diff] [blame] | 2457 | which is replaced by the Full Name of the current user. |
| 2458 | |
| 2459 | + |
| 2460 | By default, MIXED. |
| 2461 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 2462 | [[sendemail.smtpServer]]sendemail.smtpServer:: |
| Shawn O. Pearce | b0572c6 | 2009-06-01 14:18:22 -0700 | [diff] [blame] | 2463 | + |
| 2464 | Hostname (or IP address) of a SMTP server that will relay |
| 2465 | messages generated by Gerrit to end users. |
| 2466 | + |
| 2467 | By default, 127.0.0.1 (aka localhost). |
| 2468 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 2469 | [[sendemail.smtpServerPort]]sendemail.smtpServerPort:: |
| Shawn O. Pearce | b0572c6 | 2009-06-01 14:18:22 -0700 | [diff] [blame] | 2470 | + |
| 2471 | Port number of the SMTP server in sendemail.smtpserver. |
| 2472 | + |
| Shawn O. Pearce | 6e9a83f | 2009-11-02 10:30:48 -0800 | [diff] [blame] | 2473 | By default, 25, or 465 if smtpEncryption is 'ssl'. |
| 2474 | |
| 2475 | [[sendemail.smtpEncryption]]sendemail.smtpEncryption:: |
| 2476 | + |
| 2477 | Specify the encryption to use, either 'ssl' or 'tls'. |
| 2478 | + |
| 2479 | By default, 'none', indicating no encryption is used. |
| 2480 | |
| 2481 | [[sendemail.sslVerify]]sendemail.sslVerify:: |
| 2482 | + |
| 2483 | If false and sendemail.smtpEncryption is 'ssl' or 'tls', Gerrit |
| 2484 | will not verify the server certificate when it connects to send |
| 2485 | an email message. |
| 2486 | + |
| 2487 | By default, true, requiring the certificate to be verified. |
| Shawn O. Pearce | b0572c6 | 2009-06-01 14:18:22 -0700 | [diff] [blame] | 2488 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 2489 | [[sendemail.smtpUser]]sendemail.smtpUser:: |
| Shawn O. Pearce | b0572c6 | 2009-06-01 14:18:22 -0700 | [diff] [blame] | 2490 | + |
| 2491 | User name to authenticate with, if required for relay. |
| 2492 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 2493 | [[sendemail.smtpPass]]sendemail.smtpPass:: |
| Shawn O. Pearce | b0572c6 | 2009-06-01 14:18:22 -0700 | [diff] [blame] | 2494 | + |
| 2495 | Password for the account named by sendemail.smtpUser. |
| 2496 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 2497 | [[sendemail.allowrcpt]]sendemail.allowrcpt:: |
| Shawn O. Pearce | 219a8ee | 2009-06-01 18:13:57 -0700 | [diff] [blame] | 2498 | + |
| 2499 | If present, each value adds one entry to the whitelist of email |
| 2500 | addresses that Gerrit can send email to. If set to a complete |
| 2501 | email address, that one address is added to the white list. |
| 2502 | If set to a domain name, any address at that domain can receive |
| 2503 | email from Gerrit. |
| 2504 | + |
| 2505 | By default, unset, permitting delivery to any email address. |
| 2506 | |
| Shawn O. Pearce | 02aacbc | 2012-06-12 13:44:22 -0700 | [diff] [blame] | 2507 | [[sendemail.includeDiff]]sendemail.includeDiff:: |
| 2508 | + |
| Bruce Zu | eb00ff3 | 2012-11-27 17:38:10 +0800 | [diff] [blame] | 2509 | If true, new change emails and merged change emails from Gerrit |
| 2510 | will include the complete unified diff of the change. |
| 2511 | Variable maxmimumDiffSize places an upper limit on how large the |
| 2512 | email can get when this option is enabled. |
| Shawn O. Pearce | 02aacbc | 2012-06-12 13:44:22 -0700 | [diff] [blame] | 2513 | + |
| 2514 | By default, false. |
| 2515 | |
| Shawn O. Pearce | 28a950b | 2012-06-12 14:36:34 -0700 | [diff] [blame] | 2516 | [[sendemail.maximumDiffSize]]sendemail.maximumDiffSize:: |
| 2517 | + |
| 2518 | Largest size of unified diff output to include in an email. When |
| 2519 | the diff exceeds this size the file paths will be listed instead. |
| 2520 | Standard byte unit suffixes are supported. |
| 2521 | + |
| 2522 | By default, 256 KiB. |
| 2523 | |
| Alex Blewitt | 9cca740 | 2011-02-11 01:39:30 +0000 | [diff] [blame] | 2524 | [[sendemail.importance]]sendemail.importance:: |
| 2525 | + |
| 2526 | If present, emails sent from Gerrit will have the given level |
| 2527 | of importance. Valid values include 'high' and 'low', which |
| 2528 | email clients will render in different ways. |
| 2529 | + |
| 2530 | By default, unset, so no Importance header is generated. |
| 2531 | |
| 2532 | [[sendemail.expiryDays]]sendemail.expiryDays:: |
| 2533 | + |
| 2534 | If present, emails sent from Gerrit will expire after the given |
| 2535 | number of days. This will add the Expiry-Date header and |
| 2536 | email clients may expire or expunge mails whose Expiry-Date |
| 2537 | header is in the past. This should be a positive non-zero |
| 2538 | number indicating how many days in the future the mails |
| 2539 | should expire. |
| 2540 | + |
| 2541 | By default, unset, so no Expiry-Date header is generated. |
| 2542 | |
| Shawn O. Pearce | dba9764 | 2011-09-07 20:12:31 -0700 | [diff] [blame] | 2543 | |
| 2544 | [[site]]Section site |
| 2545 | ~~~~~~~~~~~~~~~~~~~~ |
| 2546 | |
| 2547 | [[site.checkUserAgent]]site.checkUserAgent:: |
| 2548 | + |
| 2549 | If true the server checks the User-Agent HTTP header and sends the |
| 2550 | correct JavaScript to the client as part of the initial page load. |
| 2551 | This usually reduces a round-trip for the client, allowing the UI to |
| 2552 | start more quickly. If false, a tiny JavaScript loader is sent to the |
| 2553 | client instead to determine the correct code to use. Default is true. |
| 2554 | |
| 2555 | [[site.refreshHeaderFooter]]site.refreshHeaderFooter:: |
| 2556 | + |
| 2557 | If true the server checks the site header, footer and CSS files for |
| 2558 | updated versions. If false, a server restart is required to change |
| 2559 | any of these resources. Default is true, allowing automatic reloads. |
| 2560 | |
| Shawn O. Pearce | 6bd04fd | 2012-04-05 14:39:22 -0700 | [diff] [blame] | 2561 | [[site.enableDeprecatedQuery]]site.enableDeprecatedQuery:: |
| 2562 | + |
| 2563 | If true the deprecated `/query` URL is available to return JSON |
| 2564 | and text results for changes. If false, the URL is disabled and |
| 2565 | returns 404 to clients. Default is true, enabling `/query`. |
| 2566 | |
| Shawn O. Pearce | 521380a | 2012-05-11 14:57:56 -0700 | [diff] [blame] | 2567 | [[ssh-alias]] Section ssh-alias |
| 2568 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 2569 | |
| 2570 | Variables in section ssh-alias permit the site administrator to alias |
| 2571 | another command from Gerrit or a plugin into the `gerrit` command |
| 2572 | namespace. To alias `replication start` to `gerrit replicate`: |
| 2573 | |
| 2574 | ---- |
| 2575 | [ssh-alias] |
| 2576 | replicate = replication start |
| 2577 | ---- |
| Shawn O. Pearce | dba9764 | 2011-09-07 20:12:31 -0700 | [diff] [blame] | 2578 | |
| Shawn O. Pearce | 8efb2a7 | 2009-08-18 19:45:33 -0700 | [diff] [blame] | 2579 | [[sshd]] Section sshd |
| Shawn O. Pearce | a758fef | 2009-08-19 08:29:32 -0700 | [diff] [blame] | 2580 | ~~~~~~~~~~~~~~~~~~~~~ |
| Shawn O. Pearce | 9410f2c | 2009-05-14 10:26:47 -0700 | [diff] [blame] | 2581 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 2582 | [[sshd.listenAddress]]sshd.listenAddress:: |
| Shawn O. Pearce | 1d3cb444 | 2009-05-30 14:03:31 -0700 | [diff] [blame] | 2583 | + |
| 2584 | Specifies the local addresses the internal SSHD should listen |
| 2585 | for connections on. The following forms may be used to specify |
| 2586 | an address. In any form, `:'port'` may be omitted to use the |
| 2587 | default of 29418. |
| 2588 | + |
| 2589 | * 'hostname':'port' (for example `review.example.com:29418`) |
| 2590 | * 'IPv4':'port' (for example `10.0.0.1:29418`) |
| 2591 | * ['IPv6']:'port' (for example `[ff02::1]:29418`) |
| Edwin Kempin | cdb0e00 | 2011-09-08 14:23:30 +0200 | [diff] [blame] | 2592 | * *:'port' (for example `*:29418`) |
| Shawn O. Pearce | 1d3cb444 | 2009-05-30 14:03:31 -0700 | [diff] [blame] | 2593 | |
| 2594 | + |
| 2595 | If multiple values are supplied, the daemon will listen on all |
| 2596 | of them. |
| 2597 | + |
| Shawn O. Pearce | 6af6f5f | 2010-06-08 17:38:43 -0700 | [diff] [blame] | 2598 | To disable the internal SSHD, set listenAddress to `off`. |
| 2599 | + |
| Shawn O. Pearce | 1d3cb444 | 2009-05-30 14:03:31 -0700 | [diff] [blame] | 2600 | By default, *:29418. |
| 2601 | |
| James Y Knight | 910bd86 | 2011-01-11 20:05:56 -0500 | [diff] [blame] | 2602 | [[sshd.advertisedAddress]]sshd.advertisedAddress:: |
| 2603 | + |
| 2604 | Specifies the addresses clients should be told to connect to. |
| 2605 | This may differ from sshd.listenAddress if a firewall based port |
| 2606 | redirector is being used, making Gerrit appear to answer on port |
| 2607 | 22. The following forms may be used to specify an address. In any |
| 2608 | form, `:'port'` may be omitted to use the default SSH port of 22. |
| 2609 | + |
| 2610 | * 'hostname':'port' (for example `review.example.com:22`) |
| 2611 | * 'IPv4':'port' (for example `10.0.0.1:29418`) |
| 2612 | * ['IPv6']:'port' (for example `[ff02::1]:29418`) |
| 2613 | |
| 2614 | + |
| 2615 | If multiple values are supplied, the daemon will advertise all |
| 2616 | of them. |
| 2617 | + |
| 2618 | By default, sshd.listenAddress. |
| 2619 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 2620 | [[sshd.tcpKeepAlive]]sshd.tcpKeepAlive:: |
| Shawn O. Pearce | fc9081f | 2009-05-14 10:26:59 -0700 | [diff] [blame] | 2621 | + |
| 2622 | If true, enables TCP keepalive messages to the other side, so |
| 2623 | the daemon can terminate connections if the peer disappears. |
| 2624 | + |
| David Ostrovsky | e5b7f1a | 2013-10-23 21:10:39 +0200 | [diff] [blame] | 2625 | Only effective when `sshd.backend` is set to `MINA`. |
| 2626 | + |
| Shawn O. Pearce | fc9081f | 2009-05-14 10:26:59 -0700 | [diff] [blame] | 2627 | By default, true. |
| 2628 | |
| Shawn O. Pearce | 1a4580b | 2009-11-19 17:37:10 -0800 | [diff] [blame] | 2629 | [[sshd.threads]]sshd.threads:: |
| 2630 | + |
| 2631 | Number of threads to use when executing SSH command requests. |
| 2632 | If additional requests are received while all threads are busy they |
| David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 2633 | are queued and serviced in a first-come-first-served order. |
| Shawn O. Pearce | 1a4580b | 2009-11-19 17:37:10 -0800 | [diff] [blame] | 2634 | + |
| 2635 | By default, 1.5x the number of CPUs available to the JVM. |
| 2636 | |
| Nico Sallembien | fc53f7f | 2010-05-18 16:40:10 -0700 | [diff] [blame] | 2637 | [[sshd.batchThreads]]sshd.batchThreads:: |
| 2638 | + |
| 2639 | Number of threads to allocate for SSH command requests from |
| Fredrik Luthander | 4684302 | 2012-03-13 16:11:02 +0100 | [diff] [blame] | 2640 | link:access-control.html#non-interactive_users[non-interactive users]. |
| 2641 | If equals to 0, then all non-interactive requests are executed in the same |
| 2642 | queue as interactive requests. |
| Nico Sallembien | fc53f7f | 2010-05-18 16:40:10 -0700 | [diff] [blame] | 2643 | + |
| 2644 | Any other value will remove the number of threads from the queue |
| 2645 | allocated to interactive users, and create a separate thread pool |
| 2646 | of the requested size, which will be used to run commands from |
| 2647 | non-interactive users. |
| 2648 | + |
| 2649 | If the number of threads requested for non-interactive users is larger |
| 2650 | than the total number of threads allocated in sshd.threads, then the |
| David Pursehouse | 9246356 | 2013-06-24 10:16:28 +0900 | [diff] [blame] | 2651 | value of sshd.threads is increased to accommodate the requested value. |
| Nico Sallembien | fc53f7f | 2010-05-18 16:40:10 -0700 | [diff] [blame] | 2652 | + |
| 2653 | By default, 0. |
| 2654 | |
| Kenny Root | 15ac1b8 | 2010-02-24 00:29:20 -0800 | [diff] [blame] | 2655 | [[sshd.streamThreads]]sshd.streamThreads:: |
| 2656 | + |
| 2657 | Number of threads to use when formatting events to asynchronous |
| 2658 | streaming clients. Event formatting is multiplexed onto this thread |
| 2659 | pool by a simple FIFO scheduling system. |
| 2660 | + |
| 2661 | By default, 1 plus the number of CPUs available to the JVM. |
| 2662 | |
| Edwin Kempin | b5df3b8 | 2011-10-10 11:31:14 +0200 | [diff] [blame] | 2663 | [[sshd.commandStartThreads]]sshd.commandStartThreads:: |
| Shawn O. Pearce | d629655 | 2011-05-15 13:56:30 -0700 | [diff] [blame] | 2664 | + |
| 2665 | Number of threads used to parse a command line submitted by a client |
| 2666 | over SSH for execution, create the internal data structures used by |
| 2667 | that command, and schedule it for execution on another thread. |
| 2668 | + |
| 2669 | By default, 2. |
| 2670 | |
| Shawn O. Pearce | 8a0bf36 | 2010-11-05 17:49:41 -0700 | [diff] [blame] | 2671 | [[sshd.maxAuthTries]]sshd.maxAuthTries:: |
| 2672 | + |
| 2673 | Maximum number of authentication attempts before the server |
| 2674 | disconnects the client. Each public key that a client has loaded |
| 2675 | into its local agent counts as one auth request. Users can work |
| 2676 | around the server's limit by loading less keys into their agent, |
| 2677 | or selecting a specific key in their `~/.ssh/config` file with |
| 2678 | the `IdentityFile` option. |
| 2679 | + |
| 2680 | By default, 6. |
| 2681 | |
| 2682 | [[sshd.loginGraceTime]]sshd.loginGraceTime:: |
| 2683 | + |
| 2684 | Time in seconds that a client has to authenticate before the server |
| 2685 | automatically terminates their connection. Values should use common |
| 2686 | unit suffixes to express their setting: |
| 2687 | + |
| 2688 | * s, sec, second, seconds |
| 2689 | * m, min, minute, minutes |
| 2690 | * h, hr, hour, hours |
| 2691 | * d, day, days |
| 2692 | |
| 2693 | + |
| 2694 | By default, 2 minutes. |
| 2695 | |
| Christian Aistleitner | 3d79459 | 2013-04-08 00:19:40 +0200 | [diff] [blame] | 2696 | [[sshd.idleTimeout]]sshd.idleTimeout:: |
| 2697 | + |
| 2698 | Time in seconds after which the server automatically terminates idle |
| 2699 | connections (or 0 to disable closing of idle connections). Values |
| 2700 | should use common unit suffixes to express their setting: |
| 2701 | + |
| 2702 | * s, sec, second, seconds |
| 2703 | * m, min, minute, minutes |
| 2704 | * h, hr, hour, hours |
| 2705 | * d, day, days |
| 2706 | |
| 2707 | + |
| 2708 | By default, 0. |
| 2709 | |
| Shawn O. Pearce | 8a0bf36 | 2010-11-05 17:49:41 -0700 | [diff] [blame] | 2710 | [[sshd.maxConnectionsPerUser]]sshd.maxConnectionsPerUser:: |
| 2711 | + |
| 2712 | Maximum number of concurrent SSH sessions that a user account |
| 2713 | 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] | 2714 | 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] | 2715 | the number of commands a user may issue over a single connection. |
| 2716 | If set to 0, there is no limit. |
| 2717 | + |
| 2718 | By default, 64. |
| 2719 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 2720 | [[sshd.cipher]]sshd.cipher:: |
| Shawn O. Pearce | 0bf2f52 | 2009-05-14 11:02:03 -0700 | [diff] [blame] | 2721 | + |
| 2722 | Available ciphers. To permit multiple ciphers, specify multiple |
| 2723 | `sshd.cipher` keys in the configuration file, one cipher name |
| 2724 | per key. Cipher names starting with `+` are enabled in addition |
| 2725 | to the default ciphers, cipher names starting with `-` are removed |
| 2726 | from the default cipher set. |
| 2727 | + |
| 2728 | Supported ciphers: aes128-cbc, aes128-cbc, aes256-cbc, blowfish-cbc, |
| 2729 | 3des-cbc, none. |
| 2730 | + |
| 2731 | By default, all supported ciphers except `none` are available. |
| 2732 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 2733 | [[sshd.mac]]sshd.mac:: |
| Shawn O. Pearce | 0bf2f52 | 2009-05-14 11:02:03 -0700 | [diff] [blame] | 2734 | + |
| 2735 | Available MAC (message authentication code) algorithms. To permit |
| 2736 | multiple algorithms, specify multiple `sshd.mac` keys in the |
| 2737 | configuration file, one MAC per key. MAC names starting with `+` |
| 2738 | are enabled in addition to the default MACs, MAC names starting with |
| 2739 | `-` are removed from the default MACs. |
| 2740 | + |
| 2741 | Supported MACs: hmac-md5, hmac-md5-96, hmac-sha1, hmac-sha1-96. |
| 2742 | + |
| 2743 | By default, all supported MACs are available. |
| 2744 | |
| Alex Blewitt | 7efb06f | 2013-04-01 12:46:48 -0400 | [diff] [blame] | 2745 | [[sshd.kerberosKeytab]]sshd.kerberosKeytab:: |
| 2746 | + |
| 2747 | Enable kerberos authentication for SSH connections. To permit |
| 2748 | kerberos authentication, the server must have a host principal |
| 2749 | (see `sshd.kerberosPrincipal`) which is acquired from a keytab. |
| 2750 | This must be provisioned by the kerberos administrators, and is |
| 2751 | typically installed into `/etc/krb5.keytab` on host machines. |
| 2752 | + |
| 2753 | The keytab must contain at least one `host/` principal, typically |
| 2754 | using the host's canonical name. If it does not use the |
| 2755 | canonical name, the `sshd.kerberosPrincipal` should be configured |
| 2756 | with the correct name. |
| 2757 | + |
| 2758 | By default, not set and so kerberos authentication is not enabled. |
| 2759 | |
| 2760 | [[sshd.kerberosPrincipal]]sshd.kerberosPrincipal:: |
| 2761 | + |
| 2762 | If kerberos authentication is enabled with `sshd.kerberosKeytab`, |
| 2763 | instead use the given principal name instead of the default. |
| 2764 | If the principal does not begin with `host/` a warning message is |
| 2765 | printed and may prevent successful authentication. |
| 2766 | + |
| 2767 | This may be useful if the host is behind an IP load balancer or |
| 2768 | other SSH forwarding systems, since the principal name is constructed |
| 2769 | by the client and must match for kerberos authentication to work. |
| 2770 | + |
| 2771 | By default, `host/canonical.host.name` |
| 2772 | |
| Shawn Pearce | 35e97c2 | 2013-10-17 22:15:38 -0700 | [diff] [blame] | 2773 | [[sshd.requestLog]]sshd.requestLog:: |
| 2774 | + |
| 2775 | Enable (or disable) the `'$site_path'/logs/sshd_log` request log. |
| 2776 | If enabled, a request log file is written out by the SSH daemon. |
| 2777 | + |
| 2778 | By default, true. |
| 2779 | |
| Shawn O. Pearce | 07bd6fb | 2011-04-29 19:15:47 -0700 | [diff] [blame] | 2780 | [[suggest]] Section suggest |
| 2781 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 2782 | |
| Dave Borowitz | 1ae8c53 | 2012-03-09 18:39:40 -0800 | [diff] [blame] | 2783 | [[suggest.accounts]]suggest.accounts:: |
| Shawn O. Pearce | 07bd6fb | 2011-04-29 19:15:47 -0700 | [diff] [blame] | 2784 | + |
| Dave Borowitz | 45baa89 | 2012-02-23 16:43:05 -0800 | [diff] [blame] | 2785 | If `true`, visible user accounts (according to the value of |
| 2786 | `accounts.visibility`) will be offered as completion suggestions |
| 2787 | 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] | 2788 | + |
| Dave Borowitz | 45baa89 | 2012-02-23 16:43:05 -0800 | [diff] [blame] | 2789 | If `false`, account suggestion is disabled. |
| Shawn O. Pearce | 07bd6fb | 2011-04-29 19:15:47 -0700 | [diff] [blame] | 2790 | + |
| Dave Borowitz | 45baa89 | 2012-02-23 16:43:05 -0800 | [diff] [blame] | 2791 | Older configurations may also have one of the `accounts.visibility` |
| 2792 | values for this field, including `OFF` as a synonym for `NONE`. If |
| 2793 | `accounts.visibility` is also set, that value overrides this one; |
| 2794 | otherwise, this value applies to both `suggest.accounts` and |
| 2795 | `accounts.visibility`. |
| Edwin Kempin | 4248881 | 2011-05-20 03:11:43 +0200 | [diff] [blame] | 2796 | + |
| Dave Borowitz | 45baa89 | 2012-02-23 16:43:05 -0800 | [diff] [blame] | 2797 | New configurations should prefer the boolean value for this field |
| 2798 | and an enum value for `accounts.visibility`. |
| Shawn O. Pearce | 07bd6fb | 2011-04-29 19:15:47 -0700 | [diff] [blame] | 2799 | |
| Edwin Kempin | f957dc2 | 2012-10-19 20:41:18 +0200 | [diff] [blame] | 2800 | [[suggest.from]]suggest.from:: |
| 2801 | + |
| 2802 | The number of characters that a user must have typed before suggestions |
| 2803 | are provided. If set to 0, suggestions are always provided. |
| 2804 | + |
| 2805 | By default 0. |
| 2806 | |
| Shawn O. Pearce | 2ba3ab4 | 2010-02-25 12:10:10 -0800 | [diff] [blame] | 2807 | [[theme]] Section theme |
| 2808 | ~~~~~~~~~~~~~~~~~~~~~~~ |
| 2809 | |
| 2810 | [[theme.backgroundColor]]theme.backgroundColor:: |
| 2811 | + |
| 2812 | Background color for the page, and major data tables like the all |
| 2813 | open changes table or the account dashboard. The value must be a |
| 2814 | valid HTML hex color code, or standard color name. |
| 2815 | + |
| Chad Horohoe | bbdf748 | 2012-11-13 18:23:15 -0800 | [diff] [blame] | 2816 | By default white, `FFFFFF`. |
| Shawn O. Pearce | 2ba3ab4 | 2010-02-25 12:10:10 -0800 | [diff] [blame] | 2817 | |
| 2818 | [[theme.topMenuColor]]theme.topMenuColor:: |
| 2819 | + |
| 2820 | This is the color of the main menu bar at the top of the page. |
| 2821 | The value must be a valid HTML hex color code, or standard color |
| Chad Horohoe | bbdf748 | 2012-11-13 18:23:15 -0800 | [diff] [blame] | 2822 | name. |
| 2823 | + |
| 2824 | By default white, `FFFFFF`. |
| Shawn O. Pearce | 2ba3ab4 | 2010-02-25 12:10:10 -0800 | [diff] [blame] | 2825 | |
| 2826 | [[theme.textColor]]theme.textColor:: |
| 2827 | + |
| 2828 | Text color for the page, and major data tables like the all |
| 2829 | open changes table or the account dashboard. The value must be a |
| 2830 | valid HTML hex color code, or standard color name. |
| 2831 | + |
| Chad Horohoe | bbdf748 | 2012-11-13 18:23:15 -0800 | [diff] [blame] | 2832 | By default dark grey, `353535`. |
| Shawn O. Pearce | 2ba3ab4 | 2010-02-25 12:10:10 -0800 | [diff] [blame] | 2833 | |
| 2834 | [[theme.trimColor]]theme.trimColor:: |
| 2835 | + |
| 2836 | Primary color used as a background color behind text. This is |
| 2837 | the color of the main menu bar at the top, of table headers, |
| 2838 | and of major UI areas that we want to offset from other portions |
| 2839 | of the page. The value must be a valid HTML hex color code, or |
| 2840 | standard color name. |
| 2841 | + |
| Chad Horohoe | bbdf748 | 2012-11-13 18:23:15 -0800 | [diff] [blame] | 2842 | By default a light grey, `EEEEEE`. |
| Shawn O. Pearce | 2ba3ab4 | 2010-02-25 12:10:10 -0800 | [diff] [blame] | 2843 | |
| 2844 | [[theme.selectionColor]]theme.selectionColor:: |
| 2845 | + |
| 2846 | Background color used within a trimColor area to denote the currently |
| 2847 | selected tab, or the background color used in a table to denote the |
| 2848 | currently selected row. The value must be a valid HTML hex color |
| 2849 | code, or standard color name. |
| 2850 | + |
| Chad Horohoe | bbdf748 | 2012-11-13 18:23:15 -0800 | [diff] [blame] | 2851 | By default a pale blue, `D8EDF9`. |
| Shawn O. Pearce | 2ba3ab4 | 2010-02-25 12:10:10 -0800 | [diff] [blame] | 2852 | |
| Andrew Hutchings | cfd7abb | 2012-06-29 10:57:05 +0100 | [diff] [blame] | 2853 | [[theme.changeTableOutdatedColor]]theme.changeTableOutdatedColor:: |
| 2854 | + |
| 2855 | Background color used for patch outdated messages. The value must be |
| 2856 | a valid HTML hex color code, or standard color name. |
| 2857 | + |
| Edwin Kempin | b034733 | 2012-07-17 10:14:32 +0200 | [diff] [blame] | 2858 | By default a shade of red, `F08080`. |
| Andrew Hutchings | cfd7abb | 2012-06-29 10:57:05 +0100 | [diff] [blame] | 2859 | |
| 2860 | [[theme.tableOddRowColor]]theme.tableOddRowColor:: |
| 2861 | + |
| 2862 | Background color for tables such as lists of open reviews for odd |
| 2863 | rows. This is so you can have a different color for odd and even |
| 2864 | rows of the table. The value must be a valid HTML hex color code, |
| 2865 | or standard color name. |
| 2866 | + |
| 2867 | By default transparent. |
| 2868 | |
| 2869 | [[theme.tableEvenRowColor]]theme.tableEvenRowColor:: |
| 2870 | + |
| 2871 | Background color for tables such as lists of open reviews for even |
| 2872 | rows. This is so you can have a different color for odd and even |
| 2873 | rows of the table. The value must be a valid HTML hex color code, |
| 2874 | or standard color name. |
| 2875 | + |
| 2876 | By default transparent. |
| 2877 | |
| Shawn O. Pearce | a83bb1c | 2011-05-20 08:46:48 -0700 | [diff] [blame] | 2878 | A different theme may be used for signed-in vs. signed-out user status |
| 2879 | by using the "signed-in" and "signed-out" theme sections. Variables |
| 2880 | not specified in a section are inherited from the default theme. |
| 2881 | |
| 2882 | ---- |
| 2883 | [theme] |
| 2884 | backgroundColor = FFFFFF |
| 2885 | [theme "signed-in"] |
| 2886 | backgroundColor = C0C0C0 |
| 2887 | [theme "signed-out"] |
| 2888 | backgroundColor = 00FFFF |
| 2889 | ---- |
| 2890 | |
| David Ostrovsky | 117c603 | 2013-08-09 00:44:56 +0200 | [diff] [blame] | 2891 | As example, here is the theme configuration to have the old green look: |
| 2892 | |
| 2893 | ---- |
| 2894 | [theme] |
| 2895 | backgroundColor = FCFEEF |
| 2896 | textColor = 000000 |
| 2897 | trimColor = D4E9A9 |
| 2898 | selectionColor = FFFFCC |
| 2899 | topMenuColor = D4E9A9 |
| 2900 | changeTableOutdatedColor = F08080 |
| 2901 | [theme "signed-in"] |
| 2902 | backgroundColor = FFFFFF |
| 2903 | ---- |
| 2904 | |
| Goran Lungberg | 04132a1 | 2010-06-15 17:20:37 -0700 | [diff] [blame] | 2905 | [[trackingid]] Section trackingid |
| Shawn O. Pearce | 91763a0 | 2010-06-16 15:39:33 -0700 | [diff] [blame] | 2906 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| Goran Lungberg | 04132a1 | 2010-06-15 17:20:37 -0700 | [diff] [blame] | 2907 | |
| Shawn O. Pearce | e800b1e | 2010-06-16 17:33:43 -0700 | [diff] [blame] | 2908 | Tagged footer lines containing references to external |
| 2909 | tracking systems, parsed out of the commit message and |
| Shawn Pearce | ff61c8a | 2013-10-07 19:35:53 -0700 | [diff] [blame] | 2910 | saved in Gerrit's database. |
| 2911 | |
| 2912 | After making changes to this section, existing changes |
| 2913 | must be reindexed with link:pgm-reindex.html[reindex] |
| 2914 | if index.type is `LUCENE` or `SOLR`; or with |
| 2915 | link:pgm-ScanTrackingIds.html[ScanTrackingIds] if index.type |
| 2916 | is unset or `SQL`. |
| Goran Lungberg | 04132a1 | 2010-06-15 17:20:37 -0700 | [diff] [blame] | 2917 | |
| Edwin Kempin | bb421f1 | 2011-08-25 11:19:00 +0200 | [diff] [blame] | 2918 | The tracking ids are searchable using tr:<tracking id> or |
| Shawn O. Pearce | 91763a0 | 2010-06-16 15:39:33 -0700 | [diff] [blame] | 2919 | bug:<tracking id>. |
| Goran Lungberg | 04132a1 | 2010-06-15 17:20:37 -0700 | [diff] [blame] | 2920 | |
| 2921 | ---- |
| 2922 | [trackingid "jira-bug"] |
| 2923 | footer = Bugfix: |
| 2924 | match = JRA\\d{2,8} |
| 2925 | system = JIRA |
| 2926 | |
| 2927 | [trackingid "jira-feature"] |
| 2928 | footer = Feature |
| 2929 | match = JRA(\\d{2,8}) |
| 2930 | system = JIRA |
| 2931 | ---- |
| 2932 | |
| 2933 | [[trackingid.name.footer]]trackingid.<name>.footer:: |
| 2934 | + |
| 2935 | 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] | 2936 | Several trackingid entries can have the same footer tag. A single |
| 2937 | trackingid entry can have multiple footer tags. If multiple footer |
| 2938 | tags are specified, each tag will be parsed separately. |
| Goran Lungberg | 04132a1 | 2010-06-15 17:20:37 -0700 | [diff] [blame] | 2939 | (the trailing ":" is optional) |
| 2940 | |
| 2941 | [[trackingid.name.match]]trackingid.<name>.match:: |
| 2942 | + |
| Magnus Bäck | e561183 | 2011-02-02 08:57:15 +0100 | [diff] [blame] | 2943 | A link:http://download.oracle.com/javase/6/docs/api/java/util/regex/Pattern.html[standard |
| 2944 | Java regular expression (java.util.regex)] used to match the |
| 2945 | external tracking id part of the footer line. The match can |
| 2946 | result in several entries in the DB. If grouping is used in the |
| 2947 | regex the first group will be interpreted as the tracking id. |
| Christian Aistleitner | 5cec368 | 2013-03-16 23:02:37 +0100 | [diff] [blame] | 2948 | Tracking ids longer than 32 characters will be ignored. |
| Goran Lungberg | 04132a1 | 2010-06-15 17:20:37 -0700 | [diff] [blame] | 2949 | + |
| 2950 | The configuration file parser eats one level of backslashes, so the |
| 2951 | character class `\s` requires `\\s` in the configuration file. The |
| 2952 | parser also terminates the line at the first `#`, so a match |
| 2953 | expression containing # must be wrapped in double quotes. |
| 2954 | |
| 2955 | [[trackingid.name.system]]trackingid.<name>.system:: |
| 2956 | + |
| David Pursehouse | 221d4f6 | 2012-06-08 17:38:08 +0900 | [diff] [blame] | 2957 | The name of the external tracking system (maximum 10 characters). |
| Goran Lungberg | 04132a1 | 2010-06-15 17:20:37 -0700 | [diff] [blame] | 2958 | It is possible to have several trackingid entries for the same |
| 2959 | tracking system. |
| 2960 | |
| Shawn O. Pearce | 6e4dfdd | 2010-05-12 17:26:08 -0700 | [diff] [blame] | 2961 | [[transfer]] Section transfer |
| 2962 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 2963 | |
| 2964 | [[transfer.timeout]]transfer.timeout:: |
| 2965 | + |
| 2966 | Number of seconds to wait for a single network read or write |
| 2967 | to complete before giving up and declaring the remote side is |
| 2968 | not responding. If 0, there is no timeout, and this server will |
| 2969 | wait indefinitely for a transfer to finish. |
| 2970 | + |
| 2971 | A timeout should be large enough to mostly transfer the objects to |
| 2972 | the other side. 1 second may be too small for larger projects, |
| 2973 | especially over a WAN link, while 10-30 seconds is a much more |
| 2974 | reasonable timeout value. |
| 2975 | + |
| 2976 | Defaults to 0 seconds, wait indefinitely. |
| 2977 | |
| lincoln | 2be1160 | 2010-07-05 10:53:25 -0300 | [diff] [blame] | 2978 | |
| 2979 | [[upload]]Section upload |
| Remy Bohmer | 203eea3 | 2012-02-19 21:21:36 +0100 | [diff] [blame] | 2980 | ~~~~~~~~~~~~~~~~~~~~~~~~ |
| lincoln | 2be1160 | 2010-07-05 10:53:25 -0300 | [diff] [blame] | 2981 | Sets the group of users allowed to execute 'upload-pack' on the |
| 2982 | server, 'upload-pack' is what runs on the server during a user's |
| 2983 | fetch, clone or repo sync command. |
| 2984 | |
| 2985 | ---- |
| 2986 | [upload] |
| 2987 | allowGroup = GROUP_ALLOWED_TO_EXECUTE |
| 2988 | allowGroup = YET_ANOTHER_GROUP_ALLOWED_TO_EXECUTE |
| 2989 | ---- |
| 2990 | |
| 2991 | [[upload.allowGroup]]upload.allowGroup:: |
| 2992 | + |
| 2993 | Name of the groups of users that are allowed to execute 'upload-pack' |
| 2994 | on the server. One or more groups can be set. |
| 2995 | + |
| 2996 | If no groups are added, any user will be allowed to execute |
| 2997 | 'upload-pack' on the server. |
| 2998 | |
| 2999 | |
| Shawn O. Pearce | 8efb2a7 | 2009-08-18 19:45:33 -0700 | [diff] [blame] | 3000 | [[user]] Section user |
| Shawn O. Pearce | a758fef | 2009-08-19 08:29:32 -0700 | [diff] [blame] | 3001 | ~~~~~~~~~~~~~~~~~~~~~ |
| Shawn O. Pearce | 0a35191 | 2009-06-01 08:14:46 -0700 | [diff] [blame] | 3002 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 3003 | [[user.name]]user.name:: |
| Shawn O. Pearce | 0a35191 | 2009-06-01 08:14:46 -0700 | [diff] [blame] | 3004 | + |
| 3005 | Name that Gerrit calls itself in Git when it creates a new Git |
| 3006 | commit, such as a merge during change submission. |
| 3007 | + |
| 3008 | By default this is "Gerrit Code Review". |
| 3009 | |
| Shawn O. Pearce | 92a7fd1 | 2009-08-18 19:52:48 -0700 | [diff] [blame] | 3010 | [[user.email]]user.email:: |
| Shawn O. Pearce | 0a35191 | 2009-06-01 08:14:46 -0700 | [diff] [blame] | 3011 | + |
| 3012 | Email address that Gerrit refers to itself as when it creates a |
| 3013 | new Git commit, such as a merge commit during change submission. |
| 3014 | + |
| 3015 | If not set, Gerrit generates this as "gerrit@`hostname`", where |
| 3016 | `hostname` is the hostname of the system Gerrit is running on. |
| 3017 | + |
| 3018 | By default, not set, generating the value at startup. |
| 3019 | |
| Edwin Kempin | 0e02ded | 2011-09-16 15:10:14 +0200 | [diff] [blame] | 3020 | [[user.anonymousCoward]]user.anonymousCoward:: |
| 3021 | + |
| David Pursehouse | 13b2190 | 2013-10-16 12:59:18 +0900 | [diff] [blame] | 3022 | Username that is displayed in the Gerrit WebUI and in e-mail |
| Edwin Kempin | 0e02ded | 2011-09-16 15:10:14 +0200 | [diff] [blame] | 3023 | notifications if the full name of the user is not set. |
| 3024 | + |
| 3025 | By default "Anonymous Coward" is used. |
| 3026 | |
| Shawn O. Pearce | 0bf2f52 | 2009-05-14 11:02:03 -0700 | [diff] [blame] | 3027 | |
| Shawn O. Pearce | c5fed82 | 2009-11-17 16:10:10 -0800 | [diff] [blame] | 3028 | File `etc/secure.config` |
| Remy Bohmer | 203eea3 | 2012-02-19 21:21:36 +0100 | [diff] [blame] | 3029 | ------------------------ |
| Shawn O. Pearce | c5fed82 | 2009-11-17 16:10:10 -0800 | [diff] [blame] | 3030 | The optional file `'$site_path'/etc/secure.config` overrides (or |
| 3031 | supplements) the settings supplied by `'$site_path'/etc/gerrit.config`. |
| Shawn O. Pearce | 0d4037a | 2009-11-12 18:33:46 -0800 | [diff] [blame] | 3032 | The file should be readable only by the daemon process and can be |
| 3033 | used to contain private configuration entries that wouldn't normally |
| 3034 | be exposed to everyone. |
| 3035 | |
| Shawn O. Pearce | c5fed82 | 2009-11-17 16:10:10 -0800 | [diff] [blame] | 3036 | Sample `etc/secure.config`: |
| Shawn O. Pearce | 0d4037a | 2009-11-12 18:33:46 -0800 | [diff] [blame] | 3037 | ---- |
| Shawn O. Pearce | 34f38cf | 2011-06-16 19:18:54 -0700 | [diff] [blame] | 3038 | [auth] |
| 3039 | registerEmailPrivateKey = 2zHNrXE2bsoylzUqDxZp0H1cqUmjgWb6 |
| Brad Larson | 3a6f077 | 2012-07-25 11:41:22 -0500 | [diff] [blame] | 3040 | restTokenPrivateKey = 7e40PzCjlUKOnXATvcBNXH6oyiu+r0dFk2c= |
| Shawn O. Pearce | 34f38cf | 2011-06-16 19:18:54 -0700 | [diff] [blame] | 3041 | |
| Shawn O. Pearce | 0d4037a | 2009-11-12 18:33:46 -0800 | [diff] [blame] | 3042 | [database] |
| Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 3043 | username = webuser |
| 3044 | password = s3kr3t |
| Shawn O. Pearce | 0d4037a | 2009-11-12 18:33:46 -0800 | [diff] [blame] | 3045 | |
| 3046 | [ldap] |
| Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 3047 | password = l3tm3srch |
| Shawn O. Pearce | 0d4037a | 2009-11-12 18:33:46 -0800 | [diff] [blame] | 3048 | |
| 3049 | [httpd] |
| Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 3050 | sslKeyPassword = g3rr1t |
| Shawn O. Pearce | 0d4037a | 2009-11-12 18:33:46 -0800 | [diff] [blame] | 3051 | |
| 3052 | [sendemail] |
| Shawn O. Pearce | 9d342a4 | 2009-12-16 15:49:05 -0800 | [diff] [blame] | 3053 | smtpPass = sp@m |
| Shawn O. Pearce | 7929d87 | 2011-05-15 13:33:15 -0700 | [diff] [blame] | 3054 | |
| 3055 | [remote "bar"] |
| 3056 | password = s3kr3t |
| Shawn O. Pearce | 0d4037a | 2009-11-12 18:33:46 -0800 | [diff] [blame] | 3057 | ---- |
| 3058 | |
| Johan Bjork | 3e5ee30 | 2012-01-27 17:59:54 +0100 | [diff] [blame] | 3059 | File `etc/peer_keys` |
| 3060 | -------------------- |
| 3061 | |
| 3062 | The optional file `'$site_path'/etc/peer_keys` controls who can |
| 3063 | login as the 'Gerrit Code Review' user, required for the link:cmd-suexec.html[suexec] |
| 3064 | command. |
| 3065 | |
| 3066 | The format is one Base-64 encoded public key per line. |
| 3067 | |
| 3068 | |
| Shawn O. Pearce | 7b40571 | 2009-05-08 18:27:53 -0700 | [diff] [blame] | 3069 | Database system_config |
| 3070 | ---------------------- |
| 3071 | |
| 3072 | Several columns in the `system_config` table within the metadata |
| 3073 | database may be set to control how Gerrit behaves. |
| Shawn O. Pearce | d2b73db | 2009-01-09 11:55:47 -0800 | [diff] [blame] | 3074 | |
| 3075 | [NOTE] |
| 3076 | The contents of the `system_config` table are cached at startup |
| 3077 | by Gerrit. If you modify any columns in this table, Gerrit needs |
| 3078 | to be restarted before it will use the new values. |
| 3079 | |
| Shawn O. Pearce | 7b40571 | 2009-05-08 18:27:53 -0700 | [diff] [blame] | 3080 | Configurable Parameters |
| 3081 | ~~~~~~~~~~~~~~~~~~~~~~~ |
| Shawn O. Pearce | d2b73db | 2009-01-09 11:55:47 -0800 | [diff] [blame] | 3082 | |
| Shawn O. Pearce | 8e9c73b | 2009-05-08 17:38:25 -0700 | [diff] [blame] | 3083 | site_path:: |
| 3084 | + |
| Shawn O. Pearce | d2b73db | 2009-01-09 11:55:47 -0800 | [diff] [blame] | 3085 | Local filesystem directory holding the site customization assets. |
| 3086 | Placing this directory under version control and/or backup is a |
| 3087 | good idea. |
| Shawn O. Pearce | 8e9c73b | 2009-05-08 17:38:25 -0700 | [diff] [blame] | 3088 | + |
| Shawn O. Pearce | c5fed82 | 2009-11-17 16:10:10 -0800 | [diff] [blame] | 3089 | Files in this directory provide additional configuration. |
| Shawn O. Pearce | 8e9c73b | 2009-05-08 17:38:25 -0700 | [diff] [blame] | 3090 | + |
| Shawn O. Pearce | d2b73db | 2009-01-09 11:55:47 -0800 | [diff] [blame] | 3091 | Other files support site customization. |
| Shawn O. Pearce | 8e9c73b | 2009-05-08 17:38:25 -0700 | [diff] [blame] | 3092 | + |
| Dave Borowitz | 1e49e14 | 2013-04-09 12:14:57 -0700 | [diff] [blame] | 3093 | * link:config-themes.html[Themes] |
| Shawn O. Pearce | d2b73db | 2009-01-09 11:55:47 -0800 | [diff] [blame] | 3094 | |
| Shawn O. Pearce | 5500e69 | 2009-05-28 15:55:01 -0700 | [diff] [blame] | 3095 | GERRIT |
| 3096 | ------ |
| 3097 | Part of link:index.html[Gerrit Code Review] |