1、下载一键安装包https://bitnami.com/stack/gitlab。
2、增加可执行权限:chmod +x bitnami-gitlab-7.12.0-0-linux-x64-installer.run( bitnami-gitlab-7.12.0-0-linux-x64-installer.run代表下载的安装包,根据实际的文件名操作)。
3、执行安装程序:./bitnami-gitlab-7.12.0-0-linux-x64-installer.run
4、设置发送邮件邮箱:
(1)cd /opt/gitlab-7.12.0-0/apps/gitlab/htdocs/config/initializers
(2)cp smtp_settings.rb.sample smtp_settings.rb
(3)smtp_settings.rb文件内容如下:
if Rails.env.production?
Gitlab::Application.config.action_mailer.delivery_method = :smtp
ActionMailer::Base.smtp_settings = {
address: "smtp.163.com",
port: 25,
user_name: "user_name",
password: "password",
domain: "163.com",
authentication: :plain,
enable_starttls_auto: false
}
end
注意: enable_starttls_auto值为false,否则qq邮箱无法接收邮件。
(4)重启gitlab:/opt/gitlab-7.12.0-0/ctlscript.sh restart