我已经设置好了,我们正在运行GitLab v6.0.1的默认安装(我们也即将升级)。这是一个“生产”的设置,严格遵循这个指南:
https://github.com/gitlabhq/gitlabhq/blob/master/doc/install/installation.md
现在,我们如何安全地更改有效安装的?
显然,我们的URL很长,我们想出了一个新的URL。我已经编辑了一些配置文件,“应用程序状态检查”报告一切正常。我已经重新启动了服务器,以确保一切仍在运行。
我可以很好地访问Nginx,通过我们原来的SSL。我可以浏览GitLab站点,创建存储库,等等。我可以很好地派生和提交。
看起来一切正常;但是,由于这不是我的原生环境,我想仔细检查一下我是否已经完成了重命名GitLab站点的所有工作。
我编辑过的文件是:
/etc/hosts
127.0.0.1 localhost
10.0.0.10 wake.domain.com wake
10.0.0.10 git.domain.com git
/home/git/gitlab/config/gitlab.yml
production: &base
gitlab:
host: git.domain.com
/home/git/gitlab-shell/config.yml
gitlab_url: "https://git.domain.com"
^- yes, we are on SSL and that is working, even on a new URL
/etc/nginx/sites-available/gitlab
server {
server_name git.domain.com
发布于 2013-10-19 19:13:13
你做的每件事都是正确的!
您还可以更改电子邮件配置,具体取决于电子邮件服务器是否也是同一服务器。GitLab发送的电子邮件和管理电子邮件的电子邮件配置都在gitlab.yml中。
发布于 2015-01-18 06:44:27
GitLab综合总线
对于Omnibus安装,情况略有不同。
Omnibus安装中正确位置为:
/etc/gitlab/gitlab.rb
external_url 'http://gitlab.example.com'
最后,您需要执行sudo gitlab-ctl reconfigure
和sudo gitlab-ctl restart
以使更改生效。
我在错误的地方做了修改,它们被吹走了。
不正确的路径包括:
/opt/gitlab/embedded/service/gitlab-rails/config/gitlab.yml
/var/opt/gitlab/.gitconfig
/var/opt/gitlab/nginx/conf/gitlab-http.conf
请注意下面的警告:
# This file is managed by gitlab-ctl. Manual changes will be
# erased! To change the contents below, edit /etc/gitlab/gitlab.rb
# and run `sudo gitlab-ctl reconfigure`.
发布于 2014-01-15 10:35:57
事实上,这并不完全正确。我来到这个页面,试图自己回答这个问题,因为我们正在将生产GitLab服务器从http://
过渡到https://
,大多数东西都像上面描述的那样工作,但是当你登录到https://server
,一切看起来都很好……除非您浏览到一个项目或存储库,它会显示SSH和HTTP指令...它显示的是"http“,它显示的指令也是"http”。
不过,我发现了更多需要编辑的东西:
/home/git/gitlab/config/gitlab.yml
production: &base
gitlab:
host: git.domain.com
# Also edit these:
port: 443
https: true
...
和
/etc/nginx/sites-available/gitlab
server {
server_name git.domain.com;
# Also edit these:
listen 443 ssl;
ssl_certificate /etc/ssl/certs/somecert.crt;
ssl_certificate_key /etc/ssl/private/somekey.key;
...
https://stackoverflow.com/questions/19456129
复制相似问题