一 官网说明

  • 安装步骤:https://about.gitlab.com/install/#centos-7

  • 安装说明:本文只是用来给微服务当配置中心,只是较浅的记录一下安装步骤,后面会详细讲解及在docker上面的安装。

1.安装和配置必要的依赖项

在CentOS 7(和RedHat / Oracle / Scientific Linux 7)上,以下命令还将在系统防火墙中打开HTTP,HTTPS和SSH访问。

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 firewall-cmd --permanent --add-service=https
sudo systemctl reload firewalld

接下来,安装Postfix以发送通知电子邮件。如果要使用其他解决方案发送电子邮件,请跳过此步骤, 并在安装GitLab之后配置外部SMTP服务器

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

在安装Postfix的过程中,可能会出现一个配置屏幕。选择“ Internet网站”,然后按Enter。使用服务器的外部DNS作为“邮件名”,然后按Enter。如果出现其他屏幕,请继续按Enter接受默认设置。

2.添加GitLab软件包存储库并安装软件包

添加GitLab软件包存储库。

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

接下来,安装GitLab软件包。更改https://gitlab.example.com为您要访问GitLab实例的URL。安装将自动配置并在该URL上启动GitLab。

对于https://URL,GitLab将使用Let's Encrypt自动请求证书,这需要入站HTTP访问和有效的主机名。您也可以使用自己的证书或仅使用http://。

sudo EXTERNAL_URL="https://gitlab.example.com" yum install -y gitlab-ee

二 开始安装

  • 需要从官网下载 gitlab-ce-12.4.0-ce.0.el7.x86_64.rpm(ce为社区版,和ee没有太大区别)

  • https://pan.baidu.com/s/17T6BhNoBKnp61EZ6FEj7kw

然后按照上面的步骤进行安装

sudo rpm -ivh gitlab-ce-12.4.0-ce.0.el7.x86_64.rpm
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 firewall-cmd --permanent --add-service=https
sudo systemctl reload firewalld
sudo yum install postfix
sudo systemctl enable postfix
sudo systemctl start postfix
curl https://packages.gitlab.com/install/repositories/gitlab/gitlab-ce/script.rpm.sh | sudo bash
sudo EXTERNAL_URL="https://gitlab.example.com" yum install -y gitlab-ce
  • Gitlab服务操作

初始化配置 gitlab
gitlab-ctl reconfigure
启动 gitlab 服务
gitlab-ctl start
停止 gitlab 服务
gitlab-ctl stop
  • 测试

Gitlab在Centos7上的安装的更多相关文章

  1. 【运维技术】CentOS7上从零开始安装阿里RocketMQ版本:release-4.0.1【亲测哈哈】

    CentOS7上从零开始安装阿里RocketMQ版本:release-4.0.1[亲测哈哈] 安装git # 更新包 $ yum update # 安装git $ yum install git # ...

  2. 分布式文件系统FastDFS在CentOS7上的安装及与Springboot的整合

    1. 概述 FastDFS 是目前比较流行的分布式文件系统,可以很容易的实现横向扩展.动态扩容.灾备.高可用和负载均衡. FastDFS 的服务分为 tracker 服务 和 storage 服务,  ...

  3. solr7.3.1在CentOS7上的安装

    1 solr的下载 从Solr官方网站(http://archive.apache.org/dist/lucene/solr/7.3.1/ )下载Solr最新版本, 根据Solr的运行环境,Linux ...

  4. centos7上docker安装和使用教程

    Docker 是一个创建和管理 Linux 容器的开源工具.容器就像是轻量级的虚拟机,并且可以以毫秒级的速度来启动或停止.Docker 帮助系统管理员和程序员在容器中开发应用程序,并且可以扩展到成千上 ...

  5. 精简总结redis/rabbitmq/zookeeper在linux centos7上的安装

    因为本博主之前已经写过了相关的一些安装及集群,可以参考前面的记录,但是由于博最近更换了VM14和centos7,为了适应这些环境,所以后续会逐渐重新搭建相关环境,并对之前的安装思路进一步精简梳理,以期 ...

  6. GitLab在centos7上安装和使用

    git的优点 git是分布式的,svn不是 git分布式本地就可以用,可以随便保存各种历史痕迹,不用担心污染服务器,连不上服务器也能提交代码.查看log. GIT分支和SVN的分支不同 分支在SVN中 ...

  7. 【运维技术】CentOS7上从零开始安装LAMP安装织梦DedeCMS教程

    前期准备数据 centos7 系统 安装 appache httpd # 更新httpd yum update httpd # 安装httpd yum install -y httpd # 启动服务 ...

  8. 在CentOs7上yum安装redis

    在开始安装步骤之前,先把我的CentOs和redis版本号列出来: # 系统/软件 版本号 1 CentOS7 CentOS Linux release 7.2.1511 (Core) 2 redis ...

  9. mongoDB在centos7上的安装

    1,下载安装包 下载MongoDB的安装文件 地址:https://www.mongodb.org/downloads#production 选择Linux 64-bit legacy 版本,下载到目 ...

随机推荐

  1. Spring 梳理 - filter、interceptor、aop实现与区别 -第一篇

    前言 项目中我们经常需要对RESTful api进行拦截,主流实现方法有filter.interceptor.aop,先说一下他们各自的实现. Filter AnimalFilter实现javax.s ...

  2. Spring boot 官网学习笔记 - Using Spring Boot without the Parent POM,但是还要使用Parent POM提供的便利

    If you do not want to use the spring-boot-starter-parent, you can still keep the benefit of the depe ...

  3. spring后台重定向方式

    1.直接返回值中加重定向:"redirect:要访问的网址"; public String updateOrAddProject() { return "redirect ...

  4. Python数据结构 - 利用headp模块寻找最大N个元素并实现优先队列

    用headp找到最大最小的N个值 import heapq nums = [1, 8, 2, 23, 7, -4, 18, 23, 42, 37, 2] print(heapq.nlargest(3, ...

  5. node学习笔记(一)本地文件目录查看器

    Node.js 新闻 nw.js 前端开发桌面应用 内容 node.js实战 照例提供百度云链接,本来以为是实战系列的那本,但不是,不过这本也不错 链接:https://pan.baidu.com/s ...

  6. 在Linux系统下有一个目录/usr/share/dict/ 这个目录里包含了一个词典的文本文件,我们可以利用这个文件来辨别单词是否为词典中的单词。

    #!/bin/bash s=`cat /usr/share/dict/linux.words` for i in $s; do if [ $1 = $i ];then echo "$1 在字 ...

  7. ELK 学习笔记之 elasticsearch基本概念和CRUD

    elasticsearch基本概念和CRUD: 基本概念: CRUD: 创建索引: curl -XPUT 'http://192.168.1.151:9200/library/' -d '{" ...

  8. 【百度地图】如何去掉百度LOGO

    只需要一步就解决问题,在CSS里加入一段代码即可: .anchorBL{display:none;}

  9. Ansible Roles角色

    Roles小技巧: 1.创建roles目录结构,手动或使用ansible-galaxy init test roles 2.编写roles的功能,也就是tasks. nginx rsyncd memc ...

  10. B-微积分-Sigmoid函数

    目录 Sigmoid函数 一.Sigmoid函数详解 更新.更全的<机器学习>的更新网站,更有python.go.数据结构与算法.爬虫.人工智能教学等着你:https://www.cnbl ...