1. 安裝依賴python
[root@localhost ~]# yum -y install policycoreutils openssh-server openssh-clients postfixgit
[root@localhost ~]# yum -y install policycoreutils-pythonvim
2. 下載安裝ssh
[root@localhost ~]# wget https://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/yum/el7/gitlab-ce-10.0.0-ce.0.el7.x86_64.rpmide
[root@localhost ~]# rpm -ivh gitlab-ce-10.0.0-ce.0.el7.x86_64.rpmgitlab
完成會有一個圖案post
3. 修改配置文件,端口號最好修改,防止衝突spa
[root@localhost ~]# vim /etc/gitlab/gitlab.rbrest
....server
580 # unicorn['listen'] = '127.0.0.1'
581 unicorn['port'] = 8888
4. 初始化
gitlab-ctl reconfigure
5. 重啓
gitlab-ctl restart
6. 其餘基本命令
#中止gitlab
gitlab-ctl stop
#卸載gitlab
rpm -e gitlab-ce
#查看gitlab進程
ps aux | grep gitlab
#殺掉gitlab進程
kill -9 4473
#刪除gitlab文件
find / -name gitlab|xargs rm -rf
7. 設置超級管理員帳戶
[root@localhost ~]# cd /opt/gitlab/bin/
[root@localhost bin]# gitlab-rails console production