diff options
author | Reuben Pereira <rpereira@gitlab.com> | 2019-02-04 12:12:24 +0000 |
---|---|---|
committer | Sean McGivern <sean@gitlab.com> | 2019-02-04 12:12:24 +0000 |
commit | 20794440918b5435bd86838252e387cbea345812 (patch) | |
tree | 29a88f0e28120e532c9f88a770f05789f87a1833 /db | |
parent | 39abe2bbe777b72ea262882d83a2b8127fecf8c7 (diff) | |
download | gitlab-ce-20794440918b5435bd86838252e387cbea345812.tar.gz |
DB and model changes for Sentry project selection dropdown
Diffstat (limited to 'db')
-rw-r--r-- | db/migrate/20190115092821_add_columns_project_error_tracking_settings.rb | 16 | ||||
-rw-r--r-- | db/schema.rb | 6 |
2 files changed, 20 insertions, 2 deletions
diff --git a/db/migrate/20190115092821_add_columns_project_error_tracking_settings.rb b/db/migrate/20190115092821_add_columns_project_error_tracking_settings.rb new file mode 100644 index 00000000000..190b6f958fd --- /dev/null +++ b/db/migrate/20190115092821_add_columns_project_error_tracking_settings.rb @@ -0,0 +1,16 @@ +# frozen_string_literal: true + +class AddColumnsProjectErrorTrackingSettings < ActiveRecord::Migration[5.0] + include Gitlab::Database::MigrationHelpers + + DOWNTIME = false + + def change + add_column :project_error_tracking_settings, :project_name, :string + add_column :project_error_tracking_settings, :organization_name, :string + + change_column_default :project_error_tracking_settings, :enabled, from: true, to: false + + change_column_null :project_error_tracking_settings, :api_url, true + end +end diff --git a/db/schema.rb b/db/schema.rb index 4cc870ba6c8..4b6e4992056 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -1574,10 +1574,12 @@ ActiveRecord::Schema.define(version: 20190131122559) do end create_table "project_error_tracking_settings", primary_key: "project_id", id: :integer, force: :cascade do |t| - t.boolean "enabled", default: true, null: false - t.string "api_url", null: false + t.boolean "enabled", default: false, null: false + t.string "api_url" t.string "encrypted_token" t.string "encrypted_token_iv" + t.string "project_name" + t.string "organization_name" end create_table "project_features", force: :cascade do |t| |