在 Ubuntu 14安装gitlab

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了在 Ubuntu 14安装gitlab相关的知识,希望对你有一定的参考价值。

在 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,添加以下内容
[gitlab-ce]
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


本文出自 “7835882” 博客,请务必保留此出处http://crfsz.blog.51cto.com/7835882/1936486

以上是关于在 Ubuntu 14安装gitlab的主要内容,如果未能解决你的问题,请参考以下文章

ubuntu14.04 nodejs安装位置在哪

如何在ubuntu14.04中安装openvswitch

ubuntu 14.04安装的软件在哪

如何在Ubuntu 14.04 LTS上安装MariaDB

ubuntu 14.04怎么安装

在 Ubuntu 14安装gitlab