一、资源准备
devops:5台服务器;centos7.9操作系统,64位。
- gitlab,代码仓库。
- jenkins,发布服务。
- harbor,docker仓库服务。
这里以发布hyperf 服务到两台机器为演示。
部署环境:
二、gitlab安装
1、安装相关依赖
yum -y install policycoreutils openssh-server openssh-clients postfix
2、启动ssh服务&设置为开机启动
systemctl enable sshd && sudo systemctl start sshd
3、设置postfix开机自启,并启动,postfix支持gitlab发信功能
systemctl enable postfix && systemctl start postfix