gitlab by the rpm package, the default storage location in / var / opt / gitlab / Git-Data / Repositories , usually need to change this path to a separate partition to store data warehouse.
For example, I have here the data stored to the next / data / gitlab directory
Creating / data / gitlab directory
mkdir -p /data/gitlab
Gitlab modify the configuration file, find git_data_dir
vim /etc/gitlab/gitlab.rb
Add a git_data_dir git_data_dir below the "/ data / gitlab"
Stop the current gitlab, reload the configuration
gitlab-ctl stop
gitlab-ctl reconfigure
After reload, you will find in the / data / gitlab directory more than a directory repositories
Finally, you can start gitlab
gitlab-ctl start
After installing gitlab, you want to warehouse (repositories) on a large hard drive, you need to modify the corresponding directory warehouse
Steps:
1: Create a new repository directory
mkdir -p /mnt/application/gitlab/git-data
2: Modify the configuration file
sudo vi /etc/gitlab/gitlab.rb
Search: git_data_dir
modified: git_data_dir "New Catalog"
Such as:
git_data_dir "/ mnt / file application / gitlab / Git-Data"
Save
3: Rebuild gitlab
the sudo gitlab the reconfigure-CTL
Does not generate an error, and you can see in the new repository directory from the directory, that amendment is successful
gitlab-SATELLITES
Repositories