summaryrefslogtreecommitdiff
path: root/db
diff options
context:
space:
mode:
authorDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2013-05-06 15:10:05 +0300
committerDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2013-05-06 15:10:05 +0300
commit8e4625af614b58df97d60031c2b5c72f37f1a692 (patch)
tree98ea623cfccc5c159013d26388ba551981ab16f9 /db
parentb7f1cf9f491f6cefdfc5f651f724331f07cfd6f5 (diff)
downloadgitlab-ce-8e4625af614b58df97d60031c2b5c72f37f1a692.tar.gz
Remove project_id from keys table
Diffstat (limited to 'db')
-rw-r--r--db/migrate/20130506095501_remove_project_id_from_key.rb9
-rw-r--r--db/schema.rb4
2 files changed, 10 insertions, 3 deletions
diff --git a/db/migrate/20130506095501_remove_project_id_from_key.rb b/db/migrate/20130506095501_remove_project_id_from_key.rb
new file mode 100644
index 00000000000..77daf5f19ba
--- /dev/null
+++ b/db/migrate/20130506095501_remove_project_id_from_key.rb
@@ -0,0 +1,9 @@
+class RemoveProjectIdFromKey < ActiveRecord::Migration
+ def up
+ remove_column :keys, :project_id
+ end
+
+ def down
+ add_column :keys, :project_id, :integer
+ end
+end
diff --git a/db/schema.rb b/db/schema.rb
index 251868f9237..d2fa70cc374 100644
--- a/db/schema.rb
+++ b/db/schema.rb
@@ -11,7 +11,7 @@
#
# It's strongly recommended to check this file into your version control system.
-ActiveRecord::Schema.define(:version => 20130506090604) do
+ActiveRecord::Schema.define(:version => 20130506095501) do
create_table "deploy_keys_projects", :force => true do |t|
t.integer "deploy_key_id", :null => false
@@ -76,12 +76,10 @@ ActiveRecord::Schema.define(:version => 20130506090604) do
t.text "key"
t.string "title"
t.string "identifier"
- t.integer "project_id"
t.string "type"
end
add_index "keys", ["identifier"], :name => "index_keys_on_identifier"
- add_index "keys", ["project_id"], :name => "index_keys_on_project_id"
add_index "keys", ["user_id"], :name => "index_keys_on_user_id"
create_table "merge_requests", :force => true do |t|