Methods and steps for deploying GitLab environment based on Docker

Methods and steps for deploying GitLab environment based on Docker

Note: It is recommended that the virtual machine memory is 2G or more, and the acceleration image of Alibaba Cloud must be configured

1. Download the image file

docker pull beginor/gitlab-ce:11.0.1-ce.0

2. Create GitLab configuration (etc), log (log), and data (data) outside the container to facilitate future upgrades

mkdir -p /mnt/gitlab/etc

mkdir -p /mnt/gitlab/log

mkdir -p /mnt/gitlab/data

3. Run the GitLab container

Enter the /mnt/gitlab/etc directory and run the following command

docker run \

  --detach \

  --publish 8443:443 \

  --publish 8090:80 \

  --name gitlab \

  --restart unless-stopped \

  -v /mnt/gitlab/etc:/etc/gitlab \

  -v /mnt/gitlab/log:/var/log/gitlab \

  -v /mnt/gitlab/data:/var/opt/gitlab \

  beginor/gitlab-ce:11.0.1-ce.0 

4. Modify /mnt/gitlab/etc/gitlab.rb

Change external_url to the domain name or IP address of the deployment machine

vi /mnt/gitlab/etc/gitlab.rb

Change external_url to 'http://192.168.125.126'

5. Modify /mnt/gitlab/data/gitlab-rails/etc/gitlab.yml

vi /mnt/gitlab/data/gitlab-rails/etc/gitlab.yml

Found the keyword * ## Web server settings *

Change the host value to the mapped external host IP address and port

6. Restart the Docker container

First stop the container, delete the container information, restart Docker, and then rerun the GitLab container.

7. Finish

The gitlab web management page can be accessed normally

This concludes this article about the steps for deploying a GitLab environment based on Docker. For more information about setting up a Docker GitLab environment, please search for previous articles on 123WORDPRESS.COM or continue to browse the following related articles. I hope you will support 123WORDPRESS.COM in the future!

You may also be interested in:
  • Detailed tutorial on using Docker to build Gitlab based on CentOS8 system
  • Teach you the detailed process of using Docker to build the Chinese version of gitlab community
  • Two ways to build a private GitLab using Docker
  • Detailed tutorial on building Gitlab server on CentOS8.1
  • How to build gitlab on centos6
  • Centos7 uses docker to build gitlab server
  • How to build gitlab using Docker example
  • Steps to build your own private GitHub repository with GitLab
  • Detailed explanation of using docker to build gitlab
  • Build a local GitLab server on CentOS7

<<:  Two methods of implementing automatic paging in Vue page printing

>>:  MySQL complete collapse query regular matching detailed explanation

Recommend

MySQL 5.7.20 Green Edition Installation Detailed Graphic Tutorial

First, let’s understand what MySQL is? MySQL is a...

How to smoothly go online after MySQL table partitioning

Table of contents Purpose of the table For exampl...

CSS to achieve compatible text alignment in different browsers

In the front-end layout of the form, we often nee...

Example analysis of mysql variable usage [system variables, user variables]

This article uses examples to illustrate the usag...

HTML table markup tutorial (28): cell border color attribute BORDERCOLOR

To beautify the table, you can set different bord...

Detailed example of HTML element blocking Flash

Copy code The code is as follows: wmode parameter...

The functions and differences between disabled and readonly

1: readonly is to lock this control so that it can...

Summary of WEBAPP development skills (notes for mobile website development)

1. To develop web responsively, the page must ada...

Detailed explanation of group by and having in MySQL

The GROUP BY syntax can group and count the query...

Detailed explanation of common usage methods of weixin-js-sdk in vue

Link: https://qydev.weixin.qq.com/wiki/index.php?...

How to enhance Linux and Unix server security

Network security is a very important topic, and t...

Tutorial on configuring and using i3 window manager in Linux

In this article, I will show you how to install a...

Complete steps to configure a static IP address for a Linux virtual machine

Preface In many cases, we will use virtual machin...

MySQL uses covering index to avoid table return and optimize query

Preface Before talking about covering index, we m...

How to Monitor Linux Memory Usage Using Bash Script

Preface There are many open source monitoring too...