Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to build gitlab in Docke

2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >

Share

Shulou(Shulou.com)05/31 Report--

This article mainly introduces Docke how to build gitlab related knowledge, content detailed and easy to understand, simple and fast operation, has a certain reference value, I believe that everyone will read this Docke how to build gitlab article will have some gains, let's take a look at it.

gitlab Introduction Overview

Gitlab is an open source project for a warehouse management system. Use git as a code management tool and build web services on top of it. Github is a public git repository, while gitlab is suitable for building private git repositories within enterprises.

Official website:

Front-end: nginx, used for pages and git tool http or https protocol

Backend: gitlab service, Ruby on rails framework, background service and multi-process through unicorn

sshd: enables sshd service, which is used for users to upload ssh key for version cloning and uploading. Note: The ssh key uploaded by the user is saved to the git account.

Database: Currently only mysql and postgresql are supported

redis: Used to store user sessions and tasks, including creating a new warehouse, sending emails, and so on

sidekiq: rails framework comes with, subscribe to redis tasks and execute

Building Process

1. create a virtual machine

The copy code is as follows:

docker-machine create --driver virtualbox --virtualbox-cpu-count 4 --virtualbox-memory 3072 dev-gitlab

2. Configure virtual machine accelerators

docker-machine ssh dev-gitlabsudo sed -i "s|extra_args='|extra_args='--registry-mirror=http://6cade60d.m.daocloud.io |g" /var/lib/boot2docker/profileexitdocker-machine restart dev-gitlab

3. Download redis, postgresql, gitlab mirror

docker pull sameersbn/redisdocker pull sameersbn/postgresqldocker pull sameersbn/gitlab

4. Execute the above mirror generation container (\for newline display, actually remove\line execution)

#Generate postgresql mirror container docker run--name postgresql-d\-e 'db_name = gitlabhq_production'\-e 'db_user = gitlab'\-e 'db_pass = password'\-e 'db_extension = pg_trgm'\-v/home/docker/opt/postgresql ql/data:/var/lib/postgresql\sameersbn/postgresql #Generate redis mirror container docker run--name redis-d\-v/home/docker/opt/redis/data:/var/lib/redis\sameersbn/redis #Generate redis mirror container #Note: gitlab_host The address assigned to the virtual machine docker run--name gitlab-d\--link postgresql: postgresql--link redis: redisio\-p 10022:22-p 10080:80\-e 'gitlab_port = 10080'\-e 'gitlab_ssh_port = 10022'\-e 'gitlab_secrets_db_key_base = long-and-random-alpha-num@ic-string'\-e 'gitlab_secrets_secret_key_base = long-and-random-alpha-numeric-string'\-e 'gitlab_secrets_otp_key_base = long-and-random-alpha-numeric-string'\-e 'gitlab_host = 192.168.99.100'\-e 'gitlab_email=xiahl0916@163.com'\-e 'smtp_enabled = true'\-e' www.gitlab_email=xiahl0916@163.com 'w.example.com'\-e' www.example.com'\-e' smtp_starttls = false'\-e' smtp_user = mail address'\-e' smtp_pass = mail password'\-e' smtp_authentication = login'\-e' gitlab_smtp_domain=www.163.com I believe everyone has a certain understanding of how to build gitlab in Docke. If you still want to learn more knowledge, please pay attention to the industry information channel.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Internet Technology

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report