1. Install: http://code.google.com/p/gerrit/downloads/listparts and use gitto obtain the latest code. 2. Configure if you use git or the source code, you can refer to the source code Documentation/install.txt to configure the database first. I chose mysqlCREATEUSER 'xwang4' @ 'localhost' IDENTIFIEDBY
1. Install
: Http://code.google.com/p/gerrit/downloads/list
Or use git to obtain the latest code.
2. Configuration
If you use git or the source code, you can refer to the source code Documentation/install.txt.
Configure the database first. I chose mysql.
Create user 'xang4' @ 'localhost' identified by 'yoyo ';
Create database reviewdb;
Alter database reviewdb charset = latin1;
Grant all on reviewdb. * TO 'xang4' @ 'localhost ';
Flush privileges;
Then initialize:
# Java-jar gerrit-2.2.1.war init-d/home/xwang4/kunlun/gerrit/sites
- Xwang4 @ PEK-xwang4-Ubuntu :~ /Kunlun/gerrit $ java-jar gerrit-2.2.1.war init-d/home/xwang4/kunlun/gerrit/sites
- *** Gerrit Code Review 2.2.1
- ***
- * ** Git Repositories
- ***
- Location of Git repositories [/home/xwang4/workspace/gingerbread-kunlun/devel]:
- * ** SQL Database
- ***
- Database server type [MYSQL/?] :
- Server hostname [localhost]:
- Server port [(MYSQL default)]:
- Database name [reviewdb]:
- Database username [xwang4]:
- Change xwang4's password [y/N]?
- * ** User Authentication
- ***
- Authentication method [DEVELOPMENT_BECOME_ANY_ACCOUNT/?] :?
- Supported options are:
- Openid
- Http
- Http_ldap
- Client_ssl_cert_ldap
- Ldap
- Ldap_bind
- Development_become_any_account
- Authentication method [DEVELOPMENT_BECOME_ANY_ACCOUNT/?] : Openid
- * ** Email Delivery
- ***
- SMTP server hostname [hhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh]:
- SMTP server port [25]:
- SMTP encryption [TLS/?] :
- SMTP username [xwang4]:
- Change xwang4's password [y/N]?
- *** Container Process
- ***
- Run as [xwang4]:
- Java runtime [/usr/lib/jvm/java-6-sun-1.6.0.26/jre]:
- Upgrade/home/xwang4/kunlun/gerrit/sites/bin/gerrit. war [Y/n]?
- Copying gerrit. war to/home/xwang4/kunlun/gerrit/sites/bin/gerrit. war
- * ** SSH Daemon
- ***
- Listen on address [*]:
- Listen on port [29418]:
- * ** HTTP Daemon
- ***
- Behind reverse proxy [y/N]?
- Use SSL (https: //) [y/N]?
- Listen on address [*]:
- Listen on port [8088]:
- Canonical URL [http: // PEK-xwang4-ubuntu: 8088/]:
Start: bin/gerrit. sh restart
If openid is used, the following message is displayed during registration: Provider is not supported, or was incorrectly entered.
Sudo ln-sf/etc/java-6-sun/security/cacerts/usr/lib/jvm/java-6-openjdk/jre/lib/security/cacerts