Merge "Use "gerrit" as the Gerrit user instead of "gerrit2""

This commit is contained in:
David Pursehouse
2017-07-05 04:42:45 +00:00
committed by Gerrit Code Review
8 changed files with 42 additions and 42 deletions

View File

@@ -16,7 +16,7 @@ Sample `etc/gerrit.config`:
packedGitLimit = 200 m packedGitLimit = 200 m
[cache] [cache]
directory = /var/cache/gerrit2 directory = /var/cache/gerrit
---- ----
[[accountPatchReviewDb]] [[accountPatchReviewDb]]
@@ -1553,7 +1553,7 @@ records about user accounts and change reviews.
type = POSTGRESQL type = POSTGRESQL
hostname = localhost hostname = localhost
database = reviewdb database = reviewdb
username = gerrit2 username = gerrit
password = s3kr3t password = s3kr3t
---- ----

View File

@@ -1,6 +1,6 @@
[[usersetup]] [[usersetup]]
== Initial Login == Initial Login
It's time to exit the gerrit2 account as you now have Gerrit running on your It's time to exit the gerrit account as you now have Gerrit running on your
host and setup your first workspace. host and setup your first workspace.
Start a shell with the credentials of the account you will perform Start a shell with the credentials of the account you will perform
@@ -57,9 +57,9 @@ Open a browser and enter the canonical url of your Gerrit server. You can
find the url in the settings file. find the url in the settings file.
---- ----
gerrit2@host:~$ git config -f ~/gerrit_testsite/etc/gerrit.config gerrit.canonicalWebUrl gerrit@host:~$ git config -f ~/gerrit_testsite/etc/gerrit.config gerrit.canonicalWebUrl
http://localhost:8080/ http://localhost:8080/
gerrit2@host:~$ gerrit@host:~$
---- ----
Register a new account in Gerrit through the web interface with the Register a new account in Gerrit through the web interface with the
@@ -70,9 +70,9 @@ proxy, and you are using an external OpenID provider, you will need to add the
proxy settings in the configuration file. proxy settings in the configuration file.
---- ----
gerrit2@host:~$ git config -f ~/gerrit_testsite/etc/gerrit.config --add http.proxy http://proxy:8080 gerrit@host:~$ git config -f ~/gerrit_testsite/etc/gerrit.config --add http.proxy http://proxy:8080
gerrit2@host:~$ git config -f ~/gerrit_testsite/etc/gerrit.config --add http.proxyUsername username gerrit@host:~$ git config -f ~/gerrit_testsite/etc/gerrit.config --add http.proxyUsername username
gerrit2@host:~$ git config -f ~/gerrit_testsite/etc/gerrit.config --add http.proxyPassword password gerrit@host:~$ git config -f ~/gerrit_testsite/etc/gerrit.config --add http.proxyPassword password
---- ----
Refer to the Gerrit configuration guide for more detailed information about Refer to the Gerrit configuration guide for more detailed information about

View File

@@ -45,8 +45,8 @@ password, create a database to store the metadata, and grant the user
full rights on the newly created database: full rights on the newly created database:
---- ----
$ createuser --username=postgres -RDIElPS gerrit2 $ createuser --username=postgres -RDIElPS gerrit
$ createdb --username=postgres -E UTF-8 -O gerrit2 reviewdb $ createdb --username=postgres -E UTF-8 -O gerrit reviewdb
---- ----
Visit PostgreSQL's link:http://www.postgresql.org/docs/9.1/interactive/index.html[documentation] for further information regarding Visit PostgreSQL's link:http://www.postgresql.org/docs/9.1/interactive/index.html[documentation] for further information regarding
@@ -65,9 +65,9 @@ rights on it:
---- ----
mysql mysql
CREATE USER 'gerrit2'@'localhost' IDENTIFIED BY 'secret'; CREATE USER 'gerrit'@'localhost' IDENTIFIED BY 'secret';
CREATE DATABASE reviewdb; CREATE DATABASE reviewdb;
GRANT ALL ON reviewdb.* TO 'gerrit2'@'localhost'; GRANT ALL ON reviewdb.* TO 'gerrit'@'localhost';
FLUSH PRIVILEGES; FLUSH PRIVILEGES;
---- ----
@@ -93,8 +93,8 @@ Create a user for the web application within sqlplus, assign it a
password, and grant the user full rights on the newly created database: password, and grant the user full rights on the newly created database:
---- ----
SQL> create user gerrit2 identified by secret_password default tablespace users; SQL> create user gerrit identified by secret_password default tablespace users;
SQL> grant connect, resources to gerrit2; SQL> grant connect, resources to gerrit;
---- ----
JDBC driver ojdbc6.jar must be obtained from your Oracle distribution. Gerrit JDBC driver ojdbc6.jar must be obtained from your Oracle distribution. Gerrit
@@ -115,7 +115,7 @@ $site_path/etc/gerrit.config:
type = oracle type = oracle
instance = xe instance = xe
hostname = localhost hostname = localhost
username = gerrit2 username = gerrit
port = 1521 port = 1521
---- ----
@@ -134,7 +134,7 @@ recommended only for environments where you intend to run Gerrit on an existing
MaxDB installation to reduce administrative overhead. MaxDB installation to reduce administrative overhead.
In the MaxDB studio or using the SQLCLI command line interface create a user In the MaxDB studio or using the SQLCLI command line interface create a user
'gerrit2' with the user class 'RESOURCE' and a password <secret password>. This 'gerrit' with the user class 'RESOURCE' and a password <secret password>. This
will also create an associated schema on the database. will also create an associated schema on the database.
To run Gerrit on MaxDB, you need to obtain the MaxDB JDBC driver. It can be To run Gerrit on MaxDB, you need to obtain the MaxDB JDBC driver. It can be
@@ -155,7 +155,7 @@ In $site_path/etc/gerrit.config:
type = maxdb type = maxdb
database = reviewdb database = reviewdb
hostname = localhost hostname = localhost
username = gerrit2 username = gerrit
---- ----
@@ -182,7 +182,7 @@ full rights on the newly created database:
---- ----
db2 => create database gerrit db2 => create database gerrit
db2 => connect to gerrit db2 => connect to gerrit
db2 => grant connect,accessctrl,dataaccess,dbadm,secadm on database to gerrit2; db2 => grant connect,accessctrl,dataaccess,dbadm,secadm on database to gerrit;
---- ----
JDBC driver db2jcc4.jar and db2jcc_license_cu.jar must be obtained JDBC driver db2jcc4.jar and db2jcc_license_cu.jar must be obtained
@@ -204,7 +204,7 @@ Sample database section in $site_path/etc/gerrit.config:
type = db2 type = db2
database = gerrit database = gerrit
hostname = localhost hostname = localhost
username = gerrit2 username = gerrit
port = 50001 port = 50001
---- ----

View File

@@ -43,8 +43,8 @@ We will run the service as a non-privileged user on your system.
First create the user and then become the user: First create the user and then become the user:
---- ----
$ sudo adduser gerrit2 $ sudo adduser gerrit
$ sudo su gerrit2 $ sudo su gerrit
---- ----
If you don't have root privileges you could skip this step and run Gerrit If you don't have root privileges you could skip this step and run Gerrit
@@ -71,12 +71,12 @@ This tutorial is based on version 2.2.2, and you can download that from this lin
It's time to run the initialization, and with the batch switch enabled, we don't have to answer any questions at all: It's time to run the initialization, and with the batch switch enabled, we don't have to answer any questions at all:
---- ----
gerrit2@host:~$ java -jar gerrit.war init --batch -d ~/gerrit_testsite gerrit@host:~$ java -jar gerrit.war init --batch -d ~/gerrit_testsite
Generating SSH host key ... rsa(simple)... done Generating SSH host key ... rsa(simple)... done
Initialized /home/gerrit2/gerrit_testsite Initialized /home/gerrit/gerrit_testsite
Executing /home/gerrit2/gerrit_testsite/bin/gerrit.sh start Executing /home/gerrit/gerrit_testsite/bin/gerrit.sh start
Starting Gerrit Code Review: OK Starting Gerrit Code Review: OK
gerrit2@host:~$ gerrit@host:~$
---- ----
When the init is complete, you can review your settings in the When the init is complete, you can review your settings in the
@@ -86,22 +86,22 @@ Note that initialization also starts the server. If any settings changes are
made, the server must be restarted before they will take effect. made, the server must be restarted before they will take effect.
---- ----
gerrit2@host:~$ ~/gerrit_testsite/bin/gerrit.sh restart gerrit@host:~$ ~/gerrit_testsite/bin/gerrit.sh restart
Stopping Gerrit Code Review: OK Stopping Gerrit Code Review: OK
Starting Gerrit Code Review: OK Starting Gerrit Code Review: OK
gerrit2@host:~$ gerrit@host:~$
---- ----
The server can be also stopped and started by passing the `stop` and `start` The server can be also stopped and started by passing the `stop` and `start`
commands to gerrit.sh. commands to gerrit.sh.
---- ----
gerrit2@host:~$ ~/gerrit_testsite/bin/gerrit.sh stop gerrit@host:~$ ~/gerrit_testsite/bin/gerrit.sh stop
Stopping Gerrit Code Review: OK Stopping Gerrit Code Review: OK
gerrit2@host:~$ gerrit@host:~$
gerrit2@host:~$ ~/gerrit_testsite/bin/gerrit.sh start gerrit@host:~$ ~/gerrit_testsite/bin/gerrit.sh start
Starting Gerrit Code Review: OK Starting Gerrit Code Review: OK
gerrit2@host:~$ gerrit@host:~$
---- ----
include::config-login-register.txt[] include::config-login-register.txt[]

View File

@@ -77,8 +77,8 @@ the path of the site directory to be created as an argument to the
own user account on the host system: own user account on the host system:
---- ----
sudo adduser gerrit2 sudo adduser gerrit
sudo su gerrit2 sudo su gerrit
java -jar gerrit.war init -d /path/to/your/gerrit_application_directory java -jar gerrit.war init -d /path/to/your/gerrit_application_directory
---- ----
@@ -86,7 +86,7 @@ own user account on the host system:
[NOTE] [NOTE]
If you choose a location where your new user doesn't If you choose a location where your new user doesn't
have any privileges, you may have to manually create the directory first and have any privileges, you may have to manually create the directory first and
then give ownership of that location to the `'gerrit2'` user. then give ownership of that location to the `'gerrit'` user.
If run from an interactive terminal, the init command will prompt through a If run from an interactive terminal, the init command will prompt through a
series of configuration questions, including gathering information series of configuration questions, including gathering information
@@ -104,8 +104,8 @@ When the init phase is complete, the daemon will be automatically started
in the background and your web browser will open to the site: in the background and your web browser will open to the site:
---- ----
Initialized /home/gerrit2/review_site Initialized /home/gerrit/review_site
Executing /home/gerrit2/review_site/bin/gerrit.sh start Executing /home/gerrit/review_site/bin/gerrit.sh start
Starting Gerrit Code Review: OK Starting Gerrit Code Review: OK
Waiting for server to start ... OK Waiting for server to start ... OK
Opening browser ... Opening browser ...

View File

@@ -36,8 +36,8 @@ Define a simple predicate and test it:
Copyright(C) 1997-2009 M.Banbara and N.Tamura Copyright(C) 1997-2009 M.Banbara and N.Tamura
(type Ctrl-D or "halt." to exit, "['path/to/file.pl']." to load a file) (type Ctrl-D or "halt." to exit, "['path/to/file.pl']." to load a file)
{consulting /usr/local/google/users/sop/gerrit2/gerrit/simple.pl ...} {consulting /usr/local/google/users/sop/gerrit/gerrit/simple.pl ...}
{/usr/local/google/users/sop/gerrit2/gerrit/simple.pl consulted 99 msec} {/usr/local/google/users/sop/gerrit/gerrit/simple.pl consulted 99 msec}
| ?- food(Type). | ?- food(Type).

View File

@@ -2,7 +2,7 @@
export JETTY_HOST=127.0.0.1 export JETTY_HOST=127.0.0.1
export JETTY_PORT=8081 export JETTY_PORT=8081
export JETTY_USER=gerrit2 export JETTY_USER=gerrit
export JETTY_PID=/var/run/jetty$JETTY_PORT.pid export JETTY_PID=/var/run/jetty$JETTY_PORT.pid
export JETTY_HOME=/home/$JETTY_USER/jetty export JETTY_HOME=/home/$JETTY_USER/jetty
export JAVA_HOME=/usr/lib/jvm/java-6-sun-1.6.0.07/jre export JAVA_HOME=/usr/lib/jvm/java-6-sun-1.6.0.07/jre

View File

@@ -42,16 +42,16 @@
<!-- PostgreSQL <!-- PostgreSQL
<Set name="driverClassName">org.postgresql.Driver</Set> <Set name="driverClassName">org.postgresql.Driver</Set>
<Set name="url">jdbc:postgresql:reviewdb</Set> <Set name="url">jdbc:postgresql:reviewdb</Set>
<Set name="username">gerrit2</Set> <Set name="username">gerrit</Set>
<Set name="password">secretkey</Set> <Set name="password">secretkey</Set>
--> -->
<!-- MySQL <!-- MySQL
<Set name="driverClassName">com.mysql.jdbc.Driver</Set> <Set name="driverClassName">com.mysql.jdbc.Driver</Set>
<Set name="url">jdbc:mysql://localhost/reviewdb?user=gerrit2&amp;password=secretkey</Set> <Set name="url">jdbc:mysql://localhost/reviewdb?user=gerrit&amp;password=secretkey</Set>
--> -->
<!-- MariaDB <!-- MariaDB
<Set name="driverClassName">org.mariadb.jdbc.Driver</Set> <Set name="driverClassName">org.mariadb.jdbc.Driver</Set>
<Set name="url">jdbc:mariadb://localhost/reviewdb?user=gerrit2&amp;password=secretkey</Set> <Set name="url">jdbc:mariadb://localhost/reviewdb?user=gerrit&amp;password=secretkey</Set>
--> -->
<!-- H2 <!-- H2
<Set name="driverClassName">org.h2.Driver</Set> <Set name="driverClassName">org.h2.Driver</Set>