Welcome to mirror list, hosted at ThFree Co, Russian Federation.

20200311154110_create_vulnerability_exports.rb « migrate « db - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: f3162f8808c9cfb41b255cb0f255553ea9c3a99b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# frozen_string_literal: true

class CreateVulnerabilityExports < ActiveRecord::Migration[6.0]
  include Gitlab::Database::MigrationHelpers

  DOWNTIME = false

  def change
    create_table :vulnerability_exports do |t|
      t.timestamps_with_timezone null: false
      t.datetime_with_timezone :started_at
      t.datetime_with_timezone :finished_at
      t.string :status, limit: 255, null: false
      t.string :file, limit: 255
      t.bigint :project_id, null: false
      t.bigint :author_id, null: false
      t.integer :file_store
      t.integer :format, limit: 2, null: false, default: 0

      t.index %i[project_id id], unique: true
      t.index %i[author_id]
    end
  end
end