木一 发表于 2018-9-19 09:23:27

在 Ubuntu 14安装gitlab-7835882

  在 Ubuntu 14 安装
  使用国内安装源镜像,加快安装速度。修改/etc/apt/sources.list.d/gitlab-ce.list,添加以下行
  deb https://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/debian jessie main
  开始安装:
  # 安装依赖包
  sudo apt-get install curl openssh-server ca-certificates postfix
  # 安装 GitLab 社区版
  apt-get install gitlab-ce
  # 初始化,初始化完自动启动 GitLab
  sudo gitlab-ctl reconfigure
  在 CentOS 6 安装
  使用国内镜像安装,新建 /etc/yum.repos.d/gitlab-ce.repo,添加以下内容
  
  name=gitlab-ce
  baseurl=http://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/yum/el6
  repo_gpgcheck=0
  gpgcheck=0
  enabled=1
  gpgkey=https://packages.gitlab.com/gpg.key
  安装步骤:
  # 安装依赖包
  sudo yum install curl openssh-server openssh-clients postfix cronie
  # 启动 postfix 邮件服务
  sudo service postfix start
  # 检查 postfix
  sudo chkconfig postfix on
  # 安装 GitLab 社区版
  sudo yum install gitlab-ce
  # 初始化 GitLab
  sudo gitlab-ctl reconfigure
  修改 host
  添加访问的 host,修改/etc/gitlab/gitlab.rb的external_url
  external_url 'http://git.home.com'
  vi /etc/hosts,添加 host 映射
  127.0.0.1 git.home.com
  每次修改/etc/gitlab/gitlab.rb,都要运行以下命令,让配置生效
  sudo gitlab-ctl reconfigure
  配置本机的 host,如:192.168.113.59 git.home.com。最后,在浏览器打开网址http://git.home.com
  登陆用户名: root
  密码: 5iveL!fe
  ps:
  ①(内存给到4G CPU给到4核),比较吃系统资源。
  ②jenkins+git

页: [1]
查看完整版本: 在 Ubuntu 14安装gitlab-7835882