GitLab安装和环境配置(虚拟机环境)

一. 安装Gitlab前系统预配置准备工作

1. 关闭firewalld防火墙

# systemctl stop firewalld
# systemctl disable firewalld

2. 关闭SELINUX并重启系统

# vi /etc/sysconfig/selinux

...
SELINUX=disabled
...

# reboot

二. 安装Omnibus Gitlab-ce package

1. 安装Gitlab组件

# yum -y install curl policycoreutils openssh-server openssh-clients postfix

2. 配置YUM仓库

# curl -sS https://packages.gitlab.com/install/repositories/gitlab/gitlab-ce/script.rpm.sh | sudo bash

3. 启动postfix邮件服务

# yum install postfix
# systemctl start postfix
# systemctl enable postfix

4. 安装Gitlab-ce社区版本

# yum install -y gitlab-ce

三. Omnibus Gitlab等相关配置初始化并完成安装

1. 证书创建与配置加载

# mkdir -p /etc/gitlab/ssl

// 创建私有秘钥
# openssl genrsa -out "/etc/gitlab/ssl/gitlab.example.com.key" 2048

// 创建csr证书
# openssl re

你可能感兴趣的:(linux,gitlab)