5
5

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

Gitlabアップデート 7.2 -> 7.5

Posted at

===========================

Gitlab 5.0のインストール (CentOS 6.5)
Gitlabアップデート 5.0 -> 6.0
Gitlabアップデート 6.0 -> 7.2

の後に行った作業です。

Requirements

  • CentOS (Tested on 6.5)
  • ruby (Tested on 2.1.2)

Upgrade

  • gitlab停止
service gitlab stop
  • バックアップ
su - git
cd /home/git/gitlab
bundle exec rake gitlab:backup:create RAILS_ENV=production
  • アップグレードスクリプトでGitlab本体をアップグレード
su - git
cd /home/git/gitlab
if [ -f bin/upgrade.rb ]; then ruby bin/upgrade.rb; else ruby script/upgrade.rb; fi
  • unicornのtimeoutを60秒に修正する(既に設定してあればそのまま)
vim config/unicorn.rb
-timeout 30
+timeout 60
  • mysqlの接続設定を変更する
production:

-pool: 5
+pool: 10
+collation: utf8_general_ci

poolを増やしている。

  • gitlab-shellをアップグレード
su - git
cd /home/git/gitlab-shell
git checkout v2.2.0
  • gitlab-shellが利用するgitlabのURLを修正
cd /home/git/gitlab-shell
vim config.yml
-gitlab_url: "http://localhost:3000/"
+gitlab_url: "https://gitlab.example.com/"
vim lib/gitlab_config.rb
-@config['gitlab_url'] ||= "http://localhost:3000/"
+@config['gitlab_url'] ||= "https://gitlab.example.com/"
  • 起動
service gitlab start

Trouble shooting

  • ログを見てみる
cd /home/git/gitlab/log
tail -f *.log
  • ActionView::Template::Errorのようなエラーが出て500になる

config/gitlab.yml内のgitのpathが合ってるか確認しましょう。

  • submoduleを含むフォルダで500になる

submoduleを削除で解決します。もう一度追加すれば戻るかも。

  • 日本語を含むタグ・ブランチ

消しましょう。

5
5
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
5
5

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?