summaryrefslogtreecommitdiff
path: root/db/post_migrate/20170830084744_destroy_gpg_signatures.rb
blob: de2e7e79e8663b6e55a722531a9e585259da1d7e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
class DestroyGpgSignatures < ActiveRecord::Migration
  DOWNTIME = false

  include Gitlab::Database::MigrationHelpers
  disable_ddl_transaction!

  class GpgSignature < ActiveRecord::Base
    self.table_name = 'gpg_signatures'

    include EachBatch
  end

  def up
    GpgSignature.each_batch do |relation|
      relation.delete_all
    end
  end

  def down
  end
end