8803103ebe
LocalUsernamesToLowerCase is changing the case of external IDs in the "gerrit" scheme. Since the external IDs are stored as fields in the account index the corresponding accounts must be reindexed. LocalUsernamesToLowerCase as a site program doesn't have the account index available and hence can't do the reindexing itself (at least not without blowing up the Guice injector stack). Instead invoke the reindex program to reindex the accounts. This is the same approach that was taken for the MigrateToNoteDb program which was added in master. This will reindex all accounts and also means that the LocalUsernamesToLowerCase program cannot run in parallel to the Gerrit server. This should be okay since running LocalUsernamesToLowerCase is a one time effort when you want to configure case-insensitive login for Gerrit. Change-Id: I6f2804ece996b22ec834aaebf209dac3b5b89415 Signed-off-by: Edwin Kempin <ekempin@google.com>
65 lines
1.7 KiB
Plaintext
65 lines
1.7 KiB
Plaintext
= LocalUsernamesToLowerCase
|
|
|
|
== NAME
|
|
LocalUsernamesToLowerCase - Convert the local username of every
|
|
account to lower case
|
|
|
|
== SYNOPSIS
|
|
[verse]
|
|
--
|
|
_java_ -jar gerrit.war _LocalUsernamesToLowerCase
|
|
-d <SITE_PATH>
|
|
--
|
|
|
|
== DESCRIPTION
|
|
Converts the local username for every account to lower case. The
|
|
local username is the username that is used to login into the Gerrit
|
|
Web UI.
|
|
|
|
This task is only intended to be run if the configuration parameter
|
|
link:config-gerrit.html#ldap.localUsernameToLowerCase[ldap.localUsernameToLowerCase]
|
|
was set to true to achieve case insensitive LDAP login to the Gerrit
|
|
Web UI.
|
|
|
|
Please be aware that the conversion of the local usernames to lower
|
|
case can't be undone.
|
|
|
|
The program will produce errors if there are accounts that have the
|
|
same local username, but with different case. In this case the local
|
|
username for these accounts is not converted to lower case.
|
|
|
|
After all usernames have been migrated, the link:pgm-reindex.html[
|
|
reindex] program is automatically invoked to reindex all accounts.
|
|
|
|
This task cannot run in the background concurrently to the server;
|
|
it must be run by itself.
|
|
|
|
== OPTIONS
|
|
|
|
-d::
|
|
--site-path::
|
|
Location of the gerrit.config file, and all other per-site
|
|
configuration data, supporting libraries and log files.
|
|
|
|
== CONTEXT
|
|
This command can only be run on a server which has direct
|
|
connectivity to the metadata database.
|
|
|
|
== EXAMPLES
|
|
To convert the local username of every account to lower case:
|
|
|
|
----
|
|
$ java -jar gerrit.war LocalUsernamesToLowerCase -d site_path
|
|
----
|
|
|
|
== SEE ALSO
|
|
|
|
* Configuration parameter link:config-gerrit.html#ldap.localUsernameToLowerCase[ldap.localUsernameToLowerCase]
|
|
|
|
GERRIT
|
|
------
|
|
Part of link:index.html[Gerrit Code Review]
|
|
|
|
SEARCHBOX
|
|
---------
|