GIT-Linux(CentOS7)系统部署git服务器
GIT-Linux(CentOS7)系統部署git服務器
root賬號登錄
?
一、 安裝并配置必要的依賴關系
在CentOS系統上安裝所需的依賴:ssh,防火墻,postfix(用于郵件通知) ,wget,以下這些命令也會打開系統防火墻中的HTTP和SSH端口訪問。
1.安裝ssh
sudo yum install -y curl policycoreutils-pythonopenssh-server
?
如報錯
錯誤信息:/var/run/yum.pid已被鎖定,PID為1610的另一個程序正在運行。
解決辦法:?運行:rm -f /var/run/yum.pid??刪除文件后再次運行yum可用。
?
?
1.sudo yum install curl policycoreutils openssh-server openssh-clients
2.sudo systemctl enable sshd
3.sudo systemctl start sshd
4.sudo yum install postfix
5.sudo systemctl enable postfix
6.sudo systemctl start postfix
7.sudo firewall-cmd --permanent --add-service=http
8.sudo systemctl reload firewalld
?
?
9.curl -sS http://packages.gitlab.cc/install/gitlab-ce/script.rpm.sh | sudo bash
10.sudo yum install gitlab-ce
11.curl -LJO https://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/yum/el7/gitlab-ce-8.9.5-ce.0.el7.x86_64.rpm
12.rpm -i?gitlab-ce-8.9.5-ce.0.el7.x86_64.rpm
?
開啟GITLab
sudo gitlab-ctl start
關閉GITLab
sudo gitlab-ctl stop
重啟GITLab
sudo gitlab-ctl restart
?
因為這種安裝會附帶安裝Nignx,所以GITLAB占用80端口,訪問時直接訪問IP就可以(第一次會讓你確認root賬戶登錄的密碼)。?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
參考:https://blog.csdn.net/duyusean/article/details/80011540
?
轉載于:https://www.cnblogs.com/1285026182YUAN/p/10726539.html
總結
以上是生活随笔為你收集整理的GIT-Linux(CentOS7)系统部署git服务器的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 教你创建自己的CSDN博客专栏
- 下一篇: ubuntu等linux系统给windo