Ubuntu 1204 安装 GitLab 出现 502

Ubuntu 1204 安装 GitLab 出现 502  GitLab is not responding.

   问题描述:   502    GitLab is not responding.

                        Please contact your GitLab administrator if this problem persists.

    出错原因:  GitLab 7.1 需要 rake 10.3.2

     解决办法:

     执行如下步骤:

      1, 查看  gem 列表

gao@gao-VirtualBox:/home/git/gitlab$ gem list

     结果:

*** LOCAL GEMS ***

bigdecimal (1.2.4)
bundler (1.7.2)
io-console (0.4.2)
json (1.8.1)
minitest (4.7.5)
multi_xml (0.5.5)
mysql2 (0.3.16)
psych (2.0.5)
rake (10.1.0)   (这里能看到 rake 的版本是 10.1.0)
rdoc (4.1.0)
test-unit (2.1.2.0)
 
    2.安装 rake 10.3.2 版本

gao@gao-VirtualBox:/home/git/gitlab$ sudo gem install rake -v '10.3.2' --source http://rubygems.org
    结果:
Fetching: rake-10.3.2.gem (100%)
rake's executable "rake" conflicts with /usr/local/bin/rake
Overwrite the executable? [yN]  y
Successfully installed rake-10.3.2
Parsing documentation for rake-10.3.2
Installing ri documentation for rake-10.3.2
Done installing documentation for rake after 1 seconds
WARNING:  Unable to pull data from 'https://rubygems.org/': Errno::ETIMEDOUT: Connection timed out - connect(2) for "s3.amazonaws.com" port 443 (https://api.rubygems.org/specs.4.8.gz)
1 gem installed
 
    3. 再次查看 gem 列表
gao@gao-VirtualBox:/home/git/gitlab$ gem list
         结果:
*** LOCAL GEMS ***

bigdecimal (1.2.4)
bundler (1.7.2)
io-console (0.4.2)
json (1.8.1)
minitest (4.7.5)
multi_xml (0.5.5)
mysql2 (0.3.16)
psych (2.0.5)
rake (10.3.2, 10.1.0)
rdoc (4.1.0)
test-unit (2.1.2.0)
          4.再次执行编译 assets
gao@gao-VirtualBox:/home/git/gitlab$ sudo -u git -H bundle exec rake assets:precompile RAILS_ENV=production

     安装了 rake 10.3.2 再次执行上一步的编译命令再次访问,成功了.   /home/git/gitlab-shell 下的 config.yml gitlab_url: "http://gitlab.gxlhost.com:8081/"

猜你喜欢

转载自gxl-ct001.iteye.com/blog/2115682