gitlab 服务器搭建指南

GitLab 是一个用于仓库管理系统的开源项目。使用Git作为代码管理工具,并在此基础上搭建起来的web服务。

(1) 下载一键安装包  

   https://bitnami.com/stack/gitlab/bitnami-gitlab-8.1.4-1-linux-x64-installer.run

设置权限 chmod +x bitnami-gitlab-7.4.3-0-linux-installer.run 

执行安装 ./bitnami-gitlab-7.4.3-0-linux-installer.run

(2)安装软件版本

Bitnami GitLab Stack ships with the following software versions:
  - GitLab 7.13.0
  - Apache 2.4.16
  - ImageMagick 6.7.5
  - PostgreSQL 9.4.4
  - Git 1.9.5
  - Ruby 1.9.3-p551
  - Rails 4.2.2
  - RubyGems 1.8.12

(3)启动

./ctlscript.sh (start|stop|restart)
./ctlscript.sh (start|stop|restart) postgres
./ctlscript.sh (start|stop|restart) redis
./ctlscript.sh (start|stop|restart) apache
./ctlscript.sh (start|stop|restart) sidekiq
start - start the service(s)
stop - stop the service(s)
restart - restart or start the service(s)

(4)logs日志

/home/user/gitlab-7.13.0-0/apache2/logs/error.log on Linux or
/Applications/gitlab-7.13.0-0/apache2/logs/error.log.

(5)具体步骤



Welcome to the Bitnami Gitlab Stack Setup Wizard.

----------------------------------------------------------------------------
Select the components you want to install; clear the components you do not want 
to install. Click Next when you are ready to continue.

PhpPgAdmin [Y/n] :y

GitLab : Y (Cannot be edited)

Is the selection above correct? [Y/n]: y

----------------------------------------------------------------------------
Installation folder

Please, choose a folder to install Bitnami Gitlab Stack

Select a folder [/opt/gitlab-8.1.4-1]: /home/gitlab-8.1.4-1

----------------------------------------------------------------------------
Create Admin account

Bitnami Gitlab Stack admin user creation

Email Address [user@example.com]: wanglitao@tuzuu.com

Login [user]: git

Password :
Please confirm your password :
----------------------------------------------------------------------------
Hostname that will be used to create internal URLs. If this value is incorrect, 
you may be unable to access your Gitlab installation from other computers. It is 
advisable to use a Domain instead of an IP address for compatibility with 
different browsers.

Domain [127.0.0.1]: 

Do you want to configure mail support? [y/N]: y

----------------------------------------------------------------------------
Configure SMTP Settings

This is required so your application can send notifications via email.

Default email provider:

[1] GMail
[2] Custom
Please choose an option [1] : 2

----------------------------------------------------------------------------
Configure SMTP Settings

This data is stored in the application configuration files and may be visible to 
others. For this reason, it is recommended that you do not use your personal 
account credentials.

Username []: wanglitao@tuzuu.com

Password :
Re-enter :
SMTP Host []: smtp.exmail.qq.com

SMTP Port [587]: 465

Secure connection

[1] None
[2] SSL
[3] TLS
Please choose an option [3] : 2

Warning: Passwords Do Not Match!
Press [Enter] to continue:
Warning: Please provide the SMTP configuration parameters
Press [Enter] to continue:
----------------------------------------------------------------------------
Configure SMTP Settings

This data is stored in the application configuration files and may be visible to 
others. For this reason, it is recommended that you do not use your personal 
account credentials.

Username [wanglitao@tuzuu.com]: wanglitao@tuzuu.com

Password :
Re-enter :
SMTP Host [smtp.exmail.qq.com]: 

SMTP Port [465]: 

Secure connection

[1] None
[2] SSL
[3] TLS
Please choose an option [2] : 

----------------------------------------------------------------------------
Setup is now ready to begin installing Bitnami Gitlab Stack on your computer.

Do you want to continue? [Y/n]: y

----------------------------------------------------------------------------
Please wait while Setup installs Bitnami Gitlab Stack on your computer.


  • 1
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
为了搭建GitLab服务器,您需要按照以下步骤进行操作: 1. 准备服务器: - 获取一台运行Linux操作系统的服务器,推荐使用Ubuntu或CentOS。 - 确保服务器具有足够的资源(处理器、内存、存储空间)来支持您的项目需求。 2. 安装依赖: - 更新服务器上的软件包列表: `sudo apt update`(对于Ubuntu)或 `sudo yum update`(对于CentOS)。 - 安装必要的依赖项: `sudo apt install curl openssh-server ca-certificates postfix`(对于Ubuntu)或 `sudo yum install curl openssh-server postfix`(对于CentOS)。 - 在安装过程中,您需要配置Postfix来设置邮件转发。选择"Internet Site"选项,并将系统邮件名称设置为域名,比如"yourdomain.com"。 3. 安装GitLab: - 添加GitLab软件仓库并安装: ``` curl https://packages.gitlab.com/install/repositories/gitlab/gitlab-ee/script.deb.sh | sudo bash sudo EXTERNAL_URL="http://yourdomain.com" apt install gitlab-ee ``` 或者 ``` curl https://packages.gitlab.com/install/repositories/gitlab/gitlab-ee/script.rpm.sh | sudo bash sudo EXTERNAL_URL="http://yourdomain.com" yum install gitlab-ee ``` 请将"yourdomain.com"替换为您的域名或服务器IP地址。 4. 配置GitLab: - 打开配置文件: `sudo nano /etc/gitlab/gitlab.rb`。 - 根据您的需求,修改配置文件中的参数,如外部URL、SMTP设置、存储设置等。 - 保存并关闭配置文件。 5. 启动GitLab: - 执行命令: `sudo gitlab-ctl reconfigure`。 - 等待一段时间,直到GitLab配置完成。 6. 访问GitLab: - 在浏览器中访问您的服务器IP地址或域名。 - 您将被重定向到GitLab登录页面。 - 创建管理员账户,完成注册。 现在,您已经成功搭建了GitLab服务器,并可以开始管理您的项目了!请注意,这只是一个基本的搭建过程,您可能需要进一步配置和定制以满足您的特定需求。参考GitLab官方文档以获取更多信息和帮助:https://docs.gitlab.com/。

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值