如果需要汉化,请根据汉化来选择版本
汉化包下载地址:https://gitlab.com/xhang/gitlab/
1.依赖包安装
yum -y install policycoreutils openssh-server openssh-clients postfix
2.下载gitlab-ce并安装
# 下载安装包 https://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/yum/el7/gitlab-ce-15.9.4-ce.0.el7.x86_64.rpm rpm -ivh gitlab-ce-15.9.4-ce.0.el7.x86_64.rpm # 修改gitlab配置文件指定服务器ip和自定义端口,如果有需要可以修改数据存放路径 # 自定义IP和端口: external_url 'http://0.0.0.0:9981' # 修改存储路径 # gitlab默认存储路径:/var/opt/gitlab/git-data # 修改为新路径:/db/gitlab/git-data git_data_dirs({ "default" => { "path" => "/db/gitlab/git-data", "failure_count_threshold" => "10", "failure_wait_time" => "30", "failure_reset_time" => "1800", "storage_timeout" => "30" } }) # 使用gitlab-ctl reconfigure 自动配置,并安装数据库,初始化信息 gitlab-ctl reconfigure
Notes: Default admin account has been configured with following details: Username: root Password: You didn't opt-in to print initial root password to STDOUT. Password stored to /etc/gitlab/initial_root_password. This file will be cleaned up in first reconfigure run after 24 hours. NOTE: Because these credentials might be present in your log files in plain text, it is highly recommended to reset the password following
https://docs.gitlab.com/ee/security/reset_user_password.html#reset-your-root-password. gitlab Reconfigured!
# 修改初始密码
gitlab-rake "gitlab:password:reset" Enter username: root Enter password: Confirm password: Password successfully updated for user with username root.
3.查看命令
# 检查状态 [root@gitlab gitlab]# gitlab-ctl status run: alertmanager: (pid 1598) 378s; run: log: (pid 16733) 3104s run: gitaly: (pid 1635) 375s; run: log: (pid 15387) 3247s run: gitlab-exporter: (pid 1591) 379s; run: log: (pid 16598) 3124s run: gitlab-kas: (pid 1571) 381s; run: log: (pid 15754) 3228s run: gitlab-workhorse: (pid 1582) 380s; run: log: (pid 16367) 3140s run: logrotate: (pid 383) 498s; run: log: (pid 15270) 3259s run: nginx: (pid 1247) 417s; run: log: (pid 16425) 3133s run: node-exporter: (pid 1275) 416s; run: log: (pid 16457) 3130s run: postgres-exporter: (pid 1626) 378s; run: log: (pid 16849) 3099s run: postgresql: (pid 461) 490s; run: log: (pid 15586) 3236s run: prometheus: (pid 1309) 411s; run: log: (pid 16676) 3110s run: puma: (pid 1146) 421s; run: log: (pid 16259) 3154s run: redis: (pid 394) 496s; run: log: (pid 15300) 3253s run: redis-exporter: (pid 1295) 412s; run: log: (pid 16622) 3116s run: sidekiq: (pid 1154) 420s; run: log: (pid 16292) 3146s # 检查问题 [root@gitlab gitlab]# gitlab-rake gitlab:check SANITIZE=true --trace # 记得注意端口,如果没问题,访问出现502的问题就再刷新下
4.gitlab服务
gitlab-ctl stop --停止服务 gitlab-ctl reconfigure --启动服务 gitlab-ctl start --启动所有gitlab组件 gitlab-ctl restart 重启
5.访问页面
http://192.168.1.1:9981/
6.页面配置
7.项目检出,上传,修改
标签:run,log,15.9,gitlab,pid,ce,password,root From: https://www.cnblogs.com/yangmeichong/p/17306869.html