diff --git a/config/patches/gitlab-rails/backup_read_REVISION.patch b/config/patches/gitlab-rails/backup_read_REVISION.patch deleted file mode 100644 index 333ef17..0000000 --- a/config/patches/gitlab-rails/backup_read_REVISION.patch +++ /dev/null @@ -1,22 +0,0 @@ -diff --git a/lib/backup/manager.rb b/lib/backup/manager.rb -index efaefa4..8f0e38f 100644 ---- a/lib/backup/manager.rb -+++ b/lib/backup/manager.rb -@@ -7,7 +7,7 @@ module Backup - s = {} - s[:db_version] = "#{ActiveRecord::Migrator.current_version}" - s[:backup_created_at] = Time.now -- s[:gitlab_version] = %x{git rev-parse HEAD}.gsub(/\n/,"") -+ s[:gitlab_version] = File.read(Rails.root.join('REVISION')).chomp - s[:tar_version] = %x{tar --version | head -1}.gsub(/\n/,"") - - Dir.chdir(Gitlab.config.backup.path) -@@ -92,7 +92,7 @@ module Backup - Dir.chdir(Rails.root) - - # restoring mismatching backups can lead to unexpected problems -- if settings[:gitlab_version] != %x{git rev-parse HEAD}.gsub(/\n/, "") -+ if settings[:gitlab_version] != File.read(Rails.root.join('REVISION')).chomp - puts "GitLab version mismatch:".red - puts " Your current HEAD differs from the HEAD in the backup!".red - puts " Please switch to the following revision and try again:".red diff --git a/config/software/gitlab-rails.rb b/config/software/gitlab-rails.rb index d2331dc..02fddd8 100644 --- a/config/software/gitlab-rails.rb +++ b/config/software/gitlab-rails.rb @@ -43,8 +43,6 @@ build do # source code to include the Git revision of the code included in the omnibus # build. command "sed -i \"s/.*REVISION.*/REVISION = '$(git log --pretty=format:'%h' -n 1)'/\" config/initializers/2_app.rb" - patch :source => "backup_read_REVISION.patch" - command "git rev-parse HEAD > REVISION" # The user uploads path is not (yet) configurable in gitlab-rails. As a # workaround, omnibus-gitlab creates a symlink for public/uploads. This breaks -- libgit2 0.21.2