当然喜欢英文的可以参考官方文档:https://about.gitlab.com/downloads/

1.  根据自己的操作系统选择相应的安装方法,我这边是阿里云 centos 7的

sudo yum install -y curl policycoreutils-python openssh-server
sudo systemctl enable sshd
sudo systemctl start sshd
sudo firewall-cmd --permanent --add-service=http
sudo systemctl reload firewalld

  

注意:阿里云服务器好像没有开启防火墙,所以重启防火墙报错也没关系

2. 安装Postfix,目的是发邮件

sudo yum install postfix
sudo systemctl enable postfix
sudo systemctl start postfix

  

3. 下载安装包,官方提供的下载速度很慢,建议用国内的镜像:

  http://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/yum/el6     #这是适用centos 6

  http://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/yum/el7    #这是适用centos 7

  下载一个适合的版本

  wget  http://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/yum/el7/gitlab-ce-10.2.4-ce.0.el7.x86_64.rpm

4. 安装下载包

  sudo yum install gitlab-ce-10.2.4-ce.0.el7.x86_64.rpm

5. 修改external_url配置:

  sudo vim /etc/gitlab/gitlab.rb

  修改为公网IP+端口, 默认http是80:external_url 'http://xxx.xx.xx.xxx:80',  

  保存退出,执行: sudo gitlab-ctl reconfigure

  浏览器直接访问IP,看能否访问。

6. 配置邮箱

  sudo vim /etc/gitlab/gitlab.rb

  修改如下配置

gitlab_rails['gitlab_email_from'] = 'username@163.com'
user['git_user_email'] = "username@163.com" gitlab_rails['smtp_enable'] = true
gitlab_rails['smtp_address'] = "smtp.163.com"
gitlab_rails['smtp_port'] = 465
gitlab_rails['smtp_user_name'] = "username@163.com"
gitlab_rails['smtp_password'] = "userpassword"
gitlab_rails['smtp_domain'] = "163.com"
gitlab_rails['smtp_authentication'] = "login"
gitlab_rails['smtp_enable_starttls_auto'] = true
gitlab_rails['smtp_tls'] = true

  记住不要用25端口,阿里云是关闭25端口的

  保存退出后,执行:

    sudo gitlab-ctl reconfigure

 


gitlab服务器搭建的更多相关文章

  1. gitlab服务器搭建教程

    gitlab服务器搭建教程 ----2016年终总结 三 参考https://bbs.gitlab.cc/topic/35/gitlab-ce-8-7-%E6%BA%90%E7%A0%81%E5%AE ...

  2. ubuntu gitlab服务器搭建

    gitlab服务器搭建 1.安装依赖包 sudo apt-get install curl openssh-server ca-certificates postfix 执行完成后,出现邮件配置,选择 ...

  3. gitLab服务器搭建+ rundeck自动化部署

    git服务器搭建 https://blog.csdn.net/gx_1_11_real/article/details/79406427 rundeck   部署 https://blog.csdn. ...

  4. 8.gitlab服务器搭建(基于centos7)

    gitlab服务硬件要求 建议服务器最低配置:2核 2G以上内存(不包含2GB,2GB内存运行的时候内存直接爆掉) 官网给出的推荐配置:4核 4GB内存 支持500个用户,8核 8GB内存 支持100 ...

  5. GitLab服务器搭建及配置

    一.服务器环境 操作系统:CentOS release 6.5 (Final) GitLab版本: GitLab-shell:2.0.1 Ruby version: ruby 2.1.2p95 (20 ...

  6. Gitlab 服务器搭建

    一.官网地址 首页:https://about.gitlab.com/ 安装说明:https://about.gitlab.com/installation/ 二.安装命令摘录 实际问题:yum 安装 ...

  7. Gitlab服务器搭建(For fedora23)

    1. Install and configure the necessary dependencies sudo yum install curl policycoreutils openssh-se ...

  8. Linux下GitLab服务器搭建

    系统环境 操作系统:CentOS6.9关闭防火墙 安装步骤 1. 安装Postfix 2. 下载rpm包并安装 3. 配置gitlab,vim /etc/gitlab/gitlab.rb,指定ip+端 ...

  9. gitLab 服务器搭建 (自己服务器上搭建gitLab)

    环境 lunix(ubuntu) 1:添加文件 在   /etc/apt/sources.list.d/gitlab-ce.list 中添加一行 deb https://mirrors.tuna.ts ...

随机推荐

  1. Golang 入门系列(九) 如何读取YAML,JSON,INI等配置文件

    实际项目中,读取相关的系统配置文件是很常见的事情.今天就来说一说,Golang 是如何读取YAML,JSON,INI等配置文件的. 1. json使用 JSON 应该比较熟悉,它是一种轻量级的数据交换 ...

  2. 分治FFT的三种含义

    分治FFT是几个算法的统称.它们之间并无关联. 分治多项式乘法 问题如求\(\prod_{i=1}^na_ix+b\). 若挨个乘复杂度为\(O(n^2\log n)\),可分治做这件事,复杂度为\( ...

  3. Nginx部署静态页

    简答说一下如何用Nginx部署静态网页,并绑定域名访问 1.通过FTP上传静态页到服务器指定目录 2.编写nginx的.conf文件 3.重启nginx 如图,这是centos上传文件路径 nginx ...

  4. EQueue

    EQueue 2.3.2版本发布(支持高可用) - dotNET跨平台 - CSDN博客https://blog.csdn.net/sD7O95O/article/details/78097193 E ...

  5. P2256 一中校运会之百米跑(map映射加并查集)

    真心水,也许只有我这样的蒟蒻能做这种题了吧.用STL中的map将所有人的名字映射成一个数字,然后就是并查集的裸题 #include<bits/stdc++.h> using namespa ...

  6. 动态生成table 列

    table.render({ elem: '#test-table-comelist' ,url: layui.setter.base + 'list/comelist' ,cols: [[]] ,d ...

  7. CentOS修改SSH端口号和禁止root用户直接登录

    linux安装ssh远程登录后,为了安全起见,修改默认的22端口号并禁止root用户直接通过ssh登录. 配置方法如下: 1.使用vi编辑器打开ssh配置文件 /etc/ssh/sshd_config ...

  8. Win10 + Ubuntu双系统,删除Ubuntu系统

    之前在电脑上装了win10 + ubuntu的双系统,偶尔会出问题,所以还是选择将ubuntu系统删掉. 正所谓“请神容易送神难”,安装ubuntu的时候,过程还算顺利,但是在删除Ubuntu的过程中 ...

  9. docker之常用命令、自定制镜像、公(私)仓库的上传和下载

    一.docker命令 1.参数和命令汇总 1. 参数 Options: --config=~/.docker Location of client config files #客户端配置文件的位置 - ...

  10. Redis DeskTop Manager 使用教程

    redis desktop manager windows 是一款能够跨平台使用的开源性redis可视化工具. redis desktop manager主要针对redis开发设计,拥有直观强大的可视 ...