ps: 修改ip

    1. _gitlab_conf() {
    2. yum -y install epel-release
    3. yum -y install git
    4. yum -y install curl openssh-server openssh-clients postfix cronie policycoreutils-python-utils
    5. systemctl enable --now postfix
    6. cd /usr/src/
    7. wget https://mirrors.bfsu.edu.cn/gitlab-ce/yum/el8/gitlab-ce-14.3.2-ce.0.el8.x86_64.rpm
    8. rpm -ivh gitlab-ce-14.3.2-ce.0.el8.x86_64.rpm
    9. sed -i 's|^external_url|#external_url|' /etc/gitlab/gitlab.rb
    10. cat >> /etc/gitlab/gitlab.rb <<EOF
    11. external_url 'http://192.168.143.102'
    12. EOF
    13. gitlab-ctl reconfigure
    14. cat /etc/gitlab/initial_root_password
    15. }
    16. _gitlab_conf