Sha256: c0851ca16ec2e3f39d1b1a21f7e8b2baa0d7b362f8cfc8fa3f9cd7715399c5a3

Contents?: true

Size: 1.9 KB

Versions: 200

Compression:

Stored size: 1.9 KB

Contents

class RenameSystemGroupsToHostCollections < ActiveRecord::Migration[4.2]
  def change
    rename_index :katello_key_system_groups, "index_key_system_groups_on_activation_key_id", "index_key_host_collections_on_activation_key_id"
    rename_index :katello_key_system_groups, "index_key_system_groups_on_system_group_id", "index_key_host_collections_on_host_collection_id"

    remove_foreign_key :katello_key_system_groups, :name => "key_system_groups_system_group_id_fk"

    rename_column :katello_key_system_groups, :system_group_id, :host_collection_id
    rename_table :katello_key_system_groups, :katello_key_host_collections

    rename_index :katello_system_groups, "index_system_groups_on_name_and_organization_id", "index_host_collections_on_name_and_organization_id"
    rename_index :katello_system_groups, "index_system_groups_on_organization_id", "index_host_collections_on_organization_id"
    rename_column :katello_system_groups, :max_systems, :max_content_hosts
    rename_table :katello_system_groups, :katello_host_collections

    add_foreign_key :katello_key_host_collections, :katello_host_collections, :name => "key_system_groups_system_group_id_fk", :column => "host_collection_id"

    rename_index :katello_system_system_groups, "index_system_system_groups_on_system_group_id", "index_system_host_collections_on_host_collection_id"
    rename_index :katello_system_system_groups, "index_system_system_groups_on_system_id", "index_system_host_collections_on_system_id"
    remove_foreign_key :katello_system_system_groups, :name => "system_system_groups_system_group_id_fk"
    rename_column :katello_system_system_groups, :system_group_id, :host_collection_id
    rename_table :katello_system_system_groups, :katello_system_host_collections
    add_foreign_key :katello_system_host_collections, :katello_host_collections, :name => "system_system_groups_system_group_id_fk", :column => "host_collection_id"
  end
end

Version data entries

200 entries across 200 versions & 1 rubygems

Version Path
katello-4.16.0 db/migrate/20140502164009_rename_system_groups_to_host_collections.rb
katello-4.15.1 db/migrate/20140502164009_rename_system_groups_to_host_collections.rb
katello-4.16.0.rc2 db/migrate/20140502164009_rename_system_groups_to_host_collections.rb
katello-4.16.0.rc1 db/migrate/20140502164009_rename_system_groups_to_host_collections.rb
katello-4.14.3 db/migrate/20140502164009_rename_system_groups_to_host_collections.rb
katello-4.14.2 db/migrate/20140502164009_rename_system_groups_to_host_collections.rb
katello-4.15.0 db/migrate/20140502164009_rename_system_groups_to_host_collections.rb
katello-4.15.0.rc2 db/migrate/20140502164009_rename_system_groups_to_host_collections.rb
katello-4.15.0.rc1 db/migrate/20140502164009_rename_system_groups_to_host_collections.rb
katello-4.14.1 db/migrate/20140502164009_rename_system_groups_to_host_collections.rb
katello-4.14.0 db/migrate/20140502164009_rename_system_groups_to_host_collections.rb
katello-4.14.0.rc3 db/migrate/20140502164009_rename_system_groups_to_host_collections.rb
katello-4.14.0.rc2 db/migrate/20140502164009_rename_system_groups_to_host_collections.rb
katello-4.14.0.rc1.1 db/migrate/20140502164009_rename_system_groups_to_host_collections.rb
katello-4.14.0.rc1 db/migrate/20140502164009_rename_system_groups_to_host_collections.rb
katello-4.13.1 db/migrate/20140502164009_rename_system_groups_to_host_collections.rb
katello-4.13.0 db/migrate/20140502164009_rename_system_groups_to_host_collections.rb
katello-4.12.1 db/migrate/20140502164009_rename_system_groups_to_host_collections.rb
katello-4.13.0.rc1 db/migrate/20140502164009_rename_system_groups_to_host_collections.rb
katello-4.12.0 db/migrate/20140502164009_rename_system_groups_to_host_collections.rb