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

Installation tutorial for GitLab and Jenkins

2025-01-16 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/03 Report--

Gitlab installation instructions:

1 the best running memory is 4 GB CPU 2 core.

2 pay attention to the running port, do not conflict with the port

3 this installation is implemented in Docker-Compose, so you need to install Docker-Compose. This installation method requires Baidu.

> vim docker-compose.yml / / create a compose file version: '2'services: gitlab: image:' gitlab/gitlab-ce:latest' container_name: gitlab restart: always hostname: 'gitlab.aiitle.com' environment: GITLAB_OMNIBUS_CONFIG: | external_url' http://gitlab.aiitle.com:8929' gitlab_rails ['gitlab_shell_ssh_port'] = 2224 gitlab_rails ['time_zone'] =' Asia/Shanghai' ports:-'8929 gitlab_rails 8929'-'2224 volumes: -'. / config:/etc/gitlab' -'. / logs:/var/log/gitlab' -'. / data:/var/opt/gitlab'Gitlab startup process

1 execute command: docker-compose up-d

2 you need to wait a long time, because you need to pull the image, and you need to deploy automatically for a period of time. Just wait patiently.

3 my port here is: 8929, so the way I access it is: http://IP:8929

4 after the installation is completed, if the access is 502, you still need to wait and refresh several times.

5 tuning, please do your own Baidu.

Jenkins installs vim docker-compose.yml / / to create the compose file for Jenkins version: '3'services: jenkins: image:' jenkins/jenkins:lts' container_name: jenkins restart: always environment:-'JAVA_OPTS=-Duser.timezone=Asia/Shanghai' volumes: -' / etc/localtime:/etc/localtime' ports:-'8928 JAVA_OPTS=-Duser.timezone=Asia/Shanghai' volumes 8080'-'50000 compose 5000' volumes: -'. / data : / var/jenkins_home'Jenkins start the process:

1 execute command: docker-compose up-d

2 you need to wait a long time, because you need to pull the image, and you need to deploy automatically for a period of time. Just wait patiently.

3 my port number: 8928, so my access method is: http:// IP+8928

4 access will require you to enter a password, get the command: find /-name initialAdminPassword to find this file and open the file, copy the password to the web browser.

5 install the recommended plug-in very slowly: find the configuration file of Jenkins default.json and use the replacement command: $sed-I 's/http:\ /\ / updates.jenkins-ci.org\ / download/https:\ /\ / mirrors.tuna.tsinghua.edu.cn\ / jenkins/g' default.json & & sed-I' s/http:\ / www.google.com/https:\ /\ / www.baidu.com/g' default.json

6 execute command: docker-compose restart

Summary

At this point, GitLab + Jenkins is installed.

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

Servers

Wechat

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

12
Report