diff options
Diffstat (limited to 'db/migrate/20200429182245_add_default_value_for_store_to_uploads.rb')
-rw-r--r-- | db/migrate/20200429182245_add_default_value_for_store_to_uploads.rb | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/db/migrate/20200429182245_add_default_value_for_store_to_uploads.rb b/db/migrate/20200429182245_add_default_value_for_store_to_uploads.rb new file mode 100644 index 00000000000..f28fcce8f2f --- /dev/null +++ b/db/migrate/20200429182245_add_default_value_for_store_to_uploads.rb @@ -0,0 +1,19 @@ +# frozen_string_literal: true + +class AddDefaultValueForStoreToUploads < ActiveRecord::Migration[6.0] + include Gitlab::Database::MigrationHelpers + + DOWNTIME = false + + def up + with_lock_retries do + change_column_default :uploads, :store, 1 + end + end + + def down + with_lock_retries do + change_column_default :uploads, :store, nil + end + end +end |