2016-07-27 62 views
2

所以我嘗試做一個git的備份。我發現這個腳本(這裏:https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/raketasks/backup_restore.md
但是,如果我使用這個命令它說,找不到命令。我究竟做錯了什麼?Linux找不到gitlab-rake?

[email protected] git/gitlab# sudo gitlab-rake gitlab:backup:create SKIP=db,uploads                            
    sudo: gitlab-rake: command not found 

而且我試着命令

sudo -u git -H bundle exec rake gitlab:backup:create RAILS_ENV=production

但隨着該命令停在upload.rbErrno::ENOENT: No such file or directory

回答

0

這取決於gitlab的安裝位置。
例如:

PATH=$PATH:/opt/gitlab/bin 
export PATH 

檢查gitlab-rake是那裏/opt/gitlab/bin

There should be symlinks in /usr/bin
如果沒有,也許你已經安裝了GitLab從源(sudo -u git -H bundle exec rake

+0

從來源:也許一個符號鏈接的問題:https://gitlab.com/gitlab-org/gitlab-ce/issues/899#note_2558643 – VonC