debian-mirror-gitlab/db/post_migrate/20200211152410_remove_instance_from_services.rb

20 lines
525 B
Ruby
Raw Normal View History

2020-03-13 15:44:24 +05:30
# frozen_string_literal: true
class RemoveInstanceFromServices < ActiveRecord::Migration[6.0]
include Gitlab::Database::MigrationHelpers
DOWNTIME = false
def up
return unless column_exists?(:services, :instance)
undo_rename_column_concurrently :services, :template, :instance
end
def down
# This migration should not be rolled back because it
# removes a column that got added in migrations that
# have been reverted in https://gitlab.com/gitlab-org/gitlab/-/merge_requests/24857
end
end