Commit 31359516408ec108d684a6b2b4ffe6098703aa78

Authored by Dmitriy Zaporozhets
2 parents 946595a5 72e2fe2c

Merge branch 'database_doc' of /home/git/repositories/gitlab/gitlabhq

config/database.yml.mysql
@@ -7,7 +7,7 @@ production: @@ -7,7 +7,7 @@ production:
7 reconnect: false 7 reconnect: false
8 database: gitlabhq_production 8 database: gitlabhq_production
9 pool: 10 9 pool: 10
10 - username: gitlab 10 + username: git
11 password: "secure password" 11 password: "secure password"
12 # host: localhost 12 # host: localhost
13 # socket: /tmp/mysql.sock 13 # socket: /tmp/mysql.sock
doc/install/databases.md
@@ -25,19 +25,19 @@ GitLab supports the following databases: @@ -25,19 +25,19 @@ GitLab supports the following databases:
25 # Create a user for GitLab 25 # Create a user for GitLab
26 # do not type the 'mysql>', this is part of the prompt 26 # do not type the 'mysql>', this is part of the prompt
27 # change $password in the command below to a real password you pick 27 # change $password in the command below to a real password you pick
28 - mysql> CREATE USER 'gitlab'@'localhost' IDENTIFIED BY '$password'; 28 + mysql> CREATE USER 'git'@'localhost' IDENTIFIED BY '$password';
29 29
30 # Create the GitLab production database 30 # Create the GitLab production database
31 mysql> CREATE DATABASE IF NOT EXISTS `gitlabhq_production` DEFAULT CHARACTER SET `utf8` COLLATE `utf8_unicode_ci`; 31 mysql> CREATE DATABASE IF NOT EXISTS `gitlabhq_production` DEFAULT CHARACTER SET `utf8` COLLATE `utf8_unicode_ci`;
32 32
33 # Grant the GitLab user necessary permissions on the table. 33 # Grant the GitLab user necessary permissions on the table.
34 - mysql> GRANT SELECT, LOCK TABLES, INSERT, UPDATE, DELETE, CREATE, DROP, INDEX, ALTER ON `gitlabhq_production`.* TO 'gitlab'@'localhost'; 34 + mysql> GRANT SELECT, LOCK TABLES, INSERT, UPDATE, DELETE, CREATE, DROP, INDEX, ALTER ON `gitlabhq_production`.* TO 'git'@'localhost';
35 35
36 # Quit the database session 36 # Quit the database session
37 mysql> \q 37 mysql> \q
38 38
39 # Try connecting to the new database with the new user 39 # Try connecting to the new database with the new user
40 - sudo -u git -H mysql -u gitlab -p -D gitlabhq_production 40 + sudo -u git -H mysql -u git -p -D gitlabhq_production
41 41
42 # Type the password you replaced $password with earlier 42 # Type the password you replaced $password with earlier
43 43